Re: Serial field
Posted in 1999
Topics: General Discussion
From: SANJAYDIXIT <SANJAYDIXIT@inf.com> > >How do I check whether any serial field has reached its maximum value ? SELECT MAX(serial_field_name) FROM table_name If this equals the maximum value you can store in a signed 4-byte int, you're there. :-) <<Attention Informix>> With the advent of many, many really big databases nowadays, shouldn't you address this? I mean, I don't really hang around with seriously big databases, and I've seen this being an issue in more than one site.... ______________________________________________________ Get Your Private, Free Email at http://www.hotmail.com
Obnoxio The Clown wrote: > From: SANJAYDIXIT <SANJAYDIXIT@inf.com> > >How do I check whether any serial field has reached its maximum value > ? > > SELECT MAX(serial_field_name) > FROM table_name > > If this equals the maximum value you can store in a signed 4-byte int, > you're there. :-) > > <<Attention Informix>> With the advent of many, many really big > databases nowadays, shouldn't you address this? I mean, I don't really > hang around with seriously big databases, and I've seen this being an > issue in more than one site.... What's wrong with the SERIAL8? You aren't about to run out of those numbers, are you? Admittedly only available in IDS/UDO, but there is a future beyond the 4-byte limit. -- Jonathan Leffler (jleffler@informix.com, jleffler@earthlink.net) Guardian of DBD::Informix v0.60 -- see http://www.perl.com/CPAN #include <disclaimer.h>