Passing string variable to Stored Procedure - Too Long Error

Inductive Team,

We had a Table, Multiple (16) text fields for filtering the data. We are fetching data using Stored Procedure (takes WHERE clause as Parameter (Type: varchar(2000)) > Building prepared statement by attaching WHERE clause > running prepared statement and return result-set).

We are building WHERE clause depending on filtering text fields. We are making sure there will be no statement if text fields are not entered. Our query will become big once you enter in more than 6 or 7 text fields. After this, we passed this WHERE clause and struck with … is too long. Maximum length is 128 error (screenshot attached). When we run in SQL Server with long WHERE clause, it works correctly.

Is there any setting we need to make for Ignition ?

That error usually means that SQL is interpreting something in double quotes as being an identifier (i.e., column name). Do you have something in your SELECT query in the stored procedure that is using double quotes?

Can you post the query and the code you use to run the query?

James,

You are absolutely correct. We are using double quotes for passing parameter to Stored Procedure. Now, we rectified our mistake and it works now.

Thank you Team.