这段代码有什么问题。在插入新序列号之前,我正在检查数据库中是否有可用记录。当我输入任何可用或不可用的记录时,它会引发错误消息:
“表达式无效”。(PowerBuilder Classic 12.5 和 SQL Server 2008)
If This.GetColumnName() = "serial_No" Then
long ll_serial
ll_serial=dw_newrecord.find(data, 1, dw_newrecord.rowcount())
if ll_serial>0 then
messagebox("validation error", "The record already exists")
return 1
end if
End If