Discussion:
[firebird-support] problem - change autoincrement fields to identity fields
Nico Speleers - Carfac BVBA nico.speleers@carfac.com [firebird-support]
2016-11-18 07:56:18 UTC
Permalink
Hello,


I want to change my autoincrement fields made in firebird 2.5.4 (with generator and trigger) to an identity field in firebird 3.0.1 without the generator and trigger. Can someone give me an useful script or another solution?
We work in an superserver model and our data access interface is FB Maestro 15.11.0.4.


Thanks in advance.


Nico Speleers
Analyst










Carfac bvba


Driving on experience




Rijksweg 53
9680 Maarkedal
Tel. +32 55 23 00 00
Fax +32 55 31 00 95
***@carfac.com
www.carfac.be<http://www.carfac.be/>
[cid:***@01D11613.C23F19C0]<Loading Image...@01D11613.C23F19C0]<http://www.linkedin.com/company/hdc-software-nv> [cid:***@01D11613.C23F19C0] <https://twitter.com/carfacbvba>


[Beschrijving: Beschrijving: Beschrijving: CarfacAS (klein)]<http://www.carfac.be/>










[Non-text portions of this message have been removed]
Dimitry Sibiryakov sd@ibphoenix.com [firebird-support]
2016-11-18 09:37:42 UTC
Permalink
Post by Nico Speleers - Carfac BVBA ***@carfac.com [firebird-support]
I want to change my autoincrement fields made in firebird 2.5.4 (with generator and
trigger) to an identity field in firebird 3.0.1 without the generator and trigger. Can
someone give me an useful script or another solution?
Give up. Identity is also just a generator and trigger, no difference.
--
WBR, SD.


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

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

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

Visit http://www.firebirdsql.org and click the Documentation item
on the main (top) menu. Try FAQ and other links from the left-side menu there.

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

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
------------------------------------

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:
firebird-support-***@yahoogroups.com
firebird-support-***@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
firebird-support-***@yahoogroups.com

<*> Your use of Yahoo Groups is subject to:
https://info.yahoo.com/legal/us/yahoo/utos/terms/
Nico Speleers - Carfac BVBA nico.speleers@carfac.com [firebird-support]
2016-11-18 11:09:01 UTC
Permalink
That's right. But I want to use identity fields because such fields don't uses a generator and a trigger. How can I easily change my old autoincrement fields to identity fields ?

Nico Speleers
Analyst

Carfac bvba
Driving on experience

Rijksweg 53
9680 Maarkedal
Tel. +32 55 23 00 00
Fax +32 55 31 00 95
***@carfac.com
www.carfac.be
 




-----Oorspronkelijk bericht-----
Van: firebird-***@yahoogroups.com [mailto:firebird-***@yahoogroups.com]
Verzonden: vrijdag 18 november 2016 10:38
Aan: firebird-***@yahoogroups.com
Onderwerp: Re: [firebird-support] problem - change autoincrement fields to identity fields
Post by Nico Speleers - Carfac BVBA ***@carfac.com [firebird-support]
I want to change my autoincrement fields made in firebird 2.5.4 (with generator and
trigger) to an identity field in firebird 3.0.1 without the generator
and trigger. Can someone give me an useful script or another solution?
Give up. Identity is also just a generator and trigger, no difference.
--
WBR, SD.


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

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

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

Visit http://www.firebirdsql.org and click the Documentation item on the main (top) menu. Try FAQ and other links from the left-side menu there.

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

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
------------------------------------

Yahoo Groups Links
Nico Speleers - Carfac BVBA nico.speleers@carfac.com [firebird-support]
2016-11-18 11:03:22 UTC
Permalink
That's right. But I want to use identity fields because such fields don't uses a generator and a trigger. How can I easily change my old autoincrement fields to identity fields ?

Nico Speleers
Analyst





Carfac bvba

Driving on experience


Rijksweg 53
9680 Maarkedal
Tel. +32 55 23 00 00
Fax +32 55 31 00 95
***@carfac.com
www.carfac.be<http://www.carfac.be/>
[cid:***@01D11613.C23F19C0]<http://www.facebook.com/groups/120709181286476/>[cid:***@01D11613.C23F19C0]<http://www.linkedin.com/company/hdc-software-nv> [cid:***@01D11613.C23F19C0] <https://twitter.com/carfacbvba>

[Beschrijving: Beschrijving: Beschrijving: CarfacAS (klein)]<http://www.carfac.be/>





[Non-text portions of this message have been removed]
Dimitry Sibiryakov sd@ibphoenix.com [firebird-support]
2016-11-18 11:21:19 UTC
Permalink
Post by Nico Speleers - Carfac BVBA ***@carfac.com [firebird-support]
How can I easily change my old autoincrement fields to identity fields ?
No way.
--
WBR, SD.


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

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

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

Visit http://www.firebirdsql.org and click the Documentation item
on the main (top) menu. Try FAQ and other links from the left-side menu there.

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

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
------------------------------------

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:
firebird-support-***@yahoogroups.com
firebird-support-***@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
firebird-support-***@yahoogroups.com

<*> Your use of Yahoo Groups is subject to:
https://info.yahoo.com/legal/us/yahoo/utos/terms/
Ann Harrison aharrison@ibphoenix.com [firebird-support]
2016-11-18 12:52:07 UTC
Permalink
Post by Nico Speleers - Carfac BVBA ***@carfac.com [firebird-support]
That's right. But I want to use identity fields because such fields don't uses a generator and a trigger. How can I easily change my old autoincrement fields to identity
What Dimitry is saying is that identity fields are just semantic sugar around the generator/trigger mechanism and there is no DDL to convert the old style to the new.

Good luck,

Ann
Lester Caine lester@lsces.co.uk [firebird-support]
2016-11-18 14:23:10 UTC
Permalink
Post by Nico Speleers - Carfac BVBA ***@carfac.com [firebird-support]
But I want to use identity fields because such fields don't uses a generator and a trigger.
Putting this a different way ... the correct way of ensuring where
multiple users are adding records which require a unique ID, SQL
introduced SEQUENCE which is the same thing as the Interbase generator
which pre-dates it. So a reliable 'identity' or 'auto-increment' field
is simply a wrapper for sequence or generator. I prefer access to the
trigger to allow more than a simple 'get next number' but if you prefer
to hid it fine. That is all you are doing by changing the code used ...
--
Lester Caine - G8HFL
-----------------------------
Contact - http://lsces.co.uk/wiki/?page=contact
L.S.Caine Electronic Services - http://lsces.co.uk
EnquirySolve - http://enquirysolve.com/
Model Engineers Digital Workshop - http://medw.co.uk
Rainbow Digital Media - http://rainbowdigitalmedia.co.uk


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

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

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

Visit http://www.firebirdsql.org and click the Documentation item
on the main (top) menu. Try FAQ and other links from the left-side menu there.

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

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
------------------------------------

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:
firebird-support-***@yahoogroups.com
firebird-support-***@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
firebird-support-***@yahoogroups.com

<*> Your use of Yahoo Groups is subject to:
https://info.yahoo.com/legal/us/yahoo/utos/terms/
Loading...