MSSQL
MSSQL
Overall table
definitions
Primary keys
can never have
NULL values
Identifying primary key
Chapter 6 Copyright © 2014 Pearson Education, Inc. 18 18
Non-nullable specifications
Primary key
Default value
Domain constraint
Primary key of
parent table
• Table Actions:
Inserting into a table does not require explicit customer ID entry or field list
Note: with aggregate functions you can’t have single-valued columns included in the
SELECT clause, unless they are included in the GROUP BY clause.
Note: the LIKE operator allows you to compare strings using wildcards.
For example, the % wildcard in ‘%Desk’ indicates that all strings that
have any number of characters preceding the word “Desk” will be
allowed.
Chapter 6 Copyright © 2014 Pearson Education, Inc. 35
Figure 6-7 Boolean query A without use of parentheses
By default,
processing order
of Boolean
operators is NOT,
then AND, then
OR
You can use single-value fields with aggregate functions if they are included in the GROUP BY
clause.