SitePoint Sponsor |
|
User Tag List
Results 1 to 4 of 4
-
Aug 21, 2001, 02:55 #1
- Join Date
- Jun 2001
- Location
- Malaysia
- Posts
- 352
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
adding in SQL text with apostrophes
hey guys...
slight dilemma.
I'm using mySQL and am inserting / updating stuff into a table like this:
PHP Code:update pdc_emp
SET text='infinitium is a cool guy' WHERE ID=10662105;
this is just an example.. don't mind the actual inserted text....
-
Aug 21, 2001, 03:43 #2
- Join Date
- Jul 2001
- Location
- UK
- Posts
- 407
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Backspace before the apostrophe?
Like:
PHP Code:SET text='infinitium[b]\[/b]'s a cool guy' WHERE ID=10662105;
-
Aug 21, 2001, 06:13 #3
- Join Date
- Nov 2000
- Location
- Sydney, Australia
- Posts
- 134
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
you should use backslashes:
SET text='infinitium\'s a fn\' cool guy' WHERE ID=10662105;
Last edited by alexk; Aug 21, 2001 at 06:15.
-
Aug 21, 2001, 23:43 #4
- Join Date
- Jun 2001
- Location
- Malaysia
- Posts
- 352
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
just what i was looking for.. thanks!
Bookmarks