23.10.2012 Views

Openedge Data Management: SQL Reference - Product ...

Openedge Data Management: SQL Reference - Product ...

Openedge Data Management: SQL Reference - Product ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

ROWID<br />

Syntax<br />

– The digit before a negative rounding_factor is 5 or greater<br />

– The digit after a positive rounding_factor is 5 or greater<br />

• The num_expression is rounded to the next lower digit when:<br />

– The digit before a negative rounding_factor is 4 or less<br />

– The digit after a positive rounding_factor is 4 or less<br />

ROWID<br />

• rounding_factor is an integer between –32 and +32 inclusive, and indicates the digit<br />

position to which you want to round num_expression. Figure 1 illustrates how the digit<br />

positions are numbered. In the figure, the num_expression is 2953861.8320.<br />

Figure 1: ROUND digit positions<br />

• If you do not specify a rounding_factor, the function rounds num_expression to digit 0<br />

(the ones place).<br />

• To round to the right of the decimal point, specify a positive rounding_factor.<br />

• To round to the left of the decimal, specify a negative rounding_factor.<br />

Compatibility<br />

Progress extension<br />

Returns the row identifier of the current row in a table. This function takes no arguments. The<br />

ROWID of a row is determined when the row is inserted into the table. Once assigned, the ROWID<br />

remains the same for the row until the row is deleted. At any given time, each row in a table is<br />

uniquely identified by its ROWID. Using its ROWID is the most efficient way of selecting the row.<br />

ROWID<br />

2953861 .8320<br />

Position -2<br />

Position 0<br />

Position 2<br />

Example This example illustrates the ROWID function, returning all columns from the row in the<br />

customers table where the ROWID = ‘10’:<br />

121

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!