codeigniter - MySQL Error Getting Values with Span -
I have another query about my database, I am using Codeigniter and when I use SPAN I get the data and save it to me. MySQL database uses a \ n drawing in this data and this is why the error arises. Here is the problem
value ('\ n16', 'SMDC') ` But in my ultimate 16 is getting the value where it spans.
is a special character for \ n mysql and other languages and means: line The end of (character line) you have to protect from characters like that which are using another backslash "\" in front of them.
Check it out:
An example with codeigniter for you is:
$ search = '\ n16'; $ Sql = "SELECT id from table WHERE column like '%'. $ This-> db-> Escape_th_st ($ search)."% '";
See this for:
Comments
Post a Comment