General information
Category:
Coding, syntax & commands
Title:
Duplicate number appearing
Hello Sergey,
I am using the below code in the add button to get the next sequence number from the database table but it is not working properly.
It is getting the sequence number which is already there in the table.
Could you please tell me is there any other way to call the next good sequence number from table which does'nt exist.
this is the code i am using
***********************************Start************************************
SELECT Docindex
* set the sort order.
SET ORDER TO PJWPToFrom DESCENDING
SET NEAR ON
SEEK cProject_no+cWorkpkg_no+cToFrm
IF FOUND()
thisform.container1.sequence.value = INT(docindex.sequence+1)
thisform.container1.sequence.setfocus
ELSE
thisform.container1.Sequence.value = 1
thisform.container1.Sequence.setfocus
ENDIF
*****************************end*********************************************
Thank you very much Sergey.
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only