List:General Discussion« Previous MessageNext Message »
From:Mr. Shawn H. Corey Date:September 17 2008 10:40pm
Subject:Re: Finding gaps
View as plain text  
On Wed, 2008-09-17 at 23:29 +0100, Stut wrote:
> On 17 Sep 2008, at 22:34, Jerry Schwartz wrote:
> > Our Japanese partners will notice and will ask. Similar things have  
> > come up
> > before.
> >
> > I want to be pro-active.
> 
> Notice what? Why would it be bad? What type of data are we dealing  
> with here?
> 
> If each row requires a unique ID use an autonumber. If your partners  
> don't understand that deleted items will create gaps, explain it to  
> them. IMHO you're creating a problem that doesn't exist.
> 
> If you just need sequential numbers for display purposes, generate  
> them when you do the displaying. There's no need for those numbers to  
> be in the database.
> 
> -Stut

More than that: if you want to guarantee that the IDs will be unique,
there is the possibility of gaps.  If there are no gaps, there is the
possibility of two (or more) items having the same ID.  This is true
even if you re-number everything.

They have a choice:  uniqueness and gaps, or no gaps and non-uniqueness.


-- 
Just my 0.00000002 million dollars worth,
  Shawn

"Where there's duct tape, there's hope."
        Cross Time Cafe

"Perl is the duct tape of the Internet."
        Hassan Schroeder, Sun's first webmaster

"There is more than one way to do things."
        A Perl axiom

Thread
Finding gapsJerry Schwartz17 Sep
  • Re: Finding gapsStut17 Sep
    • Re: Finding gapsPeter Brawley17 Sep
      • RE: Finding gapsJerry Schwartz8 Oct
        • Re: Finding gapsGerald L. Clark8 Oct
          • RE: Finding gapsUS Data Export8 Oct
        • Re: Finding gapsPeter Brawley8 Oct
          • RE: Finding gapsUS Data Export9 Oct
            • Re: Finding gapsPeter Brawley9 Oct
              • RE: Finding gapsJerry Schwartz10 Oct
                • Re: Finding gapsMoon's Father25 Oct
                  • Re: Finding gapsMoon's Father25 Oct
                  • RE: Finding gapsUS Data Export27 Oct
    • RE: Finding gapsJerry Schwartz17 Sep
      • Re: Finding gapsStut18 Sep
        • Re: Finding gapsMr. Shawn H. Corey18 Sep
        • RE: Finding gapsJerry Schwartz18 Sep
          • Re: Finding gapsMike Diehl18 Sep
            • RE: Finding gapsJerry Schwartz18 Sep
    • RE: Finding gapsMartin Gainty18 Sep
      • RE: Finding gapsJerry Schwartz18 Sep
    • Re: Finding gapsJoerg Bruehe18 Sep
    • Re: Finding gapsJoerg Bruehe18 Sep
      • Re: Finding gapsStut18 Sep
        • Re: Finding gapsMr. Shawn H. Corey18 Sep