我试图在 FM 中插入数据,但没有运气得到解析错误 serached number of fourms。错误 [HY000] [DataDirect][ODBC SequeLink 驱动程序][ODBC 套接字][DataDirect][ODBC FileMaker 驱动程序][FileMaker]SQL 中的解析错误
enter code here
StringBuilder sbAddBarcode = new StringBuilder(); sbAddBarcode.Append("插入条码 (PONumber,Description,Model,[Serial Number])"); sbAddBarcode.Append("值"); sbAddBarcode.Append(" ("+barcode.PONumber + ","); sbAddBarcode.Append(" '" + barcode.Description +"',"); sbAddBarcode.Append(" '" + barcode.ModelNumber +"') "); //sbAddBarcode.Append(" '" + barcode.SerialNumber +"')");
fmCommand = new OdbcCommand(sbAddBarcode.ToString(), fmcon);
fmCommand.CommandType = CommandType.Text;
fmCommand.Connection = fmcon;
try
{
fmcon.Open();
fmCommand.ExecuteNonQuery();
}
catch (OdbcException oe)
{
throw new Exception(oe.Message);
}
catch (Exception ex)
{
throw new Exception(ex.Message);
}
finally
{
fmcon.Close();
}