I want to do something like this:
while(false == ($result = mysql_query($query)) ) {
switch(mysql_errno()) {
case $fixableError[0]:
case $fixableError[1]:
/* fix the errors */
break;
default:
die ("Fatal error in '$query': " . mysql_error() );
break;
}
}
But I haven't found a satisfactory reference to the error codes. My
googling has returned tonnes of references to files in the PHP source,
but I'm not willing to download the source files and I doubt that
they'd have the kind of error descriptions that would be useful (like,
suggestions on how to avoid the error).
So can someone supply an address to a reference list of these error
numbers?
Also, would the syntax in the "while" clause above work in PHP?
TIA,
Will