[英]SQLJet Table insert parameter
I guess I have a strange error while insert a record in a SQLJet database. 我猜我在SQLJet数据库中插入记录时遇到一个奇怪的错误。 I open the database connection and use following code to insert a test record.
我打开数据库连接,并使用以下代码插入测试记录。
ISqlJetTable tbl = db.getTable("file");
tbl.insert("filename");
Eclipse shows me a red icon with the info message Eclipse向我显示一个带有信息消息的红色图标
The method insert(Object[]) in the type ISqlJetTable is not applicable for the arguments (String).
ISqlJetTable类型的方法insert(Object [])不适用于参数(字符串)。
What went wrong? 什么地方出了错? If I remember rightly on my mac I don't get this error message.
如果我在Mac上正确记得,我不会收到此错误消息。 I'm sorry I haven't access to my mac at the moment.
抱歉,我目前无法访问我的Mac。 How to fix this?
如何解决这个问题? The tutorial use the same way.
本教程使用相同的方法。 Greetz
格蕾兹
The method insert(Object[]) in the type ISqlJetTable is not applicable for the arguments (String).
ISqlJetTable类型的方法insert(Object [])不适用于参数(字符串)。
You need to pass String[]/Object[] instead of just String. 您需要传递String [] / Object []而不是仅传递String。 Based on documentation syntax for insert method is
insert(Object[] arr)
根据文档语法,insert方法为
insert(Object[] arr)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.