|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Access database Memo data typesHi,
I am trying to add record (INSERT INTO...) into a Memo field in the access database. But the ExecuteNonQuery() throws an exception. "Syntax error (missing operator) in query expression "<field value>"". Also note that <field value> is a string and has apostrophes in two places. For text field I am sending with apostrophes around the field value and it works. Does any one know, what I am missing here? Regards Sanjib I got the answer Chr(34) + <field value> + Chr(34)
Show quote "Sanjib Biswas" <sanjib.bis***@ieee.org> wrote in message news:ubpjZQI4FHA.696@TK2MSFTNGP09.phx.gbl... > Hi, > > I am trying to add record (INSERT INTO...) into a Memo field in the > access database. But the ExecuteNonQuery() throws an exception. "Syntax > error (missing operator) in query expression "<field value>"". Also note > that <field value> is a string and has apostrophes in two places. For text > field I am sending with apostrophes around the field value and it works. > > Does any one know, what I am missing here? > > Regards > Sanjib > By the does any know, the correct way to insert a Memo record into Access
database? Because even after adding quote before and after the field value does not work all the times. Sometime, I had to pass double quote 'Chr(39)' to get it working. Regards Sanjib Show quote "Sanjib Biswas" <sanjib.bis***@ieee.org> wrote in message news:ebAPcgI4FHA.700@TK2MSFTNGP15.phx.gbl... >I got the answer Chr(34) + <field value> + Chr(34) > > "Sanjib Biswas" <sanjib.bis***@ieee.org> wrote in message > news:ubpjZQI4FHA.696@TK2MSFTNGP09.phx.gbl... >> Hi, >> >> I am trying to add record (INSERT INTO...) into a Memo field in the >> access database. But the ExecuteNonQuery() throws an exception. "Syntax >> error (missing operator) in query expression "<field value>"". Also note >> that <field value> is a string and has apostrophes in two places. For >> text field I am sending with apostrophes around the field value and it >> works. >> >> Does any one know, what I am missing here? >> >> Regards >> Sanjib >> > > |
|||||||||||||||||||||||