authors Table

The authors table contains the name, telephone number, author ID, and other information about authors.

authors is defined as:

create table authors
(au_id id not null,
au_lname varchar(40) not null,
au_fname varchar(20) not null,
phone char(12) not null,
address varchar(40) null,
city varchar(20) null,
state char(2) null,
country varchar(12) null,
postalcode char(10) null)

Its primary key is au_id:

sp_primarykey authors, au_id

Its nonclustered index for the au_lname and au_fname columns is defined as:

create nonclustered index aunmind
on authors (au_lname, au_fname)

The phone column uses this default:

create default phonedflt as "UNKNOWN"
sp_bindefault phonedft, "authors.phone"

The following view uses authors:

create view titleview
as
select title, au_ord, au_lname,
price, total_sales, pub_id
from authors, titles, titleauthor
where authors.au_id = titleauthor.au_id
and titles.title_id = titleauthor.title_id