Get Next 'ProjID'

B

Barry Prentiss

Hi,
I am trying to get the last 'projID' and add 1 to it to sequentially number
my forms.
I have a fully functional method using the projNum concept referred to in
this newsgroup (thank you very much).
I would like to be able to use the existing projID field (with a
'TEST-10001' format) rather than a separate projNum field (with a '10001'
format), but am having difficulty getting the max().
I have a data connection (TEST.GetLastProjID) that queries the form library
for the projID column.
I then try to get the max() by using something like:
max(number(substring-after(@ProjID, "-"))) + 1
This generates an error 'after max()'.
Anybody know what I'm doing wrong?
Thx,
Barry
 
B

Barry Prentiss

I also tried concat(DgnGroup, "-", number(substring-after(max(@ProjID),
"-")) + 1) which does not generate any errors, but fills the projID field
with 'TEST-NaN'

Thx,
Barry
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top