这是我的代码:
OleDbConnection connection = new OleDbConnection(
"Provider=Microsoft.ACE.OLEDB.12.0;Data Source=c:\\Offline.accdb;Persist Security Info=False");
connection.Open();
OleDbCommand command = connection.CreateCommand();
command.CommandText = "SELECT DISTINCT B.* FROM BlankFormSubmissions B, Actions A WHERE A.FormName = 'FindingNemo' AND B.ProcessName = A.ProcessName AND B.ActionName = A.ActionName AND B.ID = 12 OR B.ID = 13 OR B.ID = 14 ORDER BY B.ID";
OleDbDataReader reader = command.ExecuteReader();
while (reader.Read())
{
string xml = (string)reader["XML"];
// ... do something with xml
}
“XML”列是一个 Access 数据库表列,类型为 memo。
xml 的值始终只包含 XML 的第一个字符。我猜这是前 256 个字符。显然,我需要字符串中的所有字符。
有人知道怎么修这个东西吗?
谢谢 :)