求高手指点,一个PDA程序,sqlite数据库连接不上,急
string ConStr="data source=C:\ceshi.db;verson=3;password=123456";
SQLiteConnection MyConnection = new SQLiteConnection(ConStr);
try
{
MyConnection.Open();
MessageBox.Show("OK");
using (SQLiteCommand SQLCom = new SQLiteCommand(MyConnection))
{
string strSQL = @"SELECT num from ceshi;";
SQLCom.CommandText = strSQL;
SQLiteDataReader SQLReader = SQLCom.ExecuteReader();
while (SQLReader.NextResult() != false)
{
this.label1.Text = SQLReader["num"].ToString();
}
}
MyConnection.Close();
}
catch (Exception err)
{
throw err;
}
路径不对吧。
string ConStr="data source=C:\ceshi.db;verson=3;password=123456";
PDA上不存在类似C:\这东东吧。
相关问答:
delphi连接Sqlite 增删改查例子
数据库已经连通了, 插入会报错,no query specified
with dm.ASQLite3Query1 do
begin
dm.ASQLite3Query1.Close;
dm.ASQLite3 ......
如下语句 :
select TimeSpan from T_Table where onlineDate = '2009-12-2'
数据库里面有符合条件的值但是查不出来
如果改成如下:
select TimeSpan from T_Table where onlineDate = '200 ......
大家好!
sqlite字段为float型的值怎样访问?
试过用sqlite3_column_double,确返回的数据不正确;
没用过,帮顶.
一样啊,返回全是 string
你的代码是什么?
double sqlite3_column_double(sqli ......
sqlite的空值查询怎么写,能者得分
select * from tt where f1 is null
select * from yourTable where col is null;
SQL code:
sqlite> create table Aoqun (id int primary key,col1 int);
sqlite> ......