|
|
|
|
|
- Managing tabulations in the items
- Managing Float during an Oracle access via ODBC
- Retrieving Float items on Oracle (via ODBC)
SQL functions: Special case
Managing tabulations in the items Depending on the type of browse implemented with the SQL functions, the management of the tabulations in the items will differ: | | | | Type of path: SQLFirst/SQLCol | Type of path: SQLFetch/SQLGetCol | Management of tabulations | This type of browse cannot be used to retrieve the tabulations found in the values of records. A tabulation separates two items. Only the part found before the tabulation will be retrieved by the read functions. For more details, see the help about SQLCol and SQLAssociate. | This type of browse can be used to retrieve the tabulations found in the values of records. For more details, see the help about SQLGetCol. | Example | ResExec = SQLExec("SELECT NOMCLI " + ...
"FROM FACT", "REQ1")
IF ResExec=True THEN
SQLFirst("REQ1")
WHILE NOT SQL.Out
ListAdd(LISTE_NOM, ...
SQLCol("REQ1" ,1))
SQLNext("REQ1")
END
ELSE
END
SQLClose("REQ1")
| i is int = 0
SQLExec("SELECT NOM, PRENOM," + ...
"POSTE,PHOTO FROM CLIENT", ...
"REQ1" )
WHILE SQLFetch("REQ1") = 0
i++
NOM[i] = SQLGetCol("REQ1", 1)
PRENOM[i] = SQLGetCol("REQ1", 2)
POSTE[i] = SQLGetCol("REQ1", 3)
{"IMAGE" +i} = ...
SQLGetMemo("REQ1", 4)
END
SQLClose("REQ1")
|
For more details, see Types of SQL browse. Managing Float during an Oracle access via ODBC Retrieving Float items on Oracle (via ODBC) By default, the decimal separator used for the Float items on Oracle is the dot. However, the ODBC driver returns the value by using the comma as decimal separator. The decimal places are lost when the value is assigned to a numeric control. To avoid this problem, you must configure the decimal separator for the current connection:
SQLConnect("MaBaseOracle", "User", "Passe", "", "ODBC")
SQLExec("ALTER SESSION SET NLS_NUMERIC_CHARACTERS ='. '", "ReqTemp")
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|