Add support for Presto - common classes#884
Merged
mrigger merged 1 commit intosqlancer:mainfrom Aug 24, 2023
axiomq:presto-common-classes-updates
Merged
Add support for Presto - common classes#884mrigger merged 1 commit intosqlancer:mainfrom axiomq:presto-common-classes-updates
mrigger merged 1 commit intosqlancer:mainfrom
axiomq:presto-common-classes-updates
Conversation
Merged
mrigger
reviewed
Aug 23, 2023
Contributor
mrigger
left a comment
There was a problem hiding this comment.
The changes look good in general. Thanks a lot! Could you have a look at my two minor comments to see whether they make sense?
To implement support for Presto some changes in common
classes are required.
## Changes in common classes:
1. class sqlancer.MainOptions - added global parameters :
* canonicalizeString (boolean) - presto doesn't support JDBC
queries with ";" at the end of statement
* compareResultsContent (boolean) - comparing content of
VARBINARY columns fails
2. class sqlancer.ComparatorHelper - compare result based on parameter
```
boolean compare = state.getOptions().compareResultsContent();
if (compare && !firstHashSet.equals(secondHashSet)) {
```
3. sqlancer.common.query.SQLancerResultSet - added method:
```
public String getType(int i) throws SQLException {
return rs.getMetaData().getColumnTypeName(i);
}
```
4. sqlancer.common.query.SQLQueryAdapter : added constructor
```
public SQLQueryAdapter(String query, ExpectedErrors expectedErrors,
boolean couldAffectSchema, boolean canonicalizeString) {
```
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
To implement support for Presto some changes in common classes are required.
Changes in common classes: