Include file for Proteus DAO functions
; Include file for Proteus DAO functions

; Attribute types for DAODBATTRIB

; transactions are supported
CONST DAOATTCANTRANSACT = 1
; update is possible
CONST DAOATTCANUPDATE = 2
; connection string
CONST DAOATTGETCONNECT = 3
; name
CONST DAOATTGETNAME = 4
; query timeout
CONST DAOATTGETSETQUERYTIMEOUT = 5
; number of records affected by the last operation
CONST DAOATTGETRECORDSAFFECTED = 6
; version
CONST DAOATTGETVERSION = 7
; open
CONST DAOATTISOPEN = 8

; -----------------------------------------------------------------------------------------

; Locale types for DAODBCREATE

CONST DAOCLangArabic = ";LANGID=0x0401;CP=1256;COUNTRY=0"
CONST DAOCLangCzech = ";LANGID=0x0405;CP=1250;COUNTRY=0"
CONST DAOCLangDutch = ";LANGID=0x0413;CP=1252;COUNTRY=0"
; to be used for: english, german, french, portuguese, italian and spanish
CONST DAOCLangGeneral = ";LANGID=0x0409;CP=1252;COUNTRY=0"
CONST DAOCLangGreek = ";LANGID=0x0408;CP=1253;COUNTRY=0"
CONST DAOCLangHebrew = ";LANGID=0x040D;CP=1255;COUNTRY=0"
CONST DAOCLangHungarian = ";LANGID=0x040E;CP=1250;COUNTRY=0"
CONST DAOCLangIcelandic = ";LANGID=0x040F;CP=1252;COUNTRY=0"
CONST DAOCLangNordic = ";LANGID=0x041D;CP=1252;COUNTRY=0"
CONST DAOCLangNorwDan = ";LANGID=0x0414;CP=1252;COUNTRY=0"
CONST DAOCLangPolish = ";LANGID=0x0415;CP=1250;COUNTRY=0"
CONST DAOCLangCyrillic = ";LANGID=0x0419;CP=1251;COUNTRY=0"
CONST DAOCLangSpanish = ";LANGID=0x040A;CP=1252;COUNTRY=0"
CONST DAOCLangSwedFin = ";LANGID=0x040B;CP=1252;COUNTRY=0"
CONST DAOCLangTurkish = ";LANGID=0x041F;CP=1254;COUNTRY=0"
CONST DAOCLangJapanese = ";LANGID=0x0411;CP=932;COUNTRY=0"
CONST DAOCLangChineseSimplified = ";LANGID=0x0804;CP=936;COUNTRY=0"
CONST DAOCLangChineseTraditional = ";LANGID=0x0404;CP=950;COUNTRY=0"
CONST DAOCLangKorean = ";LANGID=0x0412;CP=949;COUNTRY=0"
CONST DAOCLangThai = ";LANGID=0x041E;CP=874;COUNTRY=0"
CONST DAOCLangSlovenian = ";LANGID=0x0424;CP=1250;COUNTRY=0"

; -----------------------------------------------------------------------------------------

; Options for DAODBCREATE

; create using Jet 1.0
CONST DAOCVersion10 = 1
; save database encrypted to disk
CONST DAOCEncrypt = 2
; save database not encrypted to disk
CONST DAOCDecrypt = 4
; create using Jet 1.1
CONST DAOCVersion11 = 8
; create using Jet 2.0
CONST DAOCVersion20 = 16
; create using Jet 3.0
CONST DAOCVersion30 = 32

; -----------------------------------------------------------------------------------------

; Attributes for DAODBCREATERELATION and for relation type information returned by DAODBGETRELATIONINFO

; 1 to 1 relation
CONST DAOCRelationUnique = 1
; no referential integrity
CONST DAOCRelationDontEnforce = 2
; relation exists in a non-concurrent database that includes both tables
CONST DAOCRelationInherited = 4
; updates will be propagated
CONST DAOCRelationUpdateCascade = 256
; deletions will be propagated
CONST DAOCRelationDeleteCascade = 4096
; relation is a left join. An external left join includes all records from the first table (left part),
; even though there are no corresponding records in the second table (right join).
CONST DAOCRelationLeft = 16777216
; relation is a right join. An external right join includes all records from the second table (right part),
; even though there are no corresponding records in the first table (left join).
CONST DAOCRelationRight = 33554432

