Newletter Sign Up
Posts on the
Design Decomposition Blog
Iridium Satellite Collision in Space
You might have seen the recent news reports about the collision between U.S. and Russian communication satellites. The U.S. satellite was one of the Iridium satellites. What wasn’t reported and you probably don’t know is that an object database management system (ODBMS) is an important part of the Iridium system. Even though ODBMSs are a [...]
February 13, 2009
(The Acronym) SOA is (Perhaps) Dead (at Some Companies); Long Live Services
I am now also posting on the Cutter Blog. My initial posting is (The Acronym) SOA is (Perhaps) Dead (at Some Companies); Long Live Services. It is a response to Anne Thomas Manes’ SOA is Dead; Long Live Services on her blog at the Burton Group.
January 9, 2009
Atomicity
The typical definition of an atomic task or process is one that cannot be decomposed further. This is vague and subject to interpretation. The Decomposition Matrix on this site uses a specific definition: A task (for business process diagrams) or a process (for data flow diagrams) is atomic if every input relates to every output [...]
December 3, 2008
Well-Formed Business Process Diagrams
My last posting referenced the criteria for a well-formed business process diagram mentioned in Business Process Driven SOA using BPMN and BPEL by Matjaz B. Juric and Kapil Pant. I am going to expand on their criteria to create a more comprehensive definition of a well-formed business process diagram. To start, here are three criteria [...]
November 18, 2008
Recent Business Process Modeling Books
I recently received two new books on business process modeling. Both books looked interesting because they had great titles. As it turns out, one book is great and the other not so good. The not so good book is Business Process Driven SOA using BPMN and BPEL by Matjaz B. Juric and Kapil Pant. There [...]
October 9, 2008
The Design Decomposition Blog
is written by Doug Barry.
INCITS

SQL:1999 was developed by the INCITS Technical Committee H2 on Database. This committee develops standards for the syntax and semantics of database languages.

SQL:1999¹ specifies the SQL:1999 object model. It adds User Defined Types (UDTs) to SQL. There are two types of UDTs: distinct types and structured types. A distinct type is based on a built-in data type, such as INTEGER, but whose values cannot be directly mixed in operation with that built-in type. A structured type has an internal structure such as an address type that might have street, state, and postal code attributes as part of the structure. Structured types can be given specific user-defined functions and participate in type hierarchies with other structured types. Single inheritance is supported. Multiple inheritance of interfaces (as in Java) is not supported. Both distinct and structured types can be used as the data type for columns, SQL variables, a field of a row type, or as attribute of another UDT. Java objects can be either stored in a serialized byte stream as an SQL BLOB (Binary Large OBject) or mapped to a row in typed tables. With the SQL BLOB approach, an object is stored in a cell of a table or stored as a UDT in a cell of a table. It is possible to define methods that operate on the object using either approach.

The SQL:1999 object model also allows you to declare that a UDT is the type of an entire table. Each row is an instance of the type. Each attribute of the type is transformed into a column of the table. The methods associated with the type are also associated with the table. Typed tables can have an additional self-referencing column. This is similar to the object identification (OID) used in classical object models. See object identification (new window). The self-referencing column holds a value that uniquely identifies that row of the table. In SQL:1999, instead of using the term OID, it uses REF value with a special data type called REF type. One type can contain a REF to another type, similar to the way OIDs are used in object models. REFs can only reference rows in typed tables and cannot reference type instances in cells of a table, in variables, or anywhere else.

The SQL:1999 object model also provides for table hierarchies in addition to type hierarchies. The relationships of the table hierarchy and the type hierarchy are not necessarily one-to-one. Basically, table hierarchies allow you to modify the behavior and appearance of the default behavior for typed tables. For example, most object models assume that if you query a super type, you will also get results from any of its subtypes. Table hierarchies allow you to modify that behavior so that when you query on the super type, you do not get results from any of its subtypes.

With SQL:1999 you have multiple ways to model your data:

  1. Regular SQL tables and columns of built-in types
  2. Regular SQL tables with some columns of built-in types and some of UDTs
  3. Regular SQL tables with one column whose data type is a UDT
  4. Typed tables

SQL:1999 is also used by SQLJ Part 2. See SQLJ (new window).

Because of backward compatibility to SQL-92, SQL:1999 supports a database sublanguage. This results in a programming style illustrated by the embedded SQL statements in the following diagram. 

Embedded database sublanguage

An example of an embedded SQL statement that creates a new Person instance would be:

EXEC SQL BEGIN DECLARE SECTION;
    char SQLSTATE[6];
    char ssan[9];
    char name[30];
EXEC SQL END DECLARE SECTION

EXEC SQL
INSERT INTO person VALUES (:ssan, :name);

This code would be in addition to any host programming code. The variables :ssan and :name would need to be set by the host program using the host programming language before execution. If you also wanted to manipulate this new Person instance in the host program, you would need programming code in addition to this code fragment that populates the instance in the programming language along with the instance in the database. 

>>
Also see the INCITS DM32.2 Task Group on Database website (new window).

¹ SQL:1999 is also known as SQL3 and SQL-99. SQL:1999 is the proper term. SQL3 was the working term before the specification became a standard.

Related content for: SQL:1999

More on the general topic: DBMS standards

Read more free articles on this site

There are nearly 400 pages of articles on this site with over 40 pages on database concepts and standards.

Search this site for more articles

Custom Search

Browse this site for more articles

Click on the topics below to browse the articles on this site. You can see more detail by clicking on the arrows. This highlights the location of the current article: SQL:1999.

Loading...

Related recent articles from Google News

MS SQL Sever 2012 Launch, New Idera Release
ASP Free
The Instant Restore technology integrated in Idera's SQL safe 7.0 drastically reduces database and application downtime that is often associated with a restore operation. The technology completes the restore operation in the background while ...
SQL Server 2012 Coming on March 7 Network World
Microsoft pivots toward business intelligence SDTimes.com
all 49 news articles »
31 Jan 2012 at 9:52am
Microsoft Reveals Launch Date for Next-generation SQL Server 2012
PCWorld
By Chris Kanaracus, IDG News Microsoft has announced a March 7 online event for the launch of SQL Server 2012, the next generation of its database product. The event will feature keynote addresses from Microsoft corporate vice presidents Ted Kummert ...
Microsoft announces March launch event for SQL Server 2012 ComputerworldUK
SQL Server 2012 'Launch Event' Set for March 7, But Release Date Unclear Redmond Channel Partner
all 78 news articles »
24 Jan 2012 at 1:45pm
Joomla Gets Search, Database Reinforcements
PCWorld
Ozimek expects more choices will be made available as others write connectors for their favorite databases, ones that can be plugged into the module. The upgrade was built in such a way that Joomla can execute many standard SQL commands across ...
Joomla! 2.5 adds new features, closes holes The H
all 12 news articles »
24 Jan 2012 at 1:45pm
Commodity Hardware Meets Mission-Critical Apps: Success Story
InformationWeek
... and resisted pressure to move from SQL to Oracle database technology. By Charles Babcock InformationWeek First American Title Insurance has switched its core business system off an HP Superdome to standard x86 blades and resisted pressure to change ...

30 Jan 2012 at 9:12am
SQL Server Tuning Talk by DBSophic's Ami Levin Featured at Database Month
PR Web (press release)
DBSophic, an innovative provider of performance management products for SQL Server based applications, announced that Ami Levin, the company's CTO and a SQL Server MVP, will speak at Database Month. Database Month is a free conference featuring two ...
and more »
30 Jan 2012 at 8:21am
More related news on: SQL database standard

Related books at Amazon.com

SQL-99 Complete, Really
SQL-99 Complete, Really
by Peter Gulutzan, Trudy Pelzer
Description: SQL is the dominant mode of database programming used in industry. This text contains descriptions of the SQL3 standards (released in Summer 1999) for syntax, data structures and retrieval processes of SQL databases. It is an example-based reference manual, and includes all of the CLI functions.
SQL: 1999 - Understanding Relational Language Components (The Morgan Kaufmann Series in Data Management Systems)
SQL: 1999 - Understanding Relational Language Components (The Morgan Kaufmann Series in Data Management Systems)
by Jim Melton, Alan R. Simon
Description: This book is the best way to make the leap from SQL-92 to SQL:1999, but it is much more than just a simple bridge between the two. The latest from celebrated SQL experts Jim Melton and Alan Simon, SQL:1999 is a comprehensive, eminently practical account of SQL's latest incarnation and a potent distillation of the details required to put it to work. Written to accommodate both novic...
More related books: Search Amazon.com for SQL 1999