× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi Dieter,

Lol...I recall those conversations. Shouldn't be an issue, as a GUID would
only have to be unique within the machine.

Replacing the use of a sequence object with our own data area is an
option. Though the question is, can a straight RPG program perform the
operation faster than the DB can with a SEQUENCE?

I'd like to think IBM's optimized the SEQUENCE object and that RPG can't do
it any faster; but I suspect that may not be the case. I've just never
seen any benchmarks.

Also, I was passed copy of a presentation, "Warpspeedlocking" presented by
Ed Prosser of IBM talking about some stuff added in v5r3 that may provide a
better alternative.
V5R3+:
– New atomic MI instructions
– CHKLKVAL/CLRLKVAL: low-level locking
– Lightweight CMPSWP option

Charles

On Sat, Feb 18, 2017 at 12:17 AM, D*B <dieter.bender@xxxxxxxxxxxx> wrote:

first of all, I would be very carefull with the GUID approach. we've had a
discussion about "most likely unique" 14 years ago.
I don't understand the problem, you described, in detail. caching in a
sequence works well for getting multiple numbers in the same job and is
useless for many jobs getting their first sequence number at the same time.
For the first case it would be sufficient to replace the sequence by a
SRVPGM with your own getNextId function, backed up by a table, caching some
numbers. For the second case, I would simply use a compound of jobnumber
and number of request, this would be fastest anyway.

D*B
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.

Please contact support@xxxxxxxxxxxx for any subscription related
questions.

Help support midrange.com by shopping at amazon.com with our affiliate
link: http://amzn.to/2dEadiD


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.