Warranty
The only warranties for Hewlett Packard Enterprise products and services are set forth in the express warranty statements accompanying such products and services. Nothing herein should be construed as constituting an additional warranty. HPE shall not be liable for technical or editorial errors or omissions contained herein.The information contained herein is subject to change without notice.
Restricted Rights Legend
Confidential computer software. Valid license from HPE required for possession, use or copying. Consistent with FAR 12.211 and 12.212, Commercial Computer Software, Computer Software Documentation, and Technical Data for Commercial Items are licensed to the U.S. Government under vendor's standard commercial license.
Copyright Notice
© Copyright 2017 Hewlett Packard Enterprise Development LP
Trademark Notices
Adobe™ is a trademark of Adobe Systems Incorporated.
Apache® Hadoop® and Hadoop are either registered trademarks or trademarks of the Apache Software Foundation in the United States and/or other countries.
Microsoft® and Windows® are U.S. registered trademarks of Microsoft Corporation.UNIX® is a registered trademark of The Open Group.
This product includes an interface of the 'zlib' general purpose compression library, which is Copyright © 1995-2002 Jean-loup Gailly and Mark Adler.
HPEVerticaAnalyticDatabase(8.1.x)Page2of36
Contents
About This Document
Get Started with the Vertica Community Edition VMThe Vertica Client Tools
Get Started With Management Console
View the Management Console Home Page
View High-Level Details About Databases and ClustersView VMart StatusWhy Is Vmart Yellow?Is VMart in Compliance?
Configure the Database and MCQuery Execution
Explain Plans and Query ProfilesExplore the Overview Tab
Learn More About Management ConsoleGet Started with Administration Toolsadmintools GUI: Check the Databaseadmintools GUI: Execute vsql Commands
admintools Command Line: Check the Databaseadmintools Command Line: Access HelpLearn More About Administration ToolsGet Started with vsql
Execute vsql CommandsLoad Online Sales DataLearn More About vsql
4578910111213141517202122232526272829313335
HPEVerticaAnalyticDatabase(8.1.x)Page3of36
VerticaCommunityEditionVMUserGuide
About This Document
The goal of this document is to introduce you to Vertica by guiding you through some common tasks. As you follow along, you will learn how to use the Vertica Management Console, Administration Tools, and vsql.
Documentation references with each example will help you learn how to find the information you need when you need it.
Note: Documentation references are links to the local Vertica documentation in the Vertica Community Edition Virtual Machine. If you read this document outside of the virtual machine environment, the documentation links will not be active.HPEVerticaAnalyticDatabase(8.1.x)Page4of36
VerticaCommunityEditionVMUserGuide
Get Started with the Vertica Community Edition VM
The Vertica Community Edition Virtual Machine (Vertica CE VM) is a pre-configured Linux environment that offers a hands-on introduction to the Vertica Analytic Database. The environment runs locally on your computer and does not require internet access.
Download the Vertica CE VM
If you have not already downloaded the Vertica CE VM, follow these steps: 1. Log in to my.vertica.com. 2. Navigate to the Downloads page. 3. Download the Vertica CE VM OVA file. 4. Open the OVA file in your VM player.
5. Start up the virtual machine. Startup may take some time.
Log In to the Vertica CE VM
Log in to the VM with these credentials:User: Vertica DBAPassword: password
What's in the VM?
When you launch the VM, you will find these components up and running and ready for use:
lVertica Analytic Database Community Edition lVertica VMart example database lVertica Management Console lComplete Vertica documentation set
VMart is fully loaded except for the online_sales fact table and its two unique dimensions. Instructions for loading the missing data are provided as an exercise in the topic Get Started with vsql.HPEVerticaAnalyticDatabase(8.1.x)Page5of36
VerticaCommunityEditionVMUserGuide
Browse the Vertica Documentation
Two icons on the Vertica CE VM desktop provide single-click access to Vertica
documentation. One icon opens the entire Vertica documentation set. The other icon opens the topic on VMart, the Vertica example database. The exercises in this document all use VMart data.
Before starting the exercises, take a few moments to familiarize yourself with the documentation:
lVertica documentation
lIntroducing the VMart Example Database
HPEVerticaAnalyticDatabase(8.1.x)Page6of36
VerticaCommunityEditionVMUserGuide
The Vertica Client Tools
Vertica has a set of client tools for managing your Vertica environment and for querying and managing your data. The interfaces support a full range of tasks, from scripting to generating informative performance charts. Launch from...Manage clusters and databasesVisualize operations and performanceAllow scriptingRun SQLGet startedManagement Console (MC)BrowserYESYESNOQuery Execution tabGet Started With Management ConsoleAdministration Tools (admintools)TerminalYESNOYESvsqlTerminalYESNOYESConnect to Database vsql menu itemcommandGet Started with Administration ToolsGet Started with vsqlTip: See Administration Tools and Management Consolein the Vertica documentation for a detailed comparison of the functionality in Management Console and Administration Tools.HPEVerticaAnalyticDatabase(8.1.x)Page7of36
VerticaCommunityEditionVMUserGuide
Get Started With Management Console
Vertica Management Console (MC) is a user-friendly performance monitoring and management tool that provides a unified view of your Vertica database operations. Using a browser, you can create, import, manage, and monitor one or more databases and their associated clusters. You can also create and manage MC users and map them to Vertica users.
Log In to Management Console
1. Double click the Management Console icon on the VM desktop.
Vertica Management Console opens in a browser at URL address https://127.0.0.1:5450/webui
2. Click the Login button to log in with the credentials supplied in the dialog box:
Username: uidbadminPassword: password
HPEVerticaAnalyticDatabase(8.1.x)Page8of36
VerticaCommunityEditionVMUserGuide
View the Management Console Home Page
The first screen you see when you log in to Management Console is a portal that provides single-click access to the main functional areas of the tool.
Under Recent Databases, we see the VMart example database, which was created and imported into MC as part of VM creation.
NEXT STEP: Click Infrastructure to open the Databases and Clusters page.
HPEVerticaAnalyticDatabase(8.1.x)Page9of36
VerticaCommunityEditionVMUserGuide
View High-Level Details About Databases and Clusters
The Databases and Clusters page provides a high-level view of the databases and
clusters that you can examine and administer within MC. On this page, you can start and stop databases and remove databases from MC. When you remove a database, it still exists but is no longer accessible within MC.
ACTION: Click the VMart database to display information about it.
NEXT STEP: Click View to open the Overview page for VMart.
HPEVerticaAnalyticDatabase(8.1.x)Page10of36
VerticaCommunityEditionVMUserGuide
View VMart Status
The Overview page is a dashboard that displays key indicators about the database, including node status, memory, CPU activity, disk space usage, and query activity.ACTIONS:
lClick the speedometer icon to display the System Health dashboard. lClick the bar chart icon to display the Query Synopsis dashboard.
NEXT STEP: Click the Manage tab.
HPEVerticaAnalyticDatabase(8.1.x)Page11of36
VerticaCommunityEditionVMUserGuide
Why Is Vmart Yellow?
The Manage tab displays a graphical representation of each database node with its IP address, node name, status, hardware detail, and health rating.
MC displays the VMart database in yellow because its status is CRITICAL. Why? The Vertica VM hosts a single node cluster, but a minimum of three nodes is required for high availability. MC considers the status of VMart to be critical, because if the node goes down then the database will be down.
To learn about high availability in Vertica, read the topic on K-Safety in the Vertica documentation.ACTIONS:
For each of the items on the KPI View drop-down list: 1. Select the item.
2. Watch the visuals and values change.
NEXT STEP: Click the License tab to view the status of the license for VMart.
HPEVerticaAnalyticDatabase(8.1.x)Page12of36
VerticaCommunityEditionVMUserGuide
Is VMart in Compliance?
The License tab displays information about database licensing and compliance. On this tab, you can monitor license usage over time and be prepared if expiration is pending or if you're approaching the maximum allowable data size.ACTION: Click the Audit button.Questions:
lWhen does the Vertica Community Edition license expire? lWhat is the maximum allowable data size for this license?
NEXT STEP: Click the Settings tab.
HPEVerticaAnalyticDatabase(8.1.x)Page13of36
VerticaCommunityEditionVMUserGuide
Configure the Database and MC
On the Settings tab, you can set database options and configure several response thresholds in MC. For example, you can set the Tuple Mover interval in the database, and you can configure MC to raise an alert when memory usage on the node reaches a certain percentage.
ACTIONS: Click each option on the side menu and note the controls and settings for each one.
NEXT STEP: Click the Query Execution tab.
HPEVerticaAnalyticDatabase(8.1.x)Page14of36
VerticaCommunityEditionVMUserGuide
Query Execution
After you click the Query Execution tab, the SQL window opens. In this window, you can run SQL statements in the Vertica database. Key components of the SQL window include:
lQuery History—A recall window, where MC saves SQL statements after they are executed. You can recall and rerun any of the SQL stored in the recall window. lEdit window—A window where you can specify SQL statements. You can type SQL, paste it from the recall window, or import it from a file. lExecute Query bar—Click this bar to execute the query in the edit window. lResults window—A window where the results of SQL execution are posted. In this pane, there are also actions you can perform based on SQL results. For example: you can export the results to a csv file.
ACTIONS:
To execute a query from Query History:
1. Click the query labeled query2 to display it in the edit window. 2. Click the Format SQL icon and watch the results.
HPEVerticaAnalyticDatabase(8.1.x)Page15of36
VerticaCommunityEditionVMUserGuide
3. Click the Execute Query bar. Observe the results in the results window. 4. Click Auto-Resize all columns to set column widths to the longest value in the
column. 5. Click Export Data to export the query results to a csv file, pipe it directly into
LibreOffice Calc, or save it to a file.To execute a query by typing it in the edit window:
1. Clear the edit window and results window by clicking the Clear button (eraser icon). 2. In the edit window, type:
select version() 3. Click the Execute Query bar.
The version of the Vertica server displays in the results window.
You can type multiple SQL commands in the edit window. Terminate each command with a semicolon. MC parses the commands and executes them individually. Each command has its own result set tab in the results window.To execute a query from a file:
1. Click the eraser icon to clear the edit window and results window. 2. Click the Import SQL Script icon.
3. Select the example_vmart_query_02.sql file and click Open. If the file is not
visible, navigate to /opt/vertica/examples/VMart_Schema.
The file is loaded into the edit window.
4. Click the Execute Query bar to run the SQL and generate the result set in the
results window.NEXT STEPS:
1. Click the Query Profile link in the results window to display the profile associated
with the query you just ran.
The query profile does not display, because profiles are not generated automatically for queries that run in less that one second. 2. To view the profile, click View More Profile Information ..
The Query Plan tab displays.
HPEVerticaAnalyticDatabase(8.1.x)Page16of36
VerticaCommunityEditionVMUserGuide
Explain Plans and Query Profiles
Explain plans and query profiles are useful for performance analysis. You can generate explain plans and query profiles on the Query Plans tab of MC. Follow these steps to profile the query you executed in the previous section, take corrective action, and then verify the results.
1. In the SQL window of the Query Plan tab, observe the text, limit 10000, which
appears at the end of the query. Note: Previously, in the Query Execution tab, you saw the Execution options on the toolbar. One of the execution options is Row Limit. Its default value is 10000. You can modify the value of Row Limit permanently in the Query Execution tab, or you can modify it temporarily by stripping the limit filter out of the query before profiling it in the Query Plan tab.HPEVerticaAnalyticDatabase(8.1.x)Page17of36
VerticaCommunityEditionVMUserGuide
2. Strip limit 10000 from the end of the SQL statement and click the Profile button.
The circle graph and the Path Information section display the query profile. Path Information contains the explain plan with profile detail for disk, memory, network, and time statistics.
3. After you profile the query and review the path information, note that NO
STATISTICS appears in red. Note also the Cost and Rows detail, which is
generated by the Vertica Optimizer. Cost is the estimated cost of the query. Rows is the number of rows to be returned for that specific step of the query execution.
+-JOIN HASH [Semi] [Cost: 1K, Rows: 75K (NO STATISTICS)] (PATH ID: 1)+-- Outer -> JOIN HASH [Anti][NotInAnti] [Cost: 732, Rows: 150K (NO STATISTICS)] (PATH ID: 2)+-- Outer -> STORAGE ACCESS for orders [Cost: 546, Rows: 300K (NO STATISTICS)] (PATH ID: 3)+---> STORAGE ACCESS for vendor_dimension [Cost: 10, Rows: 25 (NO STATISTICS)] (PATH ID: 5)+---> STORAGE ACCESS for store_dimension [Cost: 10, Rows: 125 (NO STATISTICS)] (PATH ID: 7)Without statistics, the optimizer may not plan an efficient execution of the query. 4. Apply statistics as follows:
HPEVerticaAnalyticDatabase(8.1.x)Page18of36
VerticaCommunityEditionVMUserGuide
a. Return to the Query Execution tab.
b. In the edit window, type the following SQL statement:
select analyze_statistics('');(The tick marks in parentheses are single quotation marks.) c. Click the Execute Query bar.
After a few seconds, the statement returns 0 for success. 5. Recall the query labeled query2 and execute it.
6. Return to the Query Profile tab and select View More Profile Information. 7. Strip the limit 10000 from the query and click the Profile button.
Note: The cost values have increased slightly, but the number of rows returned has decreased significantly. This means that the optimizer is doing a more efficient job of returning only rows meeting the filter criteria, which should equate to faster times and less memory usage.NO STATISTICS:
+-JOIN HASH [Semi] [Cost: 1K, Rows: 75K (NO STATISTICS)] (PATH ID: 1)+-- Outer -> JOIN HASH [Anti][NotInAnti] [Cost: 732, Rows: 150K (NO STATISTICS)] (PATH ID: 2)+-- Outer -> STORAGE ACCESS for orders [Cost: 546, Rows: 300K (NO STATISTICS)] (PATH ID: 3)+---> STORAGE ACCESS for vendor_dimension [Cost: 10, Rows: 25 (NO STATISTICS)] (PATH ID: 5)+---> STORAGE ACCESS for store_dimension [Cost: 10, Rows: 125 (NO STATISTICS)] (PATH ID: 7)WITH STATISTICS
+-JOIN HASH [Semi] [Cost: 2K, Rows: 18K] (PATH ID: 1)+-- Outer -> JOIN HASH [Anti][NotInAnti] [Cost: 1K, Rows: 35K] (PATH ID: 2)+-- Outer -> STORAGE ACCESS for orders [Cost: 1K, Rows: 71K] (PATH ID: 3)+---> STORAGE ACCESS for vendor_dimension [Cost: 35, Rows: 3] (PATH ID: 5)+---> STORAGE ACCESS for store_dimension [Cost: 35, Rows: 16] (PATH ID: 7)HPEVerticaAnalyticDatabase(8.1.x)Page19of36
VerticaCommunityEditionVMUserGuide
Explore the Overview Tab
Now that we've seen some of the capabilities of MC, let's take a look at the Overview tab. In this tab, you can see summarized information about the database. Some of the items on this tab are actually links; you can click them to display additional details. You can learn more about other items by hovering your mouse over them.ACTIONS:
1. At the bottom of the page, click the Overview tab.
The Status Summary page appears.
2. In the CPU/Memory/Disk I/O section, hover over the Avg Mem Usage (%) line in
the line graph. 3. Observe the additional details for this point in time.
4. Click a point in the timeline to open an exploded view of this time. 5. Click the Back arrow in your browser to return to the Status Summary page.
HPEVerticaAnalyticDatabase(8.1.x)Page20of36
VerticaCommunityEditionVMUserGuide
Learn More About Management Console
To learn more about the Vertica Management Console, see these topics in the Vertica documentation:
lManagement Console lUsing Management Console
HPEVerticaAnalyticDatabase(8.1.x)Page21of36
VerticaCommunityEditionVMUserGuide
Get Started with Administration Tools
The Administration Tools interface allows you to manage your Vertica environment from a Linux shell.
You can use Administration Tools within an interactive graphical user interface, or you can use the command line. The command line is useful for scripting.
Tip: The vsql commands in these examples are stored in the command history buffer in the VM. Instead of typing a command, you can press the Up arrow and select it from the list.Start the Administration Tools GUI
1. Right-click the desktop and select Open Terminal. 2. At the Linux command line, type admintools.
The Main Menu displays.
HPEVerticaAnalyticDatabase(8.1.x)Page22of36
VerticaCommunityEditionVMUserGuide
admintools GUI: Check the Database
1. To see if the database is up, select option 1 View Database Cluster State and click
OK.
The database status displays. We see that the VMart database is up and that all host computers are running.
2. To return to the Main Menu, click OK.To view details about the database:
1. To view details about the database, select option 6 Configuration Menu and click
OK.
HPEVerticaAnalyticDatabase(8.1.x)Page23of36
VerticaCommunityEditionVMUserGuide
2. On the Configuration Menu, select option 3 View Database and click OK.
3. On the Select database to view screen, press the space bar to select VMart and
click OK.
Details about the VMart database display.
4. Click OK.
5. Scroll to option M Main Menu, then click OK.
HPEVerticaAnalyticDatabase(8.1.x)Page24of36
VerticaCommunityEditionVMUserGuide
admintools GUI: Execute vsql Commands
1. To run sql statements against the database using the vsql command line, select
option 2Connect to Database and click OK. 2. Type the password for connecting to the VMart database and click OK.
The password is password.
The vsql prompt displays.
3. To display the version of vsql, type select version();as shown:
VMart=> select version();versionVertica Analytic Database V8.1.1.-20170424(1 row) 4. To exit vsql and return to the Administration Tools GUI, type \\q.
Exit the Administration Tools GUI
To exit the Administration Tools GUI, select option E Exit and click OK.
HPEVerticaAnalyticDatabase(8.1.x)Page25of36
VerticaCommunityEditionVMUserGuide
admintools Command Line: Check the Database
To check database status and details using the Administration Tools command line: 1. Right-click the desktop and select Open Terminal.
2. To check if the database is up, type the following command at the Linux command
prompt:
[dbadmin@localhost ~]$ admintools -t db_status -s UPThis command returns the following, indicating that the VMart database is running:
VMart 3. To view details about the database, type this command:
[dbadmin@localhost ~]$ admintools -t list_db -d VMartThis command returns the following:
Database: VMartDatabase Log: /vertica/data/VMart/dbLog, /vertica/data/VMart/v_vmart_node0001_catalog/vertica.logHosts: 127.0.0.1Restart Policy: alwaysPort: 5433Catalog Directory: /vertica/data/VMart/v_vmart_node0001_catalog[dbadmin@localhost ~]$HPEVerticaAnalyticDatabase(8.1.x)Page26of36
VerticaCommunityEditionVMUserGuide
admintools Command Line: Access Help
1. To access admintools Help, type this command:
[dbadmin@localhost ~]$ admintools --helpThis command returns the following:
Usage: admintools [options]Options:-h, --help Display this help. Can be combined with -t node tool: [dbadmin@localhost ~]$ admintools -t list_node –helpThis command returns the following: Usage: admintools [options]Usage: list_node [options]Options:-h, --help show this help message and exit-n NODENAME, --node=NODENAMEName of the node to be listedHPEVerticaAnalyticDatabase(8.1.x)Page27of36 VerticaCommunityEditionVMUserGuide Learn More About Administration Tools To learn more about the Vertica Administration Tools, see these topics in the Vertica documentation: lAdministration Tools lUsing the Administration Tools HPEVerticaAnalyticDatabase(8.1.x)Page28of36 VerticaCommunityEditionVMUserGuide Get Started with vsql vsql is a character-based, interactive utility that lets you type SQL statements and see the results. vsql also provides meta-commands and several shell-like features for writing scripts and automating various tasks. Tip: The vsql commands in these examples are stored in the command history buffer in the VM. Instead of typing a command, you can press the Up arrow and select it from the list.Start vsql 1. Right-click the desktop and select Open Terminal. 2. Change to the directory that contains the VMart example scripts used in this exercise: [dbadmin@localhost ~]$ cd /opt/vertica/examples/VMart_Schema 3. Start vsql and type password for the password: [dbadmin@localhost VMart_Schema]$ vsqlPassword:The following text displays: Welcome to vsql, the Vertica Analytic Database interactive terminal.Type: \\h or \\? for help with vsql commands\\g or terminate with semicolon to execute query\\q to quitDisplay a List of vsql Commands 1. To display a list of vsql commands, type \\? as shown: dbadmin=> \\?The following output displays: See the Vertica Programmer's Guide for information on available commands.GeneralHPEVerticaAnalyticDatabase(8.1.x)Page29of36 VerticaCommunityEditionVMUserGuide \\c[onnect] [DBNAME|- [USER]]connect to new database (currently \"dbadmin\")\\cd [DIR] change the current working directory\\q quit vsql\\set [NAME [VALUE]]set internal variable, or list all if no parameters\iming [on|off]toggle timing of commands, or explicitly turn it on or off (currentlyoff)... 2. To view more output, press the space bar. 3. To quit displaying output, type q. HPEVerticaAnalyticDatabase(8.1.x)Page30of36 VerticaCommunityEditionVMUserGuide Execute vsql Commands 1. Type \\d to see a list of user tables: dbadmin=> \\dThe list of tables displays: List of tablesSchema | Name | Kind | Owner | Comment-------------+----------------- -----+-------+---------+--------online_sales | call_center_dimension | table | dbadmin |online_sales | online_page_dimension | table | dbadmin |online_sales | online_sales_fact | table | dbadmin |public | customer_dimension | table | dbadmin |public | date_dimension | table | dbadmin |public | employee_dimension | table | dbadmin |public | inventory_fact | table | dbadmin |public | product_dimension | table | dbadmin |public | promotion_dimension | table | dbadmin |public | shipping_dimension | table | dbadmin |public | vendor_dimension | table | dbadmin |public | warehouse_dimension | table | dbadmin |store | store_dimension | table | dbadmin |store | store_orders_fact | table | dbadmin |store | store_sales_fact | table | dbadmin |(15 rows)Note: \\d is an example of a meta-command in vsql. Meta-commands begin with an unquoted backslash character and are processed by vsql itself. These commands help make vsql more useful for administration or scripting.See Meta-Commands in the Vertica documentation for details. 2. Type \\ds to see a list of system tables: dbadmin=> \\dSThe list of system tables displays: HPEVerticaAnalyticDatabase(8.1.x)Page31of36 VerticaCommunityEditionVMUserGuide List of tablesSchema | Name | Kind | Description |Comment----------+----------------- +-------+----------------------------------------------------+------v_catalog |access_policy |system |Access Policy information |v_catalog |all_tables |system |A complete listing of all tables and views |v_catalog |client_auth |system |Client Authentication Detailed information |v_catalog |client_auth_params|system |Client Authentication Paramters |v_catalog |cluster_layout |system |Current cluster layout with relative order of nodes |v_catalog |columns |system |Table column information |v_catalog |comments |system |User comments on catalog objects |v_catalog |constraint_columns|system |Table column constraint information |v_catalog |databases |system |Database information |v_catalog |directed_queries |system |Directed queries |....To view more output, press the space bar. To quit displaying output, type q. 3. Query the system table projection_storage as shown: dbadmin=> select projection_name,sum(row_count) from projection_storage where projection_schema = 'online_sales' group by projection_schema,projection_name order by sum(row_count);The query returns the following: projection_name | sum-----------------------------+-----online_page_dimension_super | 0call_center_dimension_super | 0online_sales_fact_super | 0(3 rows)HPEVerticaAnalyticDatabase(8.1.x)Page32of36 VerticaCommunityEditionVMUserGuide Load Online Sales Data Follow these steps to load data into the online-sales fact table and its two unique dimensions: 1. View the content of the external SQL script called vmart_load_online_sales_ data.sql. Tip: Press the Up arrow to execute this command from History.dbadmin=> \\! cat /opt/vertica/examples/VMart_Schema/vmart_load_online_sales_data.sqlThe content of the SQL script file displays: \\set t_pwd 'pwd'\\set input_file '''':t_pwd'/Online_Page_Dimension.tbl'''COPY online_sales.Online_Page_Dimension FROM :input_file DELIMITER '|' NULL '' DIRECT;\\set input_file '''':t_pwd'/Call_Center_Dimension.tbl'''COPY online_sales.Call_Center_Dimension FROM :input_file DELIMITER '|' NULL '' DIRECT;\\set input_file '''':t_pwd'/Online_Sales_Fact.tbl'''COPY online_sales.Online_Sales_Fact FROM :input_file DELIMITER '|' NULL '' DIRECT; 2. Run the external SQL script to load the data: dbadmin=> \\i /opt/vertica/examples/VMart_Schema/vmart_load_online_sales_data.sqlThe script loads the data and displays the following: Rows Loaded-------------1000(1 row)Rows Loaded-------------200(1 row)Rows Loaded-------------1000000(1 row) 3. Rerun the query of the system table projection_storage to see the effect of the HPEVerticaAnalyticDatabase(8.1.x)Page33of36 VerticaCommunityEditionVMUserGuide data load. Tip: Press the Up arrow to execute this command from History..dbadmin=> select projection_name,sum(row_count) from projection_storage where projection_schema = 'online_sales' group by projection_schema,projection_name order by sum(row_count);The query returns the following: projection_name | sum-----------------------------+---------call_center_dimension_super | 200online_page_dimension_super | 1000online_sales_fact_super | 1000000(3 rows)Exit vsql To exit vsql, type \\q: dbadmin-> \\qAfter you exit vsql, the Linux command prompt displays: [dbadmin@localhost VMart_Schema]$HPEVerticaAnalyticDatabase(8.1.x)Page34of36 VerticaCommunityEditionVMUserGuide Learn More About vsql To learn more about vsql, see the following topics in the Vertica documentation: lUsing vsql lSQL in Vertica HPEVerticaAnalyticDatabase(8.1.x)Page35of36 VerticaCommunityEditionVMUserGuide HPEVerticaAnalyticDatabase(8.1.x)Page36of36 因篇幅问题不能全部显示,请点此查看更多更全内容