Database Reference
In-Depth Information
# Capture to /home/username/Desktop/testqueries.txt
CAPTURE '/home/username/Desktop/testqueries.txt'
# Turn off capturing
CAPTURE OFF
ASSUME
The ASSUME command is a feature from past versions. With the CQL definition, one does
not need to explicitly set column types to view the result. The ASSUME command is used
to tell the CQL shell to treat column names as a certain data type, or treat column values
as a certain data type.
Here's an example where a table tabx is set to interpret the column names and values as
various types:
# Treat column names as int and values as text
ASSUME tabx NAMES ARE int, VALUES ARE text;
# Treat the tabid column as UUID
ASSUME tabx(tabid) VALUES ARE uuid
SOURCE
The SOURCE command like the MySQL SOURCE command reads the contents of a file
and tries to execute it. So, one can have a bunch of CQL statements in the file and then
call the SOURCE command with the file location, and the CQL shell will execute it:
# Execute the contents of /home/username/Desktop/
create_dev_envt.txt
SOURCE '/home/username/Desktop/create_dev_envt.txt'€
SHOW
The SHOW command displays system information. There are three variants of this com-
mand:
SHOW VERSION;
SHOW HOST;
SHOW ASSUMPTIONS;
Search WWH ::




Custom Search