Generating unique serial no in a distributed system.

  • hi guys,

    How we can generate a unique serial no in a distributed system.

    The tables are replicated across all DB servers.

    say for example we have table loc_no (loc_code,serial_no) and the table is replication to all the servers.

    Now we need to generate serial no which is unique across all servers.

    plz let me know the avaiable alternative that can be used in this scenario.

     

  • NEWID()

    _____________
    Code for TallyGenerator

  • We cannot use GUID.

    The existing table has a numeric field which need to be migrated to a distributed enviornment.

     

    suggest??

  • Ranges. Determine some range for each server and let it grant IDs within that range.

    Or set up a central number distributor. Service Broker would be great, but any distributed query would work. Let a central server give out the numbers to other servers.

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply