![]() |
Why use `?
I see people putting "`" around input for the SQL, why?
|
Oh I get you now. Blond moment!
Basically the back-ticks should only be around the table names for the very reason that it distinguishes between a user string and a reserved word in MySQL: sql Code:
Whereas the back-ticks tell MySQL that count and desc are user entities, and not MySQL commands:sql Code:
|
-It defines commands from user entities as wild pointed out
-It looks cleaner in my opinion I personally find it good coding to use the brackets so that if you accidentally name a table or field a command name, you wont have to worry about an error. |
No one said this directly but hinted at it ... I believe the back ticks are MySQL specific.
|
| All times are GMT. The time now is 06:17 AM. |
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0