What does `STRING_TO_ARRAY(‘a,b,c’, ‘,’)` return in PostgreSQL?

Advanced SQL Developer Medium

Advanced SQL Developer — Medium

What does `STRING_TO_ARRAY(‘a,b,c’, ‘,’)` return in PostgreSQL?

Key points

  • The function splits a string based on a delimiter
  • The result is an array of strings
  • The TEXT[] data type signifies an array of text values
  • Each element is enclosed in single quotes

Ready to go further?

Related questions