Difference between revisions of "CURRSEQNO()"

From Recital Documentation Wiki
Jump to: navigation, search
(Class)
 
(One intermediate revision by one user not shown)
Line 1: Line 1:
 
 
 
==Purpose==
 
==Purpose==
 
Function to return the current 'SEQNO' value
 
Function to return the current 'SEQNO' value
Line 10: Line 8:
  
 
==See Also==
 
==See Also==
[[SEQNO()]], [[SET SEQNO]], [[ZAP]]
+
[[LASTSEQNO()]], [[SEQNO()]], [[SET SEQNO]], [[ZAP]]
  
  
Line 19: Line 17:
  
 
The SET SEQNO command and CURRSEQNO() and SEQNO() functions are only supported for Recital tables.
 
The SET SEQNO command and CURRSEQNO() and SEQNO() functions are only supported for Recital tables.
 +
 +
The CURRSEQNO() function is synonymous with the LASTSEQNO() function.
  
  
Line 41: Line 41:
  
 
==Products==
 
==Products==
Recital Database Server, Recital Mirage Server, Recital Terminal Developer
+
Recital Server, Recital  
 
[[Category:Documentation]]
 
[[Category:Documentation]]
 
[[Category:Functions]]
 
[[Category:Functions]]

Latest revision as of 08:01, 27 July 2011

Purpose

Function to return the current 'SEQNO' value


Syntax

CURRSEQNO([<workarea | alias>])


See Also

LASTSEQNO(), SEQNO(), SET SEQNO, ZAP


Description

The CURRSEQNO() function returns the current 'SEQNO' value. The SEQNO value is a unique sequence number generated on a per table basis. The CURRSEQNO() function differs from the SEQNO() function in that CURRSEQNO() returns the current sequence number for a table and SEQNO() increases the current sequence number by one and then returns the value. Including the optional <workarea | alias> parameter will cause the CURRSEQNO() function to operate on the specified table. If there is no active table the CURRSEQNO() function will return 0.

A ZAP operation will reset the sequence number to 0. The sequence number of a table can be reset with the command SET SEQNO TO <expN>.

The SET SEQNO command and CURRSEQNO() and SEQNO() functions are only supported for Recital tables.

The CURRSEQNO() function is synonymous with the LASTSEQNO() function.


Example

use newtable
? seqno()
         1
? seqno()
         2
? currseqno()
         2
? currseqno()
         2
set seqno to 0
? currseqno()
         0
? seqno()
         1


Products

Recital Server, Recital