Last active
December 22, 2015 10:19
-
-
Save nileema/6458383 to your computer and use it in GitHub Desktop.
This file contains 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
select * from foo tablesample system (10) | |
(QUERY | |
(QUERY_SPEC | |
(select (SELECT_LIST ALL_COLUMNS)) | |
(from | |
(SAMPLED_RELATION | |
(TABLE (QNAME foo)) system 10)))) | |
Query{queryBody=QuerySpecification{select=Select{distinct=false, selectItems=[*]}, from=[SampledRelation{relation=Table{foo}, type=SYSTEM, samplePercentage=10}], where=null, groupBy=[], having=null, orderBy=[], limit=null}, orderBy=[]} | |
SELECT * | |
FROM foo | |
TABLESAMPLE SYSTEM (10) | |
============================================================ | |
select * from foo tablesample system (10) join bar tablesample bernoulli (30) on a.id = b .id | |
(QUERY | |
(QUERY_SPEC | |
(select (SELECT_LIST ALL_COLUMNS)) | |
(from | |
(QUALIFIED_JOIN INNER_JOIN | |
(on | |
(= (QNAME a id) (QNAME b id))) | |
(SAMPLED_RELATION | |
(TABLE (QNAME foo)) system 10) | |
(SAMPLED_RELATION | |
(TABLE (QNAME bar)) bernoulli 30))))) | |
Query{queryBody=QuerySpecification{select=Select{distinct=false, selectItems=[*]}, from=[Join{type=INNER, left=SampledRelation{relation=Table{foo}, type=SYSTEM, samplePercentage=10}, right=SampledRelation{relation=Table{bar}, type=BERNOULLI, samplePercentage=30}, criteria=JoinOn{("a"."id" = "b"."id")}}], where=null, groupBy=[], having=null, orderBy=[], limit=null}, orderBy=[]} | |
SELECT * | |
FROM (foo | |
TABLESAMPLE SYSTEM (10) | |
INNER JOIN bar | |
TABLESAMPLE BERNOULLI (30) ON (("a"."id" = "b"."id"))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment