2012-02-22 105 views
1

我無法在sqlite中插入撇號字符。我想這種方式是許多說,在論壇替換「‘‘和’’'」在sqlite錯誤中插入撇號值

String replace=replaceString.replace("'"," ''") but after using this method too gives insert error. 

回答

0

您是否正在尋找在字符串中使用「?

如果是這樣,你能做到這一點

「插入MY_TABLE集myvalue的=「我的狗\的骨頭」其中id = 5"

1

我喜歡用

String replace = replaceString.replace("'","\'"); 

這將撇號插入表格中。