11 May 2004 Kevin Rosenberg (kevin@rosenberg.net)
+ * db-odbc/odbc-api.lisp: work around return-type bug [spr28889] in
+ Allegro 7.0beta AMD64
* db-odbc/*.lisp: Add a layer of indirection to foreign-type
of ODBC longs since this type can vary on 64-bit platforms depending
upon the compilation options of unixODBC.
'clsql-base:clsql-odbc-error
:odbc-message error-message
:sql-state sql-state)))
+ (#.$SQL_NO_DATA_FOUND
+ (progn ,result-code ,@body))
+ ;; work-around for Allegro 7.0beta AMD64 which
+ ;; has for negative numbers
(otherwise
+ (multiple-value-bind (error-message sql-state)
+ (handle-error (or ,henv +null-handle-ptr+)
+ (or ,hdbc +null-handle-ptr+)
+ (or ,hstmt +null-handle-ptr+))
+ (error
+ 'clsql-base:clsql-odbc-error
+ :odbc-message error-message
+ :sql-state sql-state))
+ #+ignore
(progn ,result-code ,@body))))))
(defun %new-environment-handle ()
(cbColNameMax :short) ; SWORD cbColNameMax
(*pcbColName (* :short)) ; SWORD FAR *pcbColName
(*pfSqlType (* :short)) ; SWORD FAR *pfSqlType
- (*pcbColDef (* :unsigned-int)) ; UDWORD FAR *pcbColDef
+ (*pcbColDef (* #.$ODBC-ULONG-TYPE)) ; UDWORD FAR *pcbColDef
(*pibScale (* :short)) ; SWORD FAR *pibScale
(*pfNullable (* :short)) ; SWORD FAR *pfNullable
)
(typep float 'double-float)
(if (and (eq :odbc *test-database-type*)
(eq :postgresql *test-database-underlying-type*))
- ;; ODBC/Postgresql returns bigints as strings
- (stringp bigint)
+ ;; ODBC/Postgresql may return returns bigints as strings or integer
+ ;; depending upon the platform
+ t
(integerp bigint))
(stringp str))
results))))