Click to See Complete Forum and Search --> : Problem Submitting info to a database when it has an apostaphe " ' "


flappie
March 25th, 2003, 11:02 AM
I am having a problem when submitting data from a text box into a database. The problem comes in when I use an apostarphe. Can anyone help in how to overcome this problem.

My thought is to search the data for the apostraphe and replace it with a Chr(??) and then submit it. How do I do this, if it is the correct method of doing so.

Any help is greatly appreciated.

Thanks

sjchandramohan
March 26th, 2003, 05:37 AM
Hi,

u could prevent error by just adding one more apostrope.

For eg: if you want to store the value "hello it's me",
then you should give in your code as "hello it'' me".

If you are using text box to type the value, then replace single apostrope character by two apostrope characters.

Regards,
Chandramohan J.