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.

Syntax<br />

LOG10<br />

LOCATE denotes the first character position of a character expression as 1. If the search fails,<br />

LOCATE returns 0. If either character expression is NULL, LOCATE returns a NULL value.<br />

Example In the following example, which uses two string literals as character expressions, LOCATE returns<br />

a value of 6:<br />

Note char_expr1 and char_expr2 can contain multi-byte characters. The start_pos argument<br />

specifies the position of a starting character, not a byte position. The search is case sensitive.<br />

Character comparisons use the collation table in the database.<br />

LOG10<br />

Syntax<br />

Compatibility<br />

ODBC compatible<br />

Returns the base 10 logarithm of expression.<br />

Example This example illustrates the LOG10 function:<br />

Note The expression must evaluate to an approximate numeric data type.<br />

LOWER<br />

LOCATE( char_expr1 , char_expr2 , [ start_pos ] )<br />

SELECT LOCATE('this', 'test this test', 1) FROM TEST;<br />

LOCATE(THIS,<br />

------------<br />

6<br />

1 record selected<br />

LOG10 ( expression )<br />

SELECT LOG10 (100) 'Log base 10 of 100' FROM SYSPROGRESS.SYSCALCTABLE;<br />

Compatibility<br />

ODBC compatible<br />

Returns the result of the argument char_expression after converting all the characters to<br />

lowercase.<br />

103

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

Saved successfully!

Ooh no, something went wrong!