Issue retrieving and displaying text[] from Supabase

Troubleshooting

I'm using Supabase as the backend for my Flutter app, and I have a database field of type text[] (array of strings). My goal is to retrieve these keywords and display them in an input field as a single string separated by commas.

When I fetch the data from Supabase, I pass the keywords field to the function above to convert it into a string and return it inside an inputText field. However, keywords returns null or an unexpected format, preventing me from using it correctly.

Questions:

  1. What is the correct way to retrieve a text[] field from Supabase and use it as a List<String> in Flutter?

  2. Is there any Supabase setting that might be affecting how arrays are returned?

Any help is greatly appreciated! ๐Ÿš€

What have you tried so far?
  • Checking if the field is correctly filled in the database.

  • Printing the keywords value inside the joinKeywords() function, and it is coming as null.

  • Testing with different records to see if the issue happens only in some cases.

Did you check FlutterFlow's Documentation for this topic?
Yes
1
2 replies