Explore Your Connect Environment

Show Schemas

To retrieve the list of schemas within a given environment, use SHOW SCHEMAS.

show schemas;

show_schemas

Four schemas are available by default:

  • delta: Developers can create custom tables here. CRUD (Create, Read, Update, and Delete) operations are supported. Custom tables can serve to store data temporarily or permanently.
    Important: These tables are not available for display in the Incent UI or from Incent rules.
  • staging: Preconfigured staging tables provide an interface for importing different types of customer source data into Incent, including sales orders and HR data. (list)
  • xactly: Provides read-only access to Incent application tables. (list)
  • xdms: Contains tables used for querying DELTA Portal button metadata and parameters found  in the Incent UI.

 

Show Tables

To retrieve the list of tables within a given environment, use SHOW TABLES.

show tables;

show_tables

Filter SHOW TABLES Results

Because SHOW commands return result sets, it is straightforward to return only specific columns or rows from a SHOW command’s results.

For example, to return just the list of tables in the xactly schema, use:

select schema_name, name 
from (show tables) 
where schema_name = 'xactly';

show_tables_filtered

Show a Specific Table

To retrieve a specific table, use SHOW TABLE with the schema name and that table’s name. For example:

show table xactly.xc_period;

Use this to narrow results to that table in other calls. For example, to retrieve the list of column names in a given table, use:

select schema_name, table_name, column_name, odbc_type_name 
from (show table xactly.xc_period);

show_table_xc_period

Describe a Table

The DESCRIBE command returns metadata about a table or result set. You can use it with the schema and table names as an alternative to SHOW TABLE schema_name.table_name:

describe select * from xactly.xc_participant;

describe

Show Data Types

To retrieve the list of data types that are supported in Connect, use SHOW TYPES.

show types;

For example, to show the list of type names, type numbers, and corresponding ODBC type names (when applicable), use:

select type_name, data_type, odbc_type_name
from (show types);

show_types

Show Variables

You can set and unset variables for use in your xSQL and xCL interactions with Connect. To retrieve a list of the variables that are defined in a given environment, use SHOW VARIABLES. Your environment may not have any variables defined yet. Run the command and see!

show variables;

show_variables

 

For instructions on setting and reusing variables, see Create and Use Global Variables.