I am really very sorry.
I mistyped the entire sql statement.
This is what my actual code looks like:
sqlite db1 "cesc_simputer.db"
#Inserting data into mri_output table
set connection_no { }
set insert_normal "insert into mri_output (pwd,ac_my,con_no) values
('$pass','$ac_mth$ac_yr','$sel_con')"
db1 eval insert_normal {} {
}
Please note that the problem is with the syntax of the sql statement.
Regards,
Anirban Sarkar
----- Original Message -----
From: "Asko Kauppi" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Thursday, February 17, 2005 2:46 PM
Subject: Re: [sqlite] Basic insert statement - syntax problem
>
> The error messages provided by SQLite seem to be very helpful, can you
> use them?
>
> like: if (rc) glua_errorN( "sqlite3 error %d: %s", rc,
> sqlite3_errmsg(db) );
>
> Aside that, shouldn't the table name (mri) have quotes ('mri')?
> What's the $con_no doing without quotes as well. Use ?1 for binding
> stuff if that's what you need.
>
> -ak
>
>
> 17.2.2005 kello 11:04, Anirban Sarkar kirjoitti:
>
> Hi all,
> >
> > I am having syntax problem with a basic sqlite insert statement. I
> > know it's very simple but just could'nt make out where I am going
> > wrong.
> >
> > set insert_details "insert into mri (pwd,con_no) values
> > ('$pwd',$con_no)"
> > Where am I going wrong?
> >
> > Thanks and regards,
> > Anirban Sarkar
>