Hi Raphael,
it’s used in LDAP, to minimize the number of trials to find a free
uidNumber or gidNumber in LDAP.
The general algorithm is:
- start with the next-id stored in that table (or the configured minimal
number)
- check if we can create a new entry in LDAP
- if yes update next-id with current id+1
- if no increment the number and check again
- check if we are less then the configured maximum number
It’s not a DB sequence, it just saved many trials in getting a new id in
LDAP.
Ralf
Raphael Alla schrieb:
What would be the benefit of using this table rather than sequences as
provided by the AdoDB API (GenID function)? It seems to me that storing
next ID in a table is not safe in a multi user/connections environment;
or if you want to make it safe you will recreate what AdoDB already does.
2008/3/15, Ralf Becker <RalfBecker@outdoor-training.de
mailto:RalfBecker@outdoor-training.de>:
It's still used for LDAP, no reason to not use it in other apps.
Ralf
Miles Lott schrieb:
> It was originally made to be used by any application, and
originally for
> the LDAP accounts. I am not certain that it is still used for that
> purpose, but I think you can still use it for your app.
>
> Nathan Gray wrote:
>> What is the purpose of the table egw_nextid?
>> Is it an appropriate place to store the next serial number for a
>> serialized product [line]?
>> My thought is to have something like:
>>
>> appname | id
>> ------------------------------------
>> perp_serial:21 9031
>> perp_serial:35 1049
>> perp_serial:201 212
>>
>> Would this be a good idea, or should I make my own table?
>>
>> Nathan Gray
>> nathan at goarctic dot com
>>
>> -----------------------------------
>> Extra punctuation??? Ug!!!!!!!!!
>> Just say no! Punctuation marks do not gain significance if you
>> increase their number, they make you look silly. One is sufficient.
>>
>>
>>
>>
>>
-------------------------------------------------------------------------
>> This SF.net email is sponsored by: Microsoft
>> Defy all challenges. Microsoft(R) Visual Studio 2008.
>> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
>> _______________________________________________
>> eGroupWare-developers mailing list
>> eGroupWare-developers@lists.sourceforge.net
<mailto:eGroupWare-developers@lists.sourceforge.net>
>> https://lists.sourceforge.net/lists/listinfo/egroupware-developers
>>
>
--
Ralf Becker
eGroupWare Training & Support ==> http://www.egroupware-support.de
Outdoor Unlimited Training GmbH [www.outdoor-training.de
<http://www.outdoor-training.de>]
Handelsregister HRB Kaiserslautern 3587
Geschäftsführer Birgit und Ralf Becker
Leibnizstr. 17, 67663 Kaiserslautern, Germany
Telefon +49 (0)631 31657-0
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
eGroupWare-developers mailing list
eGroupWare-developers@lists.sourceforge.net
<mailto:eGroupWare-developers@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/egroupware-developers
–
Raphael Alla
Mitija Australia
+61 4 15 678 576
+687 78 86 86
http://www.mitija.com
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft® Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
eGroupWare-developers mailing list
eGroupWare-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/egroupware-developers
–
Ralf Becker
eGroupWare Training & Support ==> http://www.egroupware-support.de
Outdoor Unlimited Training GmbH [www.outdoor-training.de]
Handelsregister HRB Kaiserslautern 3587
Geschäftsführer Birgit und Ralf Becker
Leibnizstr. 17, 67663 Kaiserslautern, Germany
Telefon +49 (0)631 31657-0
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft® Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
eGroupWare-developers mailing list
eGroupWare-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/egroupware-developers