I am on my first MySQL DB and it is very text heavy because it is a news site, therefore there is a great deal of use of the apostrophe or as MySQL would see it the single quote. I was hoping to be able to use double quotes to overcome the need to constantly have to escape the apostrophe/single quote, and where speech marks or a double quote is required, I was going to suggest that the editors of the site use two single quotes. Is this going to cause me problems?

However...

I have seen a message in the mailing lists that stated the use of double quotes locks me into MySQL for ever as most other DB packages use only single quotes to enclose data. I am concerned about this just incase my client decides that for some reason in the future they want me to use Oracle or MS SQL etc.

On top of this is have also just seen messages about 'magic quotes', what is this then? A reply to the message also mentions the use of 'mysql_real_escape_string'!!

Does this mean that when a user submits a html form with a name such as 'O'Brien' the name is automatically escaped to 'O\'Brien'? Would I be safer to use double quotes to enclose data, eg. "O'Brien"? I obviously can't ask all visitors to the site who enter their name to escape each quote.

Are my prayers answered? I have been a bit concerned that I might not be able to completely fulfill my clients needs because of them being restricted to the use of single quotes.

Thanks in advance

Mat


-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]



Reply via email to