sudoconf / php-sql-parser

Automatically exported from code.google.com/p/php-sql-parser
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

ORDER BY fails with `s around the column name #80

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. SELECT * FROM `model` WHERE `marker`='this_model' ORDER BY `test`";

What is the expected output? What do you see instead?

Should parse ok. Throws UnableToCalculatePositionException.

What version of the product are you using? On what operating system?

CentOS, latest

Original issue reported on code.google.com by rick.he...@mayden.co.uk on 30 Nov 2012 at 2:57

GoogleCodeExporter commented 9 years ago
I traced this back to line 1044 in php-sql-parser.php . If you comment this 
out, it works. Not sure what other problems it might cause tho! But so far this 
seems to work fine for me. You might want to just remove the 
$this->revokeEscaping(...) and keep the trim(...).

Original comment by paans...@gmail.com on 8 May 2013 at 2:33

GoogleCodeExporter commented 9 years ago
I have fixed that issue in r385.

Original comment by pho...@gmx.de on 1 Nov 2013 at 3:41

GoogleCodeExporter commented 9 years ago

Original comment by pho...@gmx.de on 1 Nov 2013 at 3:46