📄 getinfo.frm
字号:
SpecialStr = "Partial outer joins."
Case "F"
SpecialStr = "Full outer joins."
Case Else
SpecialStr = "Missing data."
End Select
Case "SQL_NEED_LONG_DATA_LEN"
SpecialStr = IIf(RetStr = "Y", "Yes", "No")
Case "SQL_LIKE_ESCAPE_CLAUSE"
SpecialStr = IIf(RetStr = "Y", "Yes", "No")
Case "SQL_ACCESSIBLE_PROCEDURES"
SpecialStr = IIf(RetStr = "Y", "Yes", "No")
Case "SQL_ACCESSIBLE_TABLES"
SpecialStr = IIf(RetStr = "Y", "Yes", "No")
Case "SQL_DATA_SOURCE_READ_ONLY"
SpecialStr = IIf(RetStr = "Y", "Yes", "No")
Case "SQL_PROCEDURES"
SpecialStr = IIf(RetStr = "Y", "Yes", "No")
Case "SQL_ROW_UPDATES"
SpecialStr = IIf(RetStr = "Y", "Yes", "No")
Case Else
SpecialStr = "Missing special processing."
End Select
End Function
Private Function SpecialInt(Opt As String, RetInt As Integer)
'Do any special processing required for a SQLGetInfo integer
Select Case Opt
Case "SQL_CORRELATION_NAME"
Select Case RetInt
Case SQL_CN_NONE
SpecialInt = "Not supported."
Case SQL_CN_DIFFERENT
SpecialInt = "Supported but names vary."
Case SQL_CN_ANY
SpecialInt = "Any valid user name."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_NON_NULLABLE_COLUMNS"
Select Case RetInt
Case SQL_NNC_NULL
SpecialInt = "All columns nullable."
Case SQL_NNC_NON_NULL
SpecialInt = "May be non-nullable."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_FILE_USAGE"
Select Case RetInt
Case SQL_FILE_NOT_SUPPORTED
SpecialInt = "Not a single tier driver."
Case SQL_FILE_TABLE
SpecialInt = "Treats data source as table."
Case SQL_FILE_QUALIFIER
SpecialInt = "Treats data source as qualifier."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_NULL_COLLATION"
Select Case RetInt
Case SQL_NC_END
SpecialInt = "NULLs sorted to end."
Case SQL_NC_HIGH
SpecialInt = "NULLs sorted to high end."
Case SQL_NC_LOW
SpecialInt = "NULLs sorted to low end."
Case SQL_NC_START
SpecialInt = "NULLs sorted to start."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_GROUP_BY"
Select Case RetInt
Case SQL_GB_NOT_SUPPORTED
SpecialInt = "Group By not supported."
Case SQL_GB_GROUP_BY_EQUALS_SELECT
SpecialInt = "All non-aggregated columns, no others."
Case SQL_GB_GROUP_BY_CONTAINS_SELECT
SpecialInt = "All non-aggregated columns, some others."
Case SQL_GB_NO_RELATION
SpecialInt = "Not related to select list."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_IDENTIFIER_CASE"
Select Case RetInt
Case SQL_IC_UPPER
SpecialInt = "Upper case."
Case SQL_IC_LOWER
SpecialInt = "Lower case."
Case SQL_IC_SENSITIVE
SpecialInt = "Case sensitive."
Case SQL_IC_MIXED
SpecialInt = "Mixed case."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_QUOTED_IDENTIFIER_CASE"
Select Case RetInt
Case SQL_IC_UPPER
SpecialInt = "Upper case."
Case SQL_IC_LOWER
SpecialInt = "Lower case."
Case SQL_IC_SENSITIVE
SpecialInt = "Case sensitive."
Case SQL_IC_MIXED
SpecialInt = "Mixed case."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_ODBC_API_CONFORMANCE"
Select Case RetInt
Case SQL_OAC_NONE
SpecialInt = "No conformance."
Case SQL_OAC_LEVEL1
SpecialInt = "Level 1 supported."
Case SQL_OAC_LEVEL2
SpecialInt = "Level 2 supported."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_CURSOR_COMMIT_BEHAVIOR"
Select Case RetInt
Case SQL_CB_DELETE
SpecialInt = "Close and delete statements."
Case SQL_CB_CLOSE
SpecialInt = "Close cursors."
Case SQL_CB_PRESERVE
SpecialInt = "Preserve cursors."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_CURSOR_ROLLBACK_BEHAVIOR"
Select Case RetInt
Case SQL_CB_DELETE
SpecialInt = "Close and delete statements."
Case SQL_CB_CLOSE
SpecialInt = "Close cursors."
Case SQL_CB_PRESERVE
SpecialInt = "Preserve cursors."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_TXN_CAPABLE"
Select Case RetInt
Case SQL_TC_NONE
SpecialInt = "Transactions not supported."
Case SQL_TC_DML
SpecialInt = "DML statements only, DDL cause error."
Case SQL_TC_DDL_COMMIT
SpecialInt = "DML statements, DDL commit transaction."
Case SQL_TC_DDL_IGNORE
SpecialInt = "DML statements, DDL ignored."
Case SQL_TC_ALL
SpecialInt = "Both DML and DDL statements."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_QUALIFIER_LOCATION"
Select Case RetInt
Case SQL_QL_START
SpecialInt = "Start of name."
Case SQL_QL_END
SpecialInt = "End of name."
Case Else
SpecialInt = "Missing data."
End Select
Case "SQL_CONCAT_NULL_BEHAVIOR"
Select Case RetInt
Case SQL_CB_NULL
SpecialInt = "intResult is NULL valued."
Case SQL_CB_NON_NULL
SpecialInt = "intResult is non-NULL concatenation."
Case Else
SpecialInt = "Missing data."
End Select
Case Else
SpecialInt = "Missing special integer processing."
End Select
End Function
Private Function BitMask(RetBit As Long)
'Do processing required for a SQLGetInfo bit mask return
Dim I As Long, bin As String
Const maxpower = 30 ' Maximum number of binary digits supported.
bin = "" 'Build the desired binary number in this string, bin.
If RetBit > 2 ^ maxpower Then
BitMask = "Error converting data."
Exit Function
End If
' Negative numbers have "1" in the 32nd left-most digit:
If RetBit < 0 Then bin = bin + "1" Else bin = bin + "0"
For I = maxpower To 0 Step -1
If RetBit And (2 ^ I) Then ' Use the logical "AND" operator.
bin = bin + "1"
Else
bin = bin + "0"
End If
Next
BitMask = bin ' The bin string contains the binary number.
End Function
Private Function SpecialLong(Opt As String, RetInt As Integer)
'Do any special processing required for a SQLGetInfo long
Select Case Opt
Case "SQL_DEFAULT_TXN_ISOLATION"
Select Case RetInt
Case SQL_TXN_READ_UNCOMMITTED
SpecialLong = "Dirty reads, nonrepeatable, phantoms."
Case SQL_TXN_READ_COMMITTED
SpecialLong = "No dirty reads, but nonrepeatable and phantoms."
Case SQL_TXN_REPEATABLE_READ
SpecialLong = "No dirty or nonrepeatable reads. Phantoms okay."
Case SQL_TXN_SERIALIZABLE
SpecialLong = "Serializable transactions."
Case SQL_TXN_VERSIONING
SpecialLong = "Serializable transactions with higher concurrency."
Case Else
SpecialLong = "Missing data."
End Select
Case Else
SpecialLong = "Missing special Long processing."
End Select
End Function
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -