I tried to create a .php which should send a statement to my local MySQL. The connection works fine and the statement is successfully run but returns NULL. When executing the statement via cmd itreturns the right resultset.
Is there the possibility of the same statement returning different resultsets determined by the fact wheather it was sent by a php script or were executed directly via a .sql file?
Cheers,
Uno
thank you for your quick answers and comments. I was able to solve the issue in the meantime.
It's similar to:
Pasted MySQL Select Statement Returns Empty Set, but Manual Select Works Fine
but was about MySQL expecting Latin1 typeset and HTML sending Unicode strings.
utf8_decode() was the key to success:
http://php.net/manual/en/function.utf8-decode.php
------------------------------------------------------------------------------------------------------------------------------------
Question: Does anyone know why MySQL just ignores UTF-8 Strings instead of returning something like 'bla bla latin1 coded String expected bla bla'?