; -----------------------------------------------------------------------------------------

; Options for DAODBEXECUTE

; deny write to other users
CONST DAOCDenyWrite = 1
; allow inconsistent updates (default)
CONST DAOCInconsistent = 16
; force inconsistent updates
CONST DAOCConsistent = 32
; statement is passed verbatim to ODBC data source for processing
CONST DAOCSQLPassThrough = 64
; roll back all updates in case of error
CONST DAOCFailOnError = 128
; generate error if another user is changing the same data
CONST DAOCSeeChanges = 512
; deny read to other users
CONST DAOCDenyRead = 2
; read only
CONST DAOCReadOnly = 4
; can only append
CONST DAOCAppendOnly = 8
; open in forward scrolling mode only (unsupported)
;CONST DAOCForwardOnly = 256
; run in asynchronous mode
CONST DAOCRunAsync = 1024
; execute directly
CONST DAOCExecDirect = 2048

; -----------------------------------------------------------------------------------------

; Indexes in the array returned by DAODBGETQUERYINFO

; query name
CONST DAOQI_NAME = 1
; query type
CONST DAOQI_TYPE = 2
; creation date
CONST DAOQI_CDATE = 3
; creation time
CONST DAOQI_CTIME = 4
; last update date
CONST DAOQI_UDATE = 5
; last update time
CONST DAOQI_UTIME = 6
; updateable
CONST DAOQI_UPDATE = 7
; return records
CONST DAOQI_RECORDSET = 8
; SQL string
CONST DAOQI_SQL = 9
; source info
CONST DAOQI_SOURCE = 10
; timeout for DB Engine
CONST DAOQI_TIMEOUT = 11

; -----------------------------------------------------------------------------------------

; Indexes in the array returned by DAODBGETRELINFO

; relation name
CONST DAORI_NAME = 1
; table name
CONST DAORI_TABLE = 2
; name of the external table
CONST DAORI_EXTTABLE = 3
; relation type
CONST DAORI_TYPE = 4
; fields related (array)
CONST DAORI_FIELDS = 5

; -----------------------------------------------------------------------------------------

; Indexes in the array returned by DAODBGETTABINFO

; table name
CONST DAOTI_NAME = 1
; updateable
CONST DAOTI_UPDATE = 2
; attributes
CONST DAOTI_ATTRIB = 3
; creation date
CONST DAOTI_CDATE = 4
; creation time
CONST DAOTI_CTIME = 5
; last update date
CONST DAOTI_UDATE = 6
; last update time
CONST DAOTI_UTIME = 7
; table linked (if it exists)
CONST DAOTI_LINK = 8
; source
CONST DAOTI_SOURCE = 9
; validation rule
CONST DAOTI_VALIDATE = 10
; message if validation fails
CONST DAOTI_INVALID = 11
; number of records visited
CONST DAOTI_RECNUMBER = 12

; -----------------------------------------------------------------------------------------

; Indexes in the array returned by DAORSGETFIELDINFO

; field name
CONST DAOFI_NAME = 1
; type
CONST DAOFI_TYPE = 2
; maximum size
CONST DAOFI_SIZE = 3
; attributes
CONST DAOFI_ATTRIB = 4
; ordinal position
CONST DAOFI_POSITION = 5
; required
CONST DAOFI_REQUIRED = 6
; allow zero length
CONST DAOFI_ALLOWZL = 7
; collating order
CONST DAOFI_COLLATE = 8
; external name
CONST DAOFI_EXTNAME = 9
; source field
CONST DAOFI_EXTFIELD = 10
; source table
CONST DAOFI_EXTTABLE = 11
; validation rule
CONST DAOFI_VALIDATE = 12
; message returned if validation fails
CONST DAOFI_INVALID = 13
; default value
CONST DAOFI_DEFAULT = 14

; -----------------------------------------------------------------------------------------

; Indexes in the array returned by DAORSGETINDEXINFO

; index name
CONST DAOII_NAME = 1
; field array
CONST DAOII_FIELDS = 2
; primary
CONST DAOII_PRIMARY = 3
; unique
CONST DAOII_UNIQUE = 4
; clustered
CONST DAOII_CLUSTERED = 5
; ignore Nulls
CONST DAOII_NULLIGNORE = 6
; required
CONST DAOII_REQUIRED = 7
; external
CONST DAOII_EXTERN = 8
; distinct keys in the index
CONST DAOII_KEYS = 9

; -----------------------------------------------------------------------------------------

; Query types returned by DAODBGETQUERYDEFINFO

; query select records
CONST DAOCQSelect = 0
; query moves or updates records, but returns none
CONST DAOCQAction = 240
; query returns records in spreadsheet format
CONST DAOCQCrosstab = 16
; query deletes a set of rows
CONST DAOCQDelete = 32
; query updates a set of records
CONST DAOCQUpdate = 48
; query add new records at the end of the table/query
CONST DAOCQAppend = 64
; query creates a new table from a recordset
CONST DAOCQMakeTable = 80
; query changes table structure
CONST DAOCQDDL = 96
; statement is passed directly to the engine
CONST DAOCQSQLPassThrough = 112
; query creates a snapshot recordset with data coming from two or more tables,
; removing duplicates. To include duplicates, all keyword ALL to SQL statement.
CONST DAOCQSetOperation = 128
; used with DAOCQSQLPassThrough to specify a query that does not return records
CONST DAOCQSPTBulk = 144

; -----------------------------------------------------------------------------------------

; Attributes returned by DAODBGETTABLEDEFINFO

; for tables using Jet, specify that the table is linked and open for exclusive usage
CONST DAOCAttachExclusive = 65536
; for tables using Jet, specify that User ID and password for the table are saved
; together with connection information
CONST DAOCAttachSavePWD = 131072
; specify that the table is of system type (read only)
CONST DAOCSystemObject = -2147483646
; specify that the table is hidden (for temporary usage, read only)
CONST DAOCAttachedTable = 1073741824
; specify that the table is linked to a non-ODBC database, such as Paradox
CONST DAOCAttachedODBC = 536870912
; specify that the table is linked to an ODBC database, such as MS SQL Server
CONST DAOCHiddenObject = 1

; -----------------------------------------------------------------------------------------

; Attributed names for DAORSATTRIB

; returns not-zero if records can be appended
CONST DAORSATTCANAPPEND = 1
; returns not-zero if recordset supports bookmark
CONST DAORSATTCANBOOKMARK = 2
; returns not-zero if query can be repeated
CONST DAORSATTCANRESTART = 3
; returns not-zero if it is possible to move between records
CONST DAORSATTCANSCROLL = 4
; returns not-zero if the data source supports transactions
CONST DAORSATTCANTRANSACT = 5
; returns not-zero if the recordset can be updated
CONST DAORSATTCANUPDATE = 6
; returns creation date for the base table in the recordset
CONST DAORSATTGETDATECREATED = 7
; returns creation time for the base table in the recordset
CONST DAORSATTGETTIMECREATED = 8
; returns last update date for the base table in the recordset
CONST DAORSATTGETDATELASTUPDATED = 9
; return last update time for the base table in the recordset
CONST DAORSATTGETTIMELASTUPDATED = 10
; returns the name of the recordset
CONST DAORSATTGETNAME = 11
; returns SQL string used to calculate recordset
CONST DAORSATTGETSQL = 12
; returns validation string for data introduced in the record
CONST DAORSATTGETVALIDATIONRULE = 13
; returns message displayed when validation fails
CONST DAORSATTGETVALIDATIONTEXT = 14
; return editing mode for current record
CONST DAORSATTGETEDITMODE = 15
; returns the name of the current index in a table-type recordset
CONST DAORSATTGETCURRENTINDEX = 16
; returns number of records accessed in a recordset
CONST DAORSATTGETRECORDCOUNT = 17
; returns not-zero if the recordset was positioned before the first record; no current record exists
CONST DAORSATTISBOF = 18
; returns not-zero if the recordset is positioned over a deleted record
CONST DAORSATTISDELETED = 19
; returns not-zero if the recordset was positioned after the last record; no current record exists
CONST DAORSATTISEOF = 20
; returns not-zero if the recordset is open
CONST DAORSATTISOPEN = 21
; returns recordset type: table, dynaset, snapshot
CONST DAORSATTGETTYPE = 22
; returns a bookmark handle for the most recently added or modified record
CONST DAORSATTGETLASTMODBMARK = 23
; sets index to be used in a table-type recordset
CONST DAORSATTSETCURRENTINDEX = 24
; returns the value of the specified parameter (if numeric, consider the position; if string, consider the name)
CONST DAORSATTGETPARAMVALUE = 25
; sets current value for the specified parameter to Null (no value)
CONST DAORSATTSETPARAMVALUENULL = 26

