-
Notifications
You must be signed in to change notification settings - Fork 41
Sql4DClient
srikalyan chandrashekar edited this page Jun 24, 2015
·
8 revisions
-
mvn clean install.
-
Edit dsql(replace the broker, coordinator, proxy name) .
-
Run dsql from a terminal.
-
Type help; (or) any queries if you have a druid cluster setup.
1. select queries (GroupBy, TimeSeries, TopN, Select, Search). See wiki for examples: https://github.com/srikalyc/Sql4D/wiki/Sql4DCompiler
2. generatebean=BeanName (This command must be preceding a SQL, it generates a java source file BeanName.java which extends DruidBaseBean.
3. trace=[true|false] (When enabled prints out compiled JSON query)
4. querymode=[sql|json] (Default is sql, when mode is json it is fired directly)
5. show tables (Displays all the datasources)
6. describe TableName (Displays the given datasource's schema)
7. quit (Exits client)
All commands are terminated by ;
1) History navigation(Cntrl-Up / Cntrl-Down).
2) Pretty print output with query time and resultset size.
3) Query mode =sql/json(yes you can also directly query using json)
4) trace to see the compiled Json query.
5) Generate a Bean for the most recently run Sql command.
6) Describe datasource/table.
7) List all data sources in the druid cluster.