This is ANSI standard SQL behaviour, NULL has a specific meaning, not the same as empty!
As the MySQL docs say ...
The concept of the NULL value is a common source of confusion for newcomers to SQL, who often think that NULL is the same thing as an empty string "". This is not the...
Problem solved! Turns out to be a wierd php problem, not MySQL at all.
If you're interested, the solution was to not connect to the db using a function, but to connect (mysql_pconnect/mysql_select_db) in the actual script.
Same code, just doesn't work if it's executed in a function. Wierd...
I have developed a PHP/MySQL driven website, and I want the site administrator to be able to back the db up when they want. It's all running on a hosting service.
The solution I came up with was when the administrator requests a backup:
1) create a new directory with name=timestamp
2) for each...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.