DatabaseExplorer - SQL Parsing Issues

Discussion about CodeLite development process and patches
chaddcw
CodeLite Curious
Posts: 1
Joined: Tue Jun 13, 2017 10:23 pm
Genuine User: Yes
IDE Question: C++
Contact:

DatabaseExplorer - SQL Parsing Issues

Post by chaddcw »

I've been working with MySQL and SQLite (on Linux) via the SqlCommandPanel and have found a number of SQL parsing errors. I've also got fixes for some of the following bugs.

What is the preferred process to handle this? Should I open Issues on GitHub and then make pull requests against those?

I've outlined my findings below.


1) History is not updated correctly in SQLCommandPanel if ; appears in a search string and comments are not always removed.

Code: Select all

select * from People where LName not like '%a%'; -- test comment
select * from People where LName not like '%;%';
2) Unicode in SQL statements is not handled correctly in MysqlDatabaseLayer

Code: Select all

select * from People where LName not like '%☺%'; 

3) A Comment at the end of a SQL statement is not filtered out correctly by SQLCommandPanel::ExecuteSQL() and is not filtered out by DatabaseQueryParser.cpp (maybe could be fixed by using the new, fixed output of ParseSql() from the solution to 1)

Also,

Code: Select all

 "%;%"
is parsed incorrectly in DatabaseQueryParser.cpp

Code: Select all

	select * from People; -- TEST
	select * from People where LName not like "%;%";
User avatar
eranif
CodeLite Plugin
Posts: 6375
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: DatabaseExplorer - SQL Parsing Issues

Post by eranif »

GitHub pull request is the best way
Make sure you have read the HOW TO POST thread
Post Reply