Reputation: 399
I am trying to do something like this:
<td>style="background:url('myimage.jpg') no-repeat;"> + column + </td>
But I get a MySQL error when trying:
Concat ('<td>style="background:url('myimage.jpg') no-repeat;">', info_text, '</td') as Nicetext
I suppose it is all the quotes that mess things up.
Thanks for all help!
Upvotes: 4
Views: 13129
Reputation: 19103
Your strings include quote marks. You will have to escape them. Try something like:
Concat ('<td>style="background:url(\'myimage.jpg\') no-repeat;">', info_text, '</td') as Nicetext
Upvotes: 7
Reputation: 2304
You haven't escaped the quotes. Try this :
Concat ('<td>style="background:url(\'myimage.jpg\') no-repeat;">', info_text, '</td') as Nicetext
Upvotes: 1