RE: Sequence number generation
So far we haven't gotten into a problem of locking, there are about 15-20 users of the system. -Original Message- Sent: Thursday, July 18, 2002 8:28 PM To: Multiple recipients of list ORACLE-L Subject: RE: Sequence number generation I really don't see where this method scores over a sequence number. But I can see a number of places where it loses out. What happens when you select from the table and then don't commit the transaction that selected it? You'll still have a gap in your sequence. It's the same as a sequence but with a larger overhead, slower performance and Igor mentioned the possibility of locks on the table stopping the update processes altogether. Just (as they say) my deux euros Mike - Original Message - To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]> Sent: Thursday, July 18, 2002 3:38 AM > > To have a better control, we always use tables for holding counters. > Depending upon the requirement, either one table to hold different counters > or multiple tables, sometime in master tables as well. > > This does not any additional coding, the trigger in which you fetch from > sequence you select from table. To keep it synchronized with the > transaction, we make counter table block > > HTH! > > Aleem > -Original Message- > Sent: Thursday, July 18, 2002 11:48 AM > To: Multiple recipients of list ORACLE-L > Subject: RE: Sequence number generation > > It is not possible to avoid sequence number loss . > If a user requests a sequence number, then ultimately rolls back that > transaction, > that sequence number is lost . > > However you can catch such lost sequence numbers programatically and reuse > then. > that would require a bit of extra coding. > > -Original Message- > Sent: Thursday, July 18, 2002 10:43 AM > To: Multiple recipients of list ORACLE-L > > > Hi > Is it possible to avoid sequence number loss in the sequence number > generation. if so how? > > Thanks in Advance > > Ayyappan.S > > "Dreams translate into thoughts, and > thoughts translate into action: Kalam" > > > > > This communication contains information, which is confidential and may also > be privileged. It is for the exclusive use of the intended recipient(s). If > you are not the intended recipient(s), please note that any distribution, > printing, copying or use of this communication or the information in it is > strictly prohibited. If you have received this communication in error, > please notify the sender immediately and then destroy any copies of it. > > -- > Please see the official ORACLE-L FAQ: http://www.orafaq.com > -- > Author: Ayyappan S > INET: [EMAIL PROTECTED] > > Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 > San Diego, California-- Public Internet access / Mailing Lists > > To REMOVE yourself from this mailing list, send an E-Mail message > to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in > the message BODY, include a line containing: UNSUB ORACLE-L > (or the name of mailing list you want to be removed from). You may > also send the HELP command for other information (like subscribing). > > -- > Please see the official ORACLE-L FAQ: http://www.orafaq.com > -- > Author: Ratnesh Kumar Singh > INET: [EMAIL PROTECTED] > > Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 > San Diego, California-- Public Internet access / Mailing Lists > > To REMOVE yourself from this mailing list, send an E-Mail message > to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in > the message BODY, include a line containing: UNSUB ORACLE-L > (or the name of mailing list you want to be removed from). You may > also send the HELP command for other information (like subscribing). > -- > Please see the official ORACLE-L FAQ: http://www.orafaq.com > -- > Author: Abdul Aleem > INET: [EMAIL PROTECTED] > > Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 > San Diego, California-- Public Internet access / Mailing Lists > > To REMOVE yourself from this mailing list, send an E-Mail message > to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in > the message BODY, include a line containing: UNSUB ORACLE-L > (or the name of mailing list y
RE: Sequence number generation
But be careful! Using tables for sequence numbers is a dead-certain guarantee that your application can never scale. The only way you can avoid performance problems with this kind of application design is to never let a lot of users use the system. If the locks don't kill you, then contention for the cache buffers chains latches will. Since your buffer clones all have the same fileid and blockid, they'll always be on the same chain in the buffer cache hash table. No amount of memory, no SGA size, and no setting of _db_block_hash_buckets or _db_block_hash_latches can save you. Cary Millsap Hotsos Enterprises, Ltd. http://www.hotsos.com Upcoming events: - Hotsos Clinic, Jul 23-25 Chicago - Miracle Database Forum, Sep 20-22 Middlefart Denmark - 2003 Hotsos Symposium on OracleR System Performance, Feb 9-12 Dallas -Original Message- Aleem Sent: Thursday, July 18, 2002 2:38 AM To: Multiple recipients of list ORACLE-L To have a better control, we always use tables for holding counters. Depending upon the requirement, either one table to hold different counters or multiple tables, sometime in master tables as well. This does not any additional coding, the trigger in which you fetch from sequence you select from table. To keep it synchronized with the transaction, we make counter table block HTH! Aleem -Original Message- Sent: Thursday, July 18, 2002 11:48 AM To: Multiple recipients of list ORACLE-L Subject: RE: Sequence number generation It is not possible to avoid sequence number loss . If a user requests a sequence number, then ultimately rolls back that transaction, that sequence number is lost . However you can catch such lost sequence numbers programatically and reuse then. that would require a bit of extra coding. -Original Message- Sent: Thursday, July 18, 2002 10:43 AM To: Multiple recipients of list ORACLE-L Hi Is it possible to avoid sequence number loss in the sequence number generation. if so how? Thanks in Advance Ayyappan.S "Dreams translate into thoughts, and thoughts translate into action: Kalam" This communication contains information, which is confidential and may also be privileged. It is for the exclusive use of the intended recipient(s). If you are not the intended recipient(s), please note that any distribution, printing, copying or use of this communication or the information in it is strictly prohibited. If you have received this communication in error, please notify the sender immediately and then destroy any copies of it. -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Ayyappan S INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Ratnesh Kumar Singh INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Abdul Aleem INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Cary Millsap INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists -
RE: Sequence number generation
I really don't see where this method scores over a sequence number. But I can see a number of places where it loses out. What happens when you select from the table and then don't commit the transaction that selected it? You'll still have a gap in your sequence. It's the same as a sequence but with a larger overhead, slower performance and Igor mentioned the possibility of locks on the table stopping the update processes altogether. Just (as they say) my deux euros Mike - Original Message - To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]> Sent: Thursday, July 18, 2002 3:38 AM > > To have a better control, we always use tables for holding counters. > Depending upon the requirement, either one table to hold different counters > or multiple tables, sometime in master tables as well. > > This does not any additional coding, the trigger in which you fetch from > sequence you select from table. To keep it synchronized with the > transaction, we make counter table block > > HTH! > > Aleem > -Original Message- > Sent: Thursday, July 18, 2002 11:48 AM > To: Multiple recipients of list ORACLE-L > Subject: RE: Sequence number generation > > It is not possible to avoid sequence number loss . > If a user requests a sequence number, then ultimately rolls back that > transaction, > that sequence number is lost . > > However you can catch such lost sequence numbers programatically and reuse > then. > that would require a bit of extra coding. > > -Original Message- > Sent: Thursday, July 18, 2002 10:43 AM > To: Multiple recipients of list ORACLE-L > > > Hi > Is it possible to avoid sequence number loss in the sequence number > generation. if so how? > > Thanks in Advance > > Ayyappan.S > > "Dreams translate into thoughts, and > thoughts translate into action: Kalam" > > > > > This communication contains information, which is confidential and may also > be privileged. It is for the exclusive use of the intended recipient(s). If > you are not the intended recipient(s), please note that any distribution, > printing, copying or use of this communication or the information in it is > strictly prohibited. If you have received this communication in error, > please notify the sender immediately and then destroy any copies of it. > > -- > Please see the official ORACLE-L FAQ: http://www.orafaq.com > -- > Author: Ayyappan S > INET: [EMAIL PROTECTED] > > Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 > San Diego, California-- Public Internet access / Mailing Lists > > To REMOVE yourself from this mailing list, send an E-Mail message > to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in > the message BODY, include a line containing: UNSUB ORACLE-L > (or the name of mailing list you want to be removed from). You may > also send the HELP command for other information (like subscribing). > > -- > Please see the official ORACLE-L FAQ: http://www.orafaq.com > -- > Author: Ratnesh Kumar Singh > INET: [EMAIL PROTECTED] > > Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 > San Diego, California-- Public Internet access / Mailing Lists > > To REMOVE yourself from this mailing list, send an E-Mail message > to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in > the message BODY, include a line containing: UNSUB ORACLE-L > (or the name of mailing list you want to be removed from). You may > also send the HELP command for other information (like subscribing). > -- > Please see the official ORACLE-L FAQ: http://www.orafaq.com > -- > Author: Abdul Aleem > INET: [EMAIL PROTECTED] > > Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 > San Diego, California-- Public Internet access / Mailing Lists > > To REMOVE yourself from this mailing list, send an E-Mail message > to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in > the message BODY, include a line containing: UNSUB ORACLE-L > (or the name of mailing list you want to be removed from). You may > also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Igor Neyman INET: [EMAIL PROTECTED] Fat City Network Services-- (85
Re: Sequence number generation
so, what do you do, when you need to lock "counter table" and it's already locked by another process? Igor Neyman, OCP DBA [EMAIL PROTECTED] - Original Message - To: "Multiple recipients of list ORACLE-L" <[EMAIL PROTECTED]> Sent: Thursday, July 18, 2002 3:38 AM > > To have a better control, we always use tables for holding counters. > Depending upon the requirement, either one table to hold different counters > or multiple tables, sometime in master tables as well. > > This does not any additional coding, the trigger in which you fetch from > sequence you select from table. To keep it synchronized with the > transaction, we make counter table block > > HTH! > > Aleem > -Original Message- > Sent: Thursday, July 18, 2002 11:48 AM > To: Multiple recipients of list ORACLE-L > Subject: RE: Sequence number generation > > It is not possible to avoid sequence number loss . > If a user requests a sequence number, then ultimately rolls back that > transaction, > that sequence number is lost . > > However you can catch such lost sequence numbers programatically and reuse > then. > that would require a bit of extra coding. > > -Original Message- > Sent: Thursday, July 18, 2002 10:43 AM > To: Multiple recipients of list ORACLE-L > > > Hi > Is it possible to avoid sequence number loss in the sequence number > generation. if so how? > > Thanks in Advance > > Ayyappan.S > > "Dreams translate into thoughts, and > thoughts translate into action: Kalam" > > > > > This communication contains information, which is confidential and may also > be privileged. It is for the exclusive use of the intended recipient(s). If > you are not the intended recipient(s), please note that any distribution, > printing, copying or use of this communication or the information in it is > strictly prohibited. If you have received this communication in error, > please notify the sender immediately and then destroy any copies of it. > > -- > Please see the official ORACLE-L FAQ: http://www.orafaq.com > -- > Author: Ayyappan S > INET: [EMAIL PROTECTED] > > Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 > San Diego, California-- Public Internet access / Mailing Lists > > To REMOVE yourself from this mailing list, send an E-Mail message > to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in > the message BODY, include a line containing: UNSUB ORACLE-L > (or the name of mailing list you want to be removed from). You may > also send the HELP command for other information (like subscribing). > > -- > Please see the official ORACLE-L FAQ: http://www.orafaq.com > -- > Author: Ratnesh Kumar Singh > INET: [EMAIL PROTECTED] > > Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 > San Diego, California-- Public Internet access / Mailing Lists > > To REMOVE yourself from this mailing list, send an E-Mail message > to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in > the message BODY, include a line containing: UNSUB ORACLE-L > (or the name of mailing list you want to be removed from). You may > also send the HELP command for other information (like subscribing). > -- > Please see the official ORACLE-L FAQ: http://www.orafaq.com > -- > Author: Abdul Aleem > INET: [EMAIL PROTECTED] > > Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 > San Diego, California-- Public Internet access / Mailing Lists > > To REMOVE yourself from this mailing list, send an E-Mail message > to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in > the message BODY, include a line containing: UNSUB ORACLE-L > (or the name of mailing list you want to be removed from). You may > also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Igor Neyman INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
RE: Sequence number generation
To have a better control, we always use tables for holding counters. Depending upon the requirement, either one table to hold different counters or multiple tables, sometime in master tables as well. This does not any additional coding, the trigger in which you fetch from sequence you select from table. To keep it synchronized with the transaction, we make counter table block HTH! Aleem -Original Message- Sent: Thursday, July 18, 2002 11:48 AM To: Multiple recipients of list ORACLE-L Subject:RE: Sequence number generation It is not possible to avoid sequence number loss . If a user requests a sequence number, then ultimately rolls back that transaction, that sequence number is lost . However you can catch such lost sequence numbers programatically and reuse then. that would require a bit of extra coding. -Original Message- Sent: Thursday, July 18, 2002 10:43 AM To: Multiple recipients of list ORACLE-L Hi Is it possible to avoid sequence number loss in the sequence number generation. if so how? Thanks in Advance Ayyappan.S "Dreams translate into thoughts, and thoughts translate into action: Kalam" This communication contains information, which is confidential and may also be privileged. It is for the exclusive use of the intended recipient(s). If you are not the intended recipient(s), please note that any distribution, printing, copying or use of this communication or the information in it is strictly prohibited. If you have received this communication in error, please notify the sender immediately and then destroy any copies of it. -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Ayyappan S INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Ratnesh Kumar Singh INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Abdul Aleem INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
RE: Sequence number generation
It is not possible to avoid sequence number loss . If a user requests a sequence number, then ultimately rolls back that transaction, that sequence number is lost . However you can catch such lost sequence numbers programatically and reuse then. that would require a bit of extra coding. -Original Message- Sent: Thursday, July 18, 2002 10:43 AM To: Multiple recipients of list ORACLE-L Hi Is it possible to avoid sequence number loss in the sequence number generation. if so how? Thanks in Advance Ayyappan.S "Dreams translate into thoughts, and thoughts translate into action: Kalam" This communication contains information, which is confidential and may also be privileged. It is for the exclusive use of the intended recipient(s). If you are not the intended recipient(s), please note that any distribution, printing, copying or use of this communication or the information in it is strictly prohibited. If you have received this communication in error, please notify the sender immediately and then destroy any copies of it. -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Ayyappan S INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Ratnesh Kumar Singh INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
RE: Sequence number generation
Generate the sequence with option NOCAHCE The cached values of the sequences are lost if the shared pool is flushed. Sanjay -Original Message- Sent: 18 July, 2002 1:13 PM To: Multiple recipients of list ORACLE-L Hi Is it possible to avoid sequence number loss in the sequence number generation. if so how? Thanks in Advance Ayyappan.S "Dreams translate into thoughts, and thoughts translate into action: Kalam" This communication contains information, which is confidential and may also be privileged. It is for the exclusive use of the intended recipient(s). If you are not the intended recipient(s), please note that any distribution, printing, copying or use of this communication or the information in it is strictly prohibited. If you have received this communication in error, please notify the sender immediately and then destroy any copies of it. -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: Ayyappan S INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- Please see the official ORACLE-L FAQ: http://www.orafaq.com -- Author: G Sanjay INET: [EMAIL PROTECTED] Fat City Network Services-- (858) 538-5051 FAX: (858) 538-5051 San Diego, California-- Public Internet access / Mailing Lists To REMOVE yourself from this mailing list, send an E-Mail message to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).