|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| ||||||||||||||||||||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Uniqe Ids Creation
Hey,
I need to create a Unique Ids factory but I don't know how, the factory is global and will be shared for the all db. Actually, the client-side framework should "ask" for new id/s and get them... Is there any simpler option than creating a table which will keep one column and one row which holds the greatest id which was created(and every time I want to get a new id, I increase the value in the row and return it .... )? Thanks all, Or. |
|
#2
|
|||
|
|||
|
Do you connect to multiple databases or one ?
|
|
#3
|
|||
|
|||
|
Yes
Quote:
only 1 database |
|
#4
|
|||
|
|||
|
usually almost all databases have concept of sequences, and you can use the sequence in your globalIdProvider factory
if you need more info, let me know what database you are using for specific solution |
![]() |
| Viewing: Dev Articles Community Forums > Databases > Database Development > Uniqe Ids Creation |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|