|
|
|
|
- Overview
- Main remarks
- Necessary version
- Unicode items
- Page code
- A file is locked in a transaction
- Specifying the execution time-out of the queries
- INSERT queries and automatic identifier
- Record number
- Main specific features
- Analysis options
- Array items
- Independent HFSQL context
- Identical records
- Locking records
- Specific features regarding HFSQL functions
- Remarks specific to the Sybase database
- Aggregate column
- IDENTITY column
- Case sensitivity for the names of tables and columns
Native Sybase Connector: Specific features and remarks
Available only with this kind of connection
The following paragraphs present the main aspects and specific features of the Native Sybase Connector. Necessary version Caution: This version of the Native Sybase Connector is only supported in WINDEV and/or WEBDEV 2024. Unicode items The Native DB2 Connector does not support Sybase items. We advise you to use text items in Ansi format and to perform the conversion (if necessary) with UnicodeToAnsi. HCreation will display an error message when creating files containing items in Unicode format. Page code The page code (charset) used by Native Sybase Connector is cp850 by default. If the server uses a different page code, you can configure the charset used by the Native Connector. The page code (charset) used by the Sybase client: - in WDSYBINS.INI (found in the in "C:\Windows" directory):
Specify the charset to use in the 'CHARSET' entry of section corresponding to the server name. For example:
- in the extended connection information: CHARSET=iso_1
A file is locked in a transaction HLockFile starts a transaction and locks the table in Exclusive mode. HUnlockFile validates the transaction and unlocks the table. Specifying the execution time-out of the queries To specify the execution timeout of queries: - in SQL mode (SQLExec), you must enter the following line in the "[OPTIONS]" entry of the "WDSYBINS.INI" file found in the Windows directory:
TIMEOUT = <Timeout in seconds> This timeout is set to 60 seconds by default. For an endless wait, enter the following line:
- with the HFSQL functions (HAdd, HExecuteQuery, etc.), simply indicate this timeout in the description window of the connection used.
You also have the ability to specify the execution timeout of queries via the "WD Connect Timeout" and "WD Command Timeout" options of HDescribeConnection and HOpenConnection. INSERT queries and automatic identifier The automatic identifiers are not supported by the INSERT queries (created through programming or in the query editor). To use an automatic identifier, call HAdd on the table. Record number You cannot specify a record number other than zero in HWrite and HRead. "Zero" corresponds to the current record number. Analysis options - The analysis options regarding the full-text indexes are not supported by the Native Connector.
- The analysis options regarding the partial indexing of text memos are not supported by the Native Connector.
- Whether the "Case sensitive", "Accent sensitive", "Punctuation sensitive" options are checked or not in the data model editor, the search will always be case, accentuation and punctuation sensitive.
Array items The Array items are not supported by the Native Connector. If you are using an array item, only the value of index 1 in the array will be handled by HFSQL functions (read/write). Independent HFSQL context The management of the independent HFSQL contexts (check box in the description of windows or reports) is not available in this version. Identical records The Native Sybase Connector cannot differentiate between two identical records (which means with identical values for all items, excluding memo items). When a record is modified or deleted, all the identical records will be modified or deleted. Locking records The lock options ( hLockWrite and hLockReadWrite) are ignored by the read functions ( HReadXXX, HReadSeekXXX). However, these locks options can be used by HAdd and HModify. If a record is added or modified with a lock option, this record is locked: - for all the other users
- for the user who requested the addition or modification if HReadFirst and HReadSeekFirst have been called on this record. If HRead is called on this same record, the record is not locked for the user who requested the addition or the modification.
Remark: To unlock the record (for all the users), use HUnlockRecNum(hCurrentRecNum). Specific features regarding HFSQL functions The specific features for using the HFSQL functions with Native Sybase Connector are as follows: | | Limitations | Affected functions |
---|
The hAffectBrowse constant is ignored. At the end of the operation, the browse continues from the record that was the current record before the addition or the modification. | HAdd, HModify | The hDistinct constant is ignored: all the records (including the duplicates) will be browsed. | HForward, HBackward, HReadPrevious, HReadNext, HNext | Multi-file queries. HAdd, HModify and HDelete are not supported. | HAdd HModify HDelete | HSeek, HFirst and HNext are used to position on a record without reading it. These functions can also be used to read the record. | HSeek HFirst HNext | If a duplicate error occurs on HModify, HRead (with the hCurrentRecNum constant) does not read the requested record. This problem will be fixed in a forthcoming version. | HRead | The hForceIDAuto constant is ignored by HModify. Sybase does not allow you to modify an "IDENTITY" column. | HModify |
Remarks specific to the Sybase database Aggregate column Workaround: To use an aggregate column, WHERE must be replaced by HAVING GROUP BY. IDENTITY column - write the following syntax in front of the query: SET IDENTITY_INSERT <TableName> ON
- write the following syntax after the query: SET IDENTITY_INSERT <TableName> OFF
For example, to insert the value "12" into the "CustomerID" column of "Customer" table, use the following syntax: SQLExec("SET IDENTITY_INSERT Customer ON INSERT INTO Customer(CustomerID)" + ... " VALUES (12) SET IDENTITY_INSERT Customer OFF", "Qry1") Case sensitivity for the names of tables and columns The table names and the column names are case sensitive:
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|