Thread: Primary and foreign key

Primary and foreign key

From
Daniel Facciolo Pires
Date:
I don't know how can I set an attribute like a primary key.

And how can I set the references integrated.

I saw at help's PostgreSQL:

create table <class_name>
        (<attr1> <type1> [default <expression>] [not null] [,...])
        [inherits (<class_name1>,...<class_nameN>)
        [[constraint <name>] check <condition> [,...] ]

Will I have to control the integrated by myself in the program?

Thanks!

-----------------------------------------
Daniel Facciolo Pires
Mestrado em Ciencias da Computacao
ICMC-USP-Sao Carlos
Grupo: Hipermidia
dfpires@intermidia.icmc.sc.usp.br
http://www.intermidia.icmc.sc.usp.br/~dfpires