mirror of
https://github.com/minio/minio.git
synced 2024-12-26 23:25:54 -05:00
bd56f80250
The SQL parser as it stands right now ignores alias for aggregate result, e.g. `SELECT COUNT(*) AS thing FROM s3object` doesn't actually return record like `{"thing": 42}`, it returns a record like `{"_1": 42}`. Column alias for aggregate result is supported in AWS's S3 Select, so this commit fixes that by respecting the `expr.As` in the expression. Also improve test for S3 select On top of testing a simple `SELECT` query, we want to test a few more "advanced" queries (e.g. aggregation). Convert existing tests into table driven tests[1], and add the new test cases with "advanced" queries into them. [1] - https://github.com/golang/go/wiki/TableDrivenTests |
||
---|---|---|
.. | ||
jsondata | ||
aggregation.go | ||
analysis.go | ||
errors.go | ||
evaluate.go | ||
funceval.go | ||
jsonpath_test.go | ||
jsonpath.go | ||
parser_test.go | ||
parser.go | ||
record.go | ||
statement.go | ||
stringfuncs_test.go | ||
stringfuncs.go | ||
timestampfuncs_test.go | ||
timestampfuncs.go | ||
utils.go | ||
value.go |