Import ID column data then convert to SEQUENCE?

From: gvim <gvimrc(at)gmail(dot)com>
To: pgsql <pgsql-general(at)postgresql(dot)org>
Subject: Import ID column data then convert to SEQUENCE?
Date: 2010-12-10 03:36:01
Message-ID: 4D01A021.9020205@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I'm migrating a database from MySQL and need to keep the original `id` column (AUTO_INCREMENT) intact so my plan is to create the `id` column, import the data then convert the new `id` column to a SEQUENCE. Is this possible/the best solution? Maybe a migration utility would be better? Suggestions?

gvim

Responses

Browse pgsql-general by date

  From Date Subject
Next Message gvim 2010-12-10 03:44:32 Import id column then convert to SEQUENCE?
Previous Message Fujii Masao 2010-12-10 02:46:50 Re: Postgresql 9.1 pg_last_xact_replay_timestamp limitations