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

Popular posts from this blog

c - Mpirun hangs when mpi send and recieve is put in a loop -

python - Apply coupon to a customer's subscription based on non-stripe related actions on the site -

java - Unable to get JDBC connection in Spring application to MySQL -