In PHP, I need something like this:
1) if('out of space' == mysql_error($link))
2) if(10 == mysql_error($link))
3) if(true == mysql_error('out of space'))
4) if(... whatever ....)
5) if(1024 == mysql_errno($link))
{
echo 'DB is out of space';
}
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You’re probably looking for errno code 1021 (ER_DISK_FULL) and/or 1041 (ER_OUT_OF_RESOURCES)
see also
https://dev.mysql.com/doc/refman/5.0/en/error-messages-server.html#error_er_disk_full
https://dev.mysql.com/doc/refman/5.0/en/error-messages-server.html#error_er_out_of_resources
(and maybe 1037, 1038)