In the Command Line Utility, use the recommendation-only
output mode
to view only the analytical view statements.
In the recommendation-only
mode you can view only the recommendatons. the
aview create statements, and syntax of the input query. This ouptut format makes it easy for
the admins to simply copy the output and use it in their environment to accelerate apps.
To view a brief summary of the analytical view recommendations, syntax of the input query, and the recommendaion status, use the Default Output Mode. For detailed information about the analytical view recommendations and the input query, including the information of the base tables, use the Verbose Output Mode.
To display analytical view recommendations in recommendation-only
mode,
follow these instructions:
To see the output in Recommendation only
mode, enter a command with the
following syntax, either the long or short form.
./arcviz util recommendation --dcname=<data_connection_name> --file=<file_path to the queries file> --recommendation_only
./arcviz util recommendation --dcname=<<data_connection_name> --file=<file_path> -r
<aview create statement_1>
<aview create statement_2>
...
<aview create statement_n>
In our example, name of the data connection is Recommendation and queries are accessed from the text.txt file.
The
output only shows the recommended aviews with the CREATE ANALYTICAL VIEW
statements, and has the following information:
Name of the base table that appears in the form database_name.table_name
.
In our example, it is test
.
Names of the recommended aviews. . In our example, it is
recommended_aview_1
and recommended_aview_2
.
Format of the base table. In our example, it is PARQUET
.
Syntax of the select query. In our example, it is SELECT avg(f), c, count(a), e
FROM test.recom1 GROUP BY c,
e;
./arcviz util recommendation --dcname=Recommendation --file=/var/lib/arcadia/test.txt —recommendation_only
CREATE ANALYTICAL VIEW `test`.`recommended_aview_1` STORED AS PARQUET AS SELECT c, count(a), d, sum(b) FROM test.recom1 GROUP BY c, d;
CREATE ANALYTICAL VIEW `test`.`recommended_aview_2` STORED AS PARQUET AS SELECT avg(e), g, h, ndv(f) FROM test.recom1 GROUP BY g, h;