RE: 4gl Syntax
Posted in 2004
This message is in MIME format. Since your mail reader does not understand this format, some or all of this message may not be legible. ------_=_NextPart_001_01C48160.F0824810 Content-Type: text/plain; charset="iso-8859-1" John, You need at least one blank at the beginning or end of each line of the statement you are preparing or it will end up as one long string. i.e. "select prop_namefrom propertywhere prop = ?" -----Original Message----- From: John Hibner [mailto:john_hibner@choicehotels.com] Sent: Friday, August 13, 2004 1:45 PM To: informix-list@iiug.org Subject: 4gl Syntax One of the developers here at my company get the following when attempting to compile a 4gl script based on what he thought the manual was telling him: Example from manual: PREPARE up_sel FROM "SELECT * FROM customer ", "WHERE customer_num between ? and ? ", "FOR UPDATE" Error from Compiler: prepare stmt1 from "select prop_name", |______________________^ | | A grammatical error has been found on line 23, character 24. The | construct is not understandable in its context. See error number | -4373. "from property", "where prop = ?" Not having wrote any statements myself for quite a while, I was hoping there was a 4gl guru out there that could point us in the right direction. Thanks, ####### John Hibner Choice Hotels Int. sending to informix-list ------_=_NextPart_001_01C48160.F0824810 Content-Type: text/html; charset="iso-8859-1" <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN"> <HTML> <HEAD> <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1"> <META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2654.45"> <TITLE>RE: 4gl Syntax</TITLE> </HEAD> <BODY> <P><FONT SIZE=2>John,</FONT> </P> <P><FONT SIZE=2>You need at least one blank at the beginning or end of each line of</FONT> <BR><FONT SIZE=2>the statement you are preparing or it will end up as one long string.</FONT> <BR><FONT SIZE=2>i.e. "select prop_namefrom propertywhere prop = ?"</FONT> </P> <P><FONT SIZE=2>-----Original Message-----</FONT> <BR><FONT SIZE=2>From: John Hibner [<A HREF="mailto:john_hibner@choicehotels.com">mailto:john_hibner@choicehotels.com</A>]</FONT> <BR><FONT SIZE=2>Sent: Friday, August 13, 2004 1:45 PM</FONT> <BR><FONT SIZE=2>To: informix-list@iiug.org</FONT> <BR><FONT SIZE=2>Subject: 4gl Syntax</FONT> </P> <BR> <P><FONT SIZE=2>One of the developers here at my company get the</FONT> <BR><FONT SIZE=2>following when attempting to compile a 4gl script</FONT> <BR><FONT SIZE=2>based on what he thought the manual was telling</FONT> <BR><FONT SIZE=2>him:</FONT> </P> <P><FONT SIZE=2>Example from manual:</FONT> <BR><FONT SIZE=2>PREPARE up_sel FROM</FONT> <BR><FONT SIZE=2>"SELECT * FROM customer ",</FONT> <BR><FONT SIZE=2>"WHERE customer_num between ? and ? ",</FONT> <BR><FONT SIZE=2>"FOR UPDATE"</FONT> </P> <P><FONT SIZE=2>Error from Compiler:</FONT> </P> <P><FONT SIZE=2> prepare stmt1 from</FONT> <BR><FONT SIZE=2> "select prop_name",</FONT> <BR><FONT SIZE=2>|______________________^</FONT> <BR><FONT SIZE=2>|</FONT> <BR><FONT SIZE=2>| A grammatical error has been found on line</FONT> <BR><FONT SIZE=2>23, character 24. The </FONT> <BR><FONT SIZE=2>| construct is not understandable in its context.</FONT> <BR><FONT SIZE=2>See error number </FONT> <BR><FONT SIZE=2>| -4373.</FONT> <BR><FONT SIZE=2> "from property",</FONT> <BR><FONT SIZE=2> "where prop = ?"</FONT> </P> <P><FONT SIZE=2> Not having wrote any statements myself for</FONT> <BR><FONT SIZE=2>quite a while, I was hoping there was a 4gl guru</FONT> <BR><FONT SIZE=2>out there that could point us in the right</FONT> <BR><FONT SIZE=2>direction.</FONT> </P> <P><FONT SIZE=2>Thanks,</FONT> <BR><FONT SIZE=2>#######</FONT> <BR><FONT SIZE=2>John Hibner</FONT> <BR><FONT SIZE=2>Choice Hotels Int.</FONT> </P> <P><FONT SIZE=2>sending to informix-list</FONT> </P> </BODY> </HTML> ------_=_NextPart_001_01C48160.F0824810-- sending to informix-list