Hi Teoman Thanks for your help, that did the trick!
Steve W "Teoman Haliloglu" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi Steve, > > That seems like a usual SQL problem and I guess it's not related to Cache > only. > > You have to replace single quotes with double quotews in the comment field > while writing the sql command. > > your vb code will be sth like this (I can't remeber the exact of Replace, > you might need to check): > > strComment = Replace(strComment, "'", "''") --->Code to replace ' with '' > strSQL = "Insert Into sometable(fldComment) " Values('" & "')" > objConnection.Execute(strSQL) > > Regards, > Teoman > "Steve" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] > > Hi, > > I need to update a cache field that contains some user comments. The VB6 > > application retrieves data from cache, allows the user to amend it and > then > > saves it back. The method is basically an ADODB command containing an > update > > statement. The problem occurs if a user puts in an apostrophe or single > > quote mark in the comments! Then it falls over because cache thinks the > next > > bit is a field name. > > > > Any suggestions gratefully received. > > > > Thanks > > Steve W > > > > > >