; -----------------------------------------------------------------------------------------

; Attribute names for DAOTDATTRIB

; returns not-zero if the table can be updated (it is possible to modify field definitions or table properties)
CONST DAOTDCANUPDATE = 1 
; returns table attributes
CONST DAOTDATTRIBUTES = 2  
; returns a value that gives information about table source
CONST DAOTDCONNECT = 3
; returns creation date for the table
CONST DAOTDCREATDATE = 4 
; returns creation time for the table
CONST DAOTDCREATTIME = 5
; returns last update date
CONST DAOTDLASTUPDATE = 6
; returns last update time
CONST DAOTDLASTUPDTIME = 7
; returns number of fields in the table
CONST DAOTDNUMFIELDS = 8
; returns information about field exp (if numeric, consider position; if string, consider name); returns an array
; with 14 elements, see DAORSGETFIELDINFO  
CONST DAOTDFIELDINFO = 9
; returns number of indexes
CONST DAOTDINDEXCOUNT = 10
; returns information about index exp (if numeric, consider position; if string, consider name); returns an array
; with 9 elements, see DAORSGETINDEXINFO  
CONST DAOTDINDEXINFO = 11
; returns table name
CONST DAOTDNAME = 12
; returns number of records accessed in the table
CONST DAOTDRECCOUNT = 13   
; returns the name of the source table
CONST DAOTDSOURCE = 14
; returns validation rule
CONST DAOTDVALRULE = 15 
; returns text displayed when validation fails
CONST DAOTDVALTEXT = 16
; returns non-zero if the table is open
CONST DAOTDISOPEN = 17
; sets to exp the value of table attributes
CONST DAOTDSETATTR = 18 
; sets to exp the value of connection string
CONST DAOTDSETCONN = 19
; sets to exp the name of the table
CONST DAOTDSETNAME = 20
; sets to exp the name of the source table
CONST DAOTDSETSOURCE = 21
; sets to exp the validation rule
CONST DAOTDSETVALRULE = 22
; sets to exp the text displayed when validation fails
CONST DAOTDSETVALTEXT = 23

; -----------------------------------------------------------------------------------------

; Attribute names for DAOQDATTRIB

; returns non-zero if the query can update the database
CONST DAOQDCANUPDATE = 1
; returns connection string connected to QueryDef  
CONST DAOQDCONNECT = 2
; returns creation date for QueryDef  
CONST DAOQDCREATDATE = 3 
; returns creation time for QueryDef    
CONST DAOQDCREATTIME = 4
; returns last update date
CONST DAOQDLASTUPDATE = 5
; returns last update time
CONST DAOQDLASTUPDTIME = 6
; returns the name of the QueryDef  
CONST DAOQDNAME = 7
; returns the timeout used by ODBCS when the query is run
CONST DAOQDODBCTOUT = 8
; returns number of records influenced by the query
CONST DAOQDRECAFFECT = 9
; returns non-zero if the query returns records
CONST DAOQDRETURNREC = 10
; returns the SQL string that defines the query
CONST DAOQDSQL = 11
; returns query type: delete, update, append, create table, etc.
CONST DAOQDTYPE = 12    
; returns non-zero if the query is open
CONST DAOQDISOPEN = 13   
; sets connection string for a SQL pass-through query over an open ODBC data source
CONST DAOQDSETCONN = 14 
: sets the name of the saved query, replacing the name assigned when it was created
CONST DAOQDSETNAME = 15
; sets the timeout value used by ODBC when the query will be run
CONST DAOQDSETODBCTO = 16
; specifies if the query returns records; valid only for SQL pass-through queries
CONST DAOQDSETRETREC = 17
; sets the SQL string that defines the query
CONST DAOQDSETSQL = 18

; -----------------------------------------------------------------------------------------

; Constants for DAOQDPARAMINFO

; parameter name
CONST DAOQDPNAME = 1
; parameter type
CONST DAOQDPTYPE = 2
; parameter value
CONST DAOQDPVALUE = 3

; ----------------------------------------------------------------------------------------- 

; Possible opening mode for DAORSOPEN

; table type with bidirectional scrolling
CONST DAOCOpenTable = 1
; dynaset type with bidirectional scrolling. This is the default
CONST DAOCOpenDynaset = 2
; snapshot type with bidirectional scrolling
CONST DAOCOpenSnapshot = 4
; forward-only type (unsupported)
; CONST DAOCOpenForwardOnly = 8
; dynamic type
CONST DAOCOpenDynamic = 16

; -----------------------------------------------------------------------------------------

; Possible types for DAORSGETFIELDINFO

; 1 (TRUE) or 0 (FALSE)
CONST DAOCBoolean = 1
; byte (0-255)
CONST DAOCByte = 2
; integer (16 bits)
CONST DAOCInteger = 3
; long integer (32 bits)
CONST DAOCLong = 4
; currency
CONST DAOCCurrency = 5
; floating point, single precision
CONST DAOCSingle = 6
; floating point, double precision
CONST DAOCDouble = 7
; date
CONST DAOCDate = 8
; binary
CONST DAOCBinary = 9
; text
CONST DAOCText = 10
; long binary
CONST DAOCLongBinary = 11
; memo
CONST DAOCMemo = 12
; GUID
CONST DAOCGUID = 15
; big integer (64 bits)
CONST DAOCBigInt = 16
; variable binary
CONST DAOCVarBinary = 17
; character
CONST DAOCChar = 18
; generic numeric
CONST DAOCNumeric = 19
; numeric decimal
CONST DAOCDecimal = 20
; floating point
CONST DAOCFloat = 21
; time
CONST DAOCTime = 22
; date/time
CONST DAOCTimeStamp = 23
; Null
CONST DAOCNull = 25

; -----------------------------------------------------------------------------------------

; Possible attributes for DAORSGETFIELDINFO

; fixed length field (default for numeric fields)
CONST DAOCFixedField = 1
; variable length field (only for text fields)
CONST DAOCVariableField = 2
; the value for the new records is automatically increased to a new long value that can not
; be modified; supported only for Microsoft® Jet tables
CONST DAOCAutoIncrField = 16
; field value can be updated
CONST DAOCUpdatableField = 32
; field is sorted in decreasing order (Z-A or 100-0); applies only to index fields
CONST DAOCDescending = 1

; -----------------------------------------------------------------------------------------

FUNCTION DAORSEOF(rs)

; Returns non-zero if the recordset was positioned beyond last record
RETURN DAORSATTRIB(rs, _DAORSATTISEOF)


FUNCTION DAORSBOF(rs)

; Returns non-zero if the recordset was positioned before first record
RETURN DAORSATTRIB(rs, _DAORSATTISBOF)
Midnight Lake iPhone Case Black Women Shoes Black Flat Shoes Leather Flats Black Patent Ballerinas Black Ballet Shoes Casual Shoes Black Shoes Women Balle Record Player Cufflinks Best iPhone XR Clear Cases iPhone XS/XS Max Leather Cases Sale Best iPhone 8/8 Plus Silicone Cases iPhone 7/7 Plus Cases & Screen Protector New Cases For iPhone 6/6 Plus iPhone 8 Case Sale iPhone Xr Case Online iPhone 7 Case UK Online iPhone X Case UK Sale iPhone X Case Deals iPhone Xs Case New Case For iPhone Xr UK Online Case For iPhone 8 UK Outlet Fashion Silver Cufflinks For Men Best Mens Cufflinks Outlet Online The Gold Cufflinks Shop Online Cheap Shirt Cufflinks On Sale Nice Wedding Cufflinks UK Online Top Black Cufflinks UK Online Mens Cufflinks Online Silver Cufflinks For Men Men Cufflinks UK Sale Gold Cufflinks UK Online Gold Cufflinks UK Silver Cufflinks UK Shirt Cufflinks Discount Online Mens Cufflinks Deals & Sales Girls Shoes For Dance Fashion Ballet Dance Shoes Best Ballet Flats Shoes UK Online Cheap Ballet Pointe Shoes UK Online Best Ballet Shoes Outlet Best Dance Shoes Sale Cheap Ballet Flats Sale UK Best Pointe Shoes Online UK Ballet Dance Shoes UK Shoes For Dance UK Best Ballet Slippers Shop Best Yoga Shoes Hotsell