shardingsphere icon indicating copy to clipboard operation
shardingsphere copied to clipboard

How can i start sql parser test for specific db?

Open makssent opened this issue 2 years ago • 2 comments

image image

Running tests in the shardingsphere. How do I check the tests against a specific database like I did in the issue:

https://github.com/apache/shardingsphere/issues/6976

There was a line like this regarding the SQL92 database:

update_with_where_calculation (Placeholder) -> SQL92

As I understand they in this ticket build the project completely and get errors, can this be done by building a specific test module for a specific database? I mean it/parser tests ONLY for SQL92

They also gave errors, I need to implement the same, in the documentation I did not see how to do it:

line 1:7 no viable alternative at input 'CREATEINDEX'
line 1:7 no viable alternative at input 'CREATEINDEX'
line 1:7 no viable alternative at input 'CREATEINDEX'
line 1:7 no viable alternative at input 'CREATEINDEX'
line 1:145 no viable alternative at input 'HASH'
line 1:145 mismatched input 'HASH' expecting {LINEAR, LIST, RANGE}
line 1:7 no viable alternative at input 'CREATEUNIQUE'
line 1:7 no viable alternative at input 'CREATEUNIQUE'
line 1:7 no viable alternative at input 'CREATEUSER'
line 1:7 no viable alternative at input 'CREATEUSER'
line 1:7 no viable alternative at input 'CREATEUSER'
line 1:7 no viable alternative at input 'CREATEUSER'
line 1:0 no viable alternative at input 'TRUNCATE'

makssent avatar Oct 21 '24 08:10 makssent

If I add an additional parameter to the test case, it just skips and doesn't give any error image image image

227 tests passed, before the change it was 229.

image

makssent avatar Oct 21 '24 09:10 makssent

I think I got it. I'll come back later if I need to.

makssent avatar Oct 21 '24 09:10 makssent