Single Select Fields Not Appearing in Query Results

When running SQL queries that include single select fields (ENUM type in MySQL):

  1. The query includes the single select fields in the SQL statement
  2. The query executes without errors
  3. The result set does not include the requested single select fields
  4. The same query runs correctly when executed directly in the database

Environment

  • Database: MySQL
  • Field Types: ENUM fields (specifically “order status” and “order state”)
  • UPDATE: Also experiencing issues with linked field types.
  • Feature: Query builder/runner (noted as being in beta)

Impact

Unable to access critical status and state information through queries, making it impossible to use the query feature for reports or data views that require these fields.

For anyone else that runs into this, it’s likely caused due to the fields in question not having a value in the first few fields of the results, which is what Noloco uses to determine if it’s valid/what type of field it is.

One fix is to do COALESCE("column_name", NULL)

2 Likes

Thank you @darragh this resolved my issue.