philip / MySQLConverterTool

A MySQL Converter Tool
314 stars 144 forks source link

Converter skipped mysql_fetch_object function #14

Closed semoriil closed 8 years ago

semoriil commented 8 years ago

was

$Q=MYSQL_QUERY("SELECT * FROM table WHERE 1 ORDER BY time DESC");

WHILE ($O = MYSQL_FETCH_OBJECT($Q)) {
    ECHO "<br><br><br>" . $O->login . " <br> " . stripslashes($O->text) . " <br> " . DATE('d.m.y H:i:s', $O->time);
}

converted to

$Q=MYSQL_QUERY("SELECT * FROM table WHERE 1 ORDER BY time DESC");

WHILE ($O = MYSQL_FETCH_OBJECT($Q)) {
    ECHO "<br><br><br>" . $O->login . " <br> " . stripslashes($O->text) . " <br> " . DATE('d.m.y H:i:s', $O->time);
}

No changes! Should be just replaced by mysqli_fetch_object (if no other args used).

LukeMcLachlan commented 8 years ago

I've read an issue about uppercase 'MYSQL_QUERY' being ignored, maybe the same issue?

semoriil commented 8 years ago

Yes, that seems to be that case because in many places this function was converted.. And i converted my project three times from beginning, in last attempt i changed mysql_* function names to lowercase and all mysql_fetch_object where converted.

philip commented 8 years ago

This was fixed with pull request #17 -- as semoriil mentioned, it was a case-sensitivity issue.