Re: SQL Parsing Error Question
Posted in 1997
Prepare your statement. If there are any problems you'll most probably get Informix error "-201: Syntax error". The sqlca.sqlerrd[5] will contain the offset position of the offending code in the SQL statement. Catalin -- Catalin Badea Senior Technical Architect Tecsys Inc. cat@tecsys.com www.tecsys.com include "disclaimer.4gh" Richard Aron <raron@cyberramp.net> wrote in article <01bc02a8$f953a0e0$6b529ecf@raron.cyberramp.net>... > I am starting a project which will be using PC workstations connected to an > Informix database running on a UNIX box. (I have never worked with > Informix before.) I need to develop a client application that will allow > users to add change and delete SQL logical expressions that will be stored > in a database and later retrieved by processes to construct "WHERE" clauses > in SQL statements. The reason for this is to allow the users to > dynamically change business rules in the system. My question is, what is > the best way to verify these logical expressions are syntactically correct > before storing them in the database? I am considering building a "dummy" > SQL statement, executing it against a dummy table, and checking for an > execution error. My concern is how can I get a meaningful error message > to present to the user if the expression contains errors? I am considering > using VB to develop the client application. Any suggestions? > > Please email me at raron@cyberramp.net >