' Maximum number of significant characters in named entity:
Global Const SqlMaximumNameLength = 32
' Global types:
Type SqlColumnType
RightJustified As Integer
ColumnHeading As String * 33
ColumnSequenceNumber As Integer
DataType As Integer
DataClass As Integer
FieldWidth As Integer
Precision As Integer
Scale As Integer
End Type
Type SqlControlType
ErrorDetail As String * 65
ErrorMessage As String * 257
HiLiteLength As Integer
HiLiteOffset As Integer
Padding As Integer
RecordBufferSize As Integer
ResultCode As Integer
RecordPosition As Long
Reserved0 As Long
Reserved1 As Long
Reserved2 As Long
Reserved3 As Long
Reserved4 As Long
Flags As Integer
End Type
Type SqlStatusType
NumberOfRecordDeletes As Long
NumberOfRecordInserts As Long
NumberOfRecordSelects As Long
NumberOfRecordUpdates As Long
TimeElapsed As Long
End Type
Type SqlTableType
NumberOfColumns As Integer
RecordSize As Integer
NumberOfRecords As Long
End Type
' Function prototypes:
Declare Function SqlCursorClose Lib "sql.dll" (ByVal User As Integer, ByVal Cursor As Integer, SqlControl As SqlControlType) As Integer
Declare Function SqlCursorOpen Lib "sql.dll" (ByVal User As Integer, SqlControl As SqlControlType) As Integer
Declare Function SqlDescribeColumn Lib "sql.dll" (ByVal User As Integer, ByVal Cursor As Integer, SqlControl As SqlControlType, ByVal ColumnNumber As Integer, SqlColumn As SqlColumnType) As Integer
Declare Function SqlDescribeTable Lib "sql.dll" (ByVal User As Integer, ByVal Cursor As Integer, SqlControl As SqlControlType, SqlTable As SqlTableType) As Integer
Declare Function SqlExecute Lib "sql.dll" (ByVal User As Integer, ByVal Cursor As Integer, SqlControl As SqlControlType, ByVal QueryText As String) As Integer
Declare Function SqlFetchFirst Lib "sql.dll" (ByVal User As Integer, ByVal Cursor As Integer, SqlControl As SqlControlType, ByVal RecordBuffer As String) As Integer
Declare Function SqlFetchLast Lib "sql.dll" (ByVal User As Integer, ByVal Cursor As Integer, SqlControl As SqlControlType, ByVal RecordBuffer As String) As Integer
Declare Function SqlFetchNext Lib "sql.dll" (ByVal User As Integer, ByVal Cursor As Integer, SqlControl As SqlControlType, ByVal RecordBuffer As String) As Integer
Declare Function SqlFetchPositioned Lib "sql.dll" (ByVal User As Integer, ByVal Cursor As Integer, SqlControl As SqlControlType, ByVal RecordPosition As Long, ByVal RecordBuffer As String) As Integer
Declare Function SqlFetchPrevious Lib "sql.dll" (ByVal User As Integer, ByVal Cursor As Integer, SqlControl As SqlControlType, ByVal RecordBuffer As String) As Integer
Declare Function SqlGetStatus Lib "sql.dll" (ByVal User As Integer, ByVal Cursor As Integer, SqlControl As SqlControlType, SqlStatus As SqlStatusType) As Integer
Declare Function SqlLogin Lib "sql.dll" (SqlControl As SqlControlType, ByVal UserName As String, ByVal UserPassword As String) As Integer
Declare Function SqlLogout Lib "sql.dll" (ByVal User As Integer, SqlControl As SqlControlType) As Integer