Creating and destroying base tables, PL-SQL Programming

Creating and Destroying Base Tables:

Example shows an SQL command to create the base table counterpart of the ENROLMENT variable

Example  Creating a base table.

CREATE TABLE ENROLMENT
( StudentId  SID ,
  Name   VARCHAR(30),
  CourseId  CID ,
  PRIMARY KEY ( StudentId, CourseId )
) ;

(Example and the other examples in this chapter all end in semicolons. Actually, a semicolon is required in SQL only in scripts consisting of more than one statement. A script consisting of a single statement must not end in a semicolon.)

Posted Date: 1/11/2013 5:20:19 AM | Location : United States







Related Discussions:- Creating and destroying base tables, Assignment Help, Ask Question on Creating and destroying base tables, Get Answer, Expert's Help, Creating and destroying base tables Discussions

Write discussion on Creating and destroying base tables
Your posts are moderated
Related Questions
Usefulness of Data Type In SQL, as in most computer languages, a type can be used for constraining the values that are permitted to be used for some purpose. In particular, i

The accuracy of product table data is critical and the Brwebean's. owner wants to have an audit file that contains information regarding all DML activity on the BB_PRODUCT table. T

Interesting properties of CROSS JOIN - SQL Compare these with the "interesting properties of JOIN", CROSS JOIN is associative but not commutative. Unlike JOIN and NATURAL JOI

Updating by replacement Syntax: UPDATE ENROLMENT SET Name = 'Ann' WHERE StudentId = SID ('S1'); Note the use of SET, as already noted in connection with direct a

Lightweight system to provide and take info from workers in the field and office, have basic design outlined already just require build and implementation Desired Skills CSS,

Use of Table Expressions - Expressing Constraint Conditions With the exception of key constraints, the examples in the theory book all explicitly reference at least one relvar

Effects of NULL for union - SQL The treatment of NULL in invocations of EXCEPT is as for UNION. This is different from its treatment in those of NOT IN and quantified compari

Table Literals - SQL One might expect SQL to support table literals in the manner illustrated in Example 2.2, but in fact that is not a legal SQL expression. Example: Not a

Read-Only Operator (+) - SQL The term read-only operator to the mathematical term function. Here I just need to add that the SQL standard reserves the term function for read-

Iteration Schemes The bounds of a loop range can be variables, literals, variables, or expressions but must compute to integers. Below are some of the examples. As you can see t