Thanks to everyone. The query worked.

On Mon, Oct 12, 2015 at 12:09 PM, <rob@xxxxxxxxx> wrote:

According to Infocenter:
...The next identity value. In some cases, this value may be an
estimate...

Rob Berendt
--
IBM Certified System Administrator - IBM i 6.1
Group Dekko
Dept 1600
Mail to: 2505 Dekko Drive
Garrett, IN 46738
Ship to: Dock 108
6928N 400E
Kendallville, IN 46755
http://www.dekko.com





From: Roger Harman <roger.harman@xxxxxxxxxxx>
To: Midrange Systems Technical Discussion <midrange-l@xxxxxxxxxxxx>
Date: 10/12/2015 02:24 PM
Subject: RE: AW: Next Identity Key Value
Sent by: "MIDRANGE-L" <midrange-l-bounces@xxxxxxxxxxxx>



But, I seem to recall that there was some caching of these values for
performance improvement.

Is that not the case?

Roger Harman
COMMON Certified Application Developer – ILE RPG on IBM i on Power


----------------------------------------
From: Hauser@xxxxxxxxxxxxxxx
To: midrange-l@xxxxxxxxxxxx
Subject: AW: Next Identity Key Value
Date: Mon, 12 Oct 2015 19:28:53 +0200

Is there a way to get the next identity key that will be used for a
given
table?
Try:
Select NEXT_IDENTITY_VALUE
From QSYS2.SYSPARTITIONSTAT
Where Table_Schema = 'YOURSCHEMA' and Table_Name = 'YOURTABLE' ;


Mit freundlichen Grüßen / Best regards

Birgitta Hauser

"Shoot for the moon, even if you miss, you'll land among the stars."
(Les
Brown)
"If you think education is expensive, try ignorance." (Derek Bok)
"What is worse than training your staff and losing them? Not training
them
and keeping them!"

-----Ursprüngliche Nachricht-----
Von: MIDRANGE-L [mailto:midrange-l-bounces@xxxxxxxxxxxx] Im Auftrag von
Alan
Campin
Gesendet: Monday, 12.10 2015 18:24
An: Midrange Systems Technical Discussion
Betreff: Next Identity Key Value

Is there a way to get the next identity key that will be used for a
given
table?

Has to be in the database somewhere.

I can do an ALTER TABLE to change the value but I want to know what the
next
value would be for a given table.

Thanks for the help.
--
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.


--
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.


--
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.




--
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.



This thread ...

Follow-Ups:
Replies:

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

This mailing list archive is Copyright 1997-2019 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].