Re: sql in informix
Posted in 2007
Go through these links given below. It would surely help you in getting the basic difference B/W INFORMIX and SQL Stored procedures http://www.4js.com/exclude/en/html/fgl/User/odiagmsv.html http://download.oracle.com/docs/html/B16022_01/ch3.htm Thanks Balaji Vinu On 10/8/07, Ben Thompson <ben@nomonitorsoftspam.com> wrote: > > jarppi.duplessis@gmail.com wrote: > > HI, > > I don't know if this is the right group, if not, please point me to > > the right one. > > > > I'm using SQL to query INformix, but I'm getting some weird errors. > > Below is my query, why is Informix bitching about syntax errors? > > Also, it doesn't tell me what's wrong, or even where, just that there > > is something wrong! Coming from MS SQL, this is very frustrating. > [snip] > > > Any idea what I'm doing wrong? > > You will need to modify your SQL statements somewhat for Informix since > once you get into declaring variables and procedure you can't just copy > and paste between MSSQL and Informix. Here are some differences to take > account of: > > - I don't think variable names need a '@' or any other character in > front of them. > - Each statement will need to end with a semi-colon. MSSQL doesn't > enforce this; Informix does. > - I don't think 'datetime' is an acceptable variable type. It looks like > you want 'datetime year to day'. > - 'DECLARE' should be 'DEFINE' I think. > - You probably want to encapsulate your SQL statements is a stored > procedure if you want to use variables. I don't think you can use them > in raw SQL. > > I hope this helps but you'll probably have to do some reading yourself > as well. > > Regards, Ben. > _______________________________________________ > Informix-list mailing list > Informix-list@iiug.org > http://www.iiug.org/mailman/listinfo/informix-list > -- no me "NO" life know me "KNOW" life