Hello,

let's say I have a table like this

NBR  INTEGER  PRIMARY KEY
SOMEFIELD1 VARCHAR
SOMEFIELD2 VARCHAR
[...]

Now I don't want to be NBR the primary key any more (the numbers there
have a special meaning where I need to have some "0" entries now); I'd
like to insert another "ID" colum which should be the new primary key
(and filling it automatically from 1 to N by a generator).

Is this possible within the "live" database/table, or do I have to create
a new table with the colums needed, and do some "INSERT INTO NEWTABLE
SELECT FROM OLDTABLE" and finally rename the new table to the old name?

The server is FB 2.0.3; I have IBExpert and FlameRobin available.

Thank you,

Matt


------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Visit http://www.firebirdsql.org and click the Resources item
on the main (top) menu.  Try Knowledgebase and FAQ links !

Also search the knowledgebases at http://www.ibphoenix.com 

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/firebird-support/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/firebird-support/join
    (Yahoo! ID required)

<*> To change settings via email:
    [email protected] 
    [email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/

Reply via email to