Search Postgresql Archives

Re: Adding another primary key to a populated table

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 1/6/06, Daniel Kunkel <DanielKunkel@xxxxxxxxxxxx> wrote:
> Hi
>
> It makes sense that I can't have more than 1 primary key.
>
> Postgres was trying to create another primary key instead of modify the
> existing primary key.
>
> So...
>
> As I understand it, a table does not always have to have a primary key
> defined.
>
> Would it work to first delete/drop the primary key, then recreate the
> primary key on all 6 columns.
>

yes, but you have to drop all the dependant FOREIGN KEY constraints too

--
regards,
Jaime Casanova
(DBA: DataBase Aniquilator ;)


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux