Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8540

Re: Auto number generation in custom table

$
0
0

Hi Ria Sen,

 

Please follow the steps as below,

 

1. Use Select single Max Query to select the latest maximum number

 

2. Check <variable> is initial or not.

3.if variable is initial assign the number which will start from your number range.

4.else increment the variable values by 1 and update the new range values.

 

Ex: Select Single Max ( Field for Number) from <table>

           into <variable>.

 

if <variable> is initial .

 

<variable> = 'Starting number from your range'.

 

else.

 

<variable> = <variable> + 1.

 

 

Please let me know if you have any issues.

 

 

Regards,

Gurunath Kumar D


Viewing all articles
Browse latest Browse all 8540

Trending Articles