ORA-00933 : commande SQL mal terminée
Solved
BelleRose2
Posted messages
10
Status
Member
-
nichola Posted messages 113 Status Member -
nichola Posted messages 113 Status Member -
Bonjour,
I work with Windows Forms under Oracle. The following line gives me an error saying that this command is "not properly ended". Can someone help me please? :(
OleDbCommand comdatabase = new OleDbCommand("select * from bi_dictionnaire where CHAMPS='" + textType.Text + "' and LIBELLE_FR LIKE '" + ID2.Text + "%';", condatabase);
I work with Windows Forms under Oracle. The following line gives me an error saying that this command is "not properly ended". Can someone help me please? :(
OleDbCommand comdatabase = new OleDbCommand("select * from bi_dictionnaire where CHAMPS='" + textType.Text + "' and LIBELLE_FR LIKE '" + ID2.Text + "%';", condatabase);
2 answers
Hello,
I'm not an Oracle or Forms expert, but it seems to me that there's a '%' missing after the LIBELLE_FR_ LIKE, right?
It should be this instead:
OleDbCommand comdatabase = new OleDbCommand("select * from bi_dictionnaire where CHAMPS='" + textType.Text + "' and LIBELLE_FR LIKE '%"+ ID2.Text +"%');",
I'm not an Oracle or Forms expert, but it seems to me that there's a '%' missing after the LIBELLE_FR_ LIKE, right?
It should be this instead:
OleDbCommand comdatabase = new OleDbCommand("select * from bi_dictionnaire where CHAMPS='" + textType.Text + "' and LIBELLE_FR LIKE '%"+ ID2.Text +"%');",
Thank you :)