Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Data Days is here! Join us now for 60+ days of learning, challenges, and connection. Learn more

Reply
red_robot
Frequent Visitor

Connecting to Informix server with SQL statement - CASE expression returns "column not found" error

Hello Power BI users:

 

I have successfully connected to an Informix database but am encountering an error when I try to connect using the optional SQL statement.

 

My SQL statement contains a CASE expression like so:

 

SELECT ...

   CASE

      WHEN y.code IN(1,2,3) THEN "SUCCESSFUL"

      WHEN y.code IN(4,5,6) THEN "UNSUCCESSFUL"

   END AS status_result

 

The problem is that the Microsoft Informix Client interprets "SUCCESSFUL" in the above code as a column name and throws a -217 error saying that the "Column (SUCCESSFUL) not found in any table in the query (or SLV is undefined). SQLSTATE=IX000 SQLCODE=-217"

 

I can run this exact same code using the SQuirrel SQL client agains the Informix server and return a result.

 

If anyone has any idea of how to get around this error, or know if it is an error in the underlying Informix driver, I would love to hear from you.

 

Thanks!

1 ACCEPTED SOLUTION
red_robot
Frequent Visitor

Nevermind ... I replaced all double quotes with single quotes and it appears to have fixed the error. Thanks!

View solution in original post

1 REPLY 1
red_robot
Frequent Visitor

Nevermind ... I replaced all double quotes with single quotes and it appears to have fixed the error. Thanks!

Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.