Re: [GENERAL] Change key primary for key foreign

2012-09-19 Thread Gavin Flower
On 19/09/12 19:40, Albe Laurenz wrote: Guilherme Rodrigues wrote: I created one table so: CREATE TABLE clima ( city char(80), cprc int, ); And have other table so: CREATE TABLE city ( namechar(80), other_thing int, ); These SQL statements have synt

Re: [GENERAL] Change key primary for key foreign

2012-09-19 Thread Guilherme Rodrigues
Em terça-feira, 18 de setembro de 2012 17h37min59s UTC-3, Guilherme Rodrigues escreveu: > Hello. I want to change one table already created. Where the comand? thank > you. Ok. Thank All. -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscriptio

Re: [GENERAL] Change key primary for key foreign

2012-09-19 Thread Albe Laurenz
Guilherme Rodrigues wrote: > I created one table so: > > CREATE TABLE clima ( > city char(80), > cprc int, > ); > > And have other table so: > > CREATE TABLE city ( > namechar(80), > other_thing int, > ); These SQL statements have syntax errors (comma aft

Re: [GENERAL] Change key primary for key foreign

2012-09-18 Thread Edson Richter
Em 18/09/2012 21:25, Guilherme Rodrigues escreveu: I created one table so: CREATE TABLE clima ( city char(80), cprc int, ); And have other table so: CREATE TABLE city ( namechar(80), other_thing int, ); But now I want the table clima receive name ta

Re: [GENERAL] Change key primary for key foreign

2012-09-18 Thread Guilherme Rodrigues
I created one table so: CREATE TABLE clima ( city char(80), cprc int, ); And have other table so: CREATE TABLE city ( namechar(80), other_thing int, ); But now I want the table clima receive name table city as foreign key. understand? Sorry my bad englis

Re: [GENERAL] Change key primary for key foreign

2012-09-18 Thread Raymond O'Donnell
On 18/09/2012 21:37, Guilherme Rodrigues wrote: > Hello. I want to change one table already created. Where the comand? thank > you. ALTER TABLE http://www.postgresql.org/docs/9.2/static/sql-altertable.html What exactly do you want to do? Ray. -- Raymond O'Donnell :: Galway :: Ireland r.

[GENERAL] Change key primary for key foreign

2012-09-18 Thread Guilherme Rodrigues
Hello. I want to change one table already created. Where the comand? thank you. -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general