最新的PostgreSql官方psqlODBC驱动程序(版本11.00.0000,32位)在Microsoft Visual Foxpro中不返回错误详细信息。
错误FoxPro命令后
AERROR(laerror)
disp memory like laerror
在laerror第三元素中返回相同的错误消息:
LAERROR Local A showerror
( 1, 1) N 1526 ( 1526,00000000)
( 1, 2) C "Connectivity error: ERROR: insert or update o
n table "rid" violates foreign key constraint
"rid_yhik_fkey";
Error while executing the que
ry"
( 1, 3) C "ERROR: insert or update on table "rid" violat
es foreign key constraint "rid_yhik_fkey";
Err
or while executing the query"
( 1, 4) C "23503"
( 1, 5) N 1 ( 1,00000000)
( 1, 6) N 1 ( 1,00000000)
( 1, 7) C
SYS(2018)也包含相同的消息。
在较旧的psqlODBC驱动程序版本中
laError [1,3]包含错误详细信息:
表(mootyhik)中不存在键(yhik)=(TK)。
如何使用最新的psqlODBC驱动程序获取错误详细信息? 如果可以从FoxPro调用,我可以提供odbc日志或使用其他ODBC API调用