• Welcome, Guest. Please login.
 
October 21, 2019, 02:25:21 am

News:

Welcome to the SQLitening support forums!


Semicolon cannot terminate the statement

Started by syahmicro, May 10, 2013, 04:46:18 pm

Previous topic - Next topic

syahmicro

May 10, 2013, 04:46:18 pm Last Edit: May 11, 2013, 12:56:44 am by syahmicro
SQLite version 3.7.13 2012-06-11 02:05:22
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> create table tbl1(char ,int );
...> insert into tbl1 values('kenneth,10);
...> ;
...>;
...>;

i installed sqlite on ubuntu 12.04 lts

i got this problem,as u can see from that statement i just
deliberate to dump the comma at 'kenneth.supposely when there have missing character such as comma it must be show the syntax error but then when need terminate the statement i could not work.I don't what is the problem because i was tried 2 times installing sqlite on ubuntu 12.04

so from this,i would like to make another coding to fix up this problem by using c programming
but then do you all have ideas to make coding?so we can access with sqlite using this command
gcc -o file file.c -lsqlite3

in sqlite,there are having files which is header file and c files.
sqlite3.c
shell.c

Bern Ertl

It's quite possible that I didn't understand your note correctly, but...

Quote from: syahmicro on May 10, 2013, 04:46:18 pm
...
sqlite> create table tbl1(char ,int );
...> insert into artist values('kenneth,10);
...


Seems to me that you need to use the correct table name?

syahmicro

SQLite version 3.7.13 2012-06-11 02:05:22
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> create table tbl1(char ,int );
...> insert into tbl1 values('kenneth,10);
...> ;
...>;
...>;

oh sory for previous post that i was inserted wrong table name,but this is the correct one..as u can see the query there still got problem to terminate the program using semicolon.

for this problem i need to solve it,by the way i have a bit issue that how come this happened

Paul Squires

Should there be a trailing single quote at the end of kenneth?   i.e.   'kenneth'

insert into tbl1 values('kenneth',10);