Skip to main content

Using InterSystems SQL

InterSystems SQL provides a full set of standard relational features, including the ability to define table schema, execute queries, and define and execute stored procedures. You can execute InterSystems SQL interactively from the Management Portal or programmatically from using a SQL shell interface. Embedded SQL enables you to embed SQL statements in your ObjectScript code, while Dynamic SQL enables you to execute dynamic SQL statements from ObjectScript at runtime.

Get Started

Topics

InterSystems SQL Syntax

  • Language Elements describes InterSystems SQL handling of literals, NULL, operators, and comments.

  • Implicit Joins (Arrow Syntax) provides an InterSystems SQL shorthand extension to perform a left outer join on a column specified in a SELECT clause.

  • Identifiers describes the conventions used for naming entities within InterSystems SQL.

SQL Execution Interfaces

Schema Definitions

  • Defining Tables describes fundamental elements of tables (schema and table names, RowID and Primary Key), and how to define a table in InterSystems SQL, either by defining a persistent class or by using DDL commands.

  • Defining and Using Views describes how to define views and the view ID (%VID) in InterSystems SQL.

  • Relationships Between Tables describes how to define and maintain foreign keys and parent/child relationships in InterSystems SQL.

  • Using Triggers describes triggers that are automatically executed when a record is added, modified, or deleted in InterSystems SQL.

  • Collation describes collation types that specify how data values are ordered and compared in InterSystems SQL.

Data Management and Queries

SQL Security

  • Users, Roles, and Privileges describes security features of InterSystems SQL, including defining users, associating users with roles, and assigning privileges to a user or a role.

SQL Import/Export

  • Importing SQL Code describes how to import and execute SQL code from a text file, either InterSystems SQL or SQL code from other vendors.

  • Importing and Exporting SQL Data describes InterSystems SQL tools to import data from a text file to a table and to export data from a table to a text file.

Feedback