項目中遇到的
下面的程序是同不Sql
using System;
using System
using System
using System
using System
using System
using System
namespace DB
{
class Program
{
static void Main(string[] args)
{
OdbcConnection DB
//這裡是用數據源連接的
//DataSourceName 數據源名稱
//UserName 用戶名
//pwd 用戶口令
//OdbcCommand
SqlConnection conSql = new SqlConnection(
DB
SqlDataAdapter ZDAdapter = new SqlDataAdapter(new SqlCommand(
SqlCommandBuilder myCommandBuilder = new SqlCommandBuilder(ZDAdapter);
DataSet ZDDataSet = new DataSet();
ZDAdapter
for (int i =
{
Console
DataRow row = ZDDataSet
int KHDM =
try
{
KHDM = int
}
catch (Exception paresException)
{
KHDM =
}
//KHDM
if (
{
OdbcCommand cmdSelect = new OdbcCommand(
OdbcDataReader odbcReader= cmdSelect
if (odbcReader
{
row[
row[
row[
row[
}
odbcReader
}
}
Console
ZDAdapter
Console
Console
Console
}
}
}
但可能有朋友要問了
然後運行
From:http://tw.wingwit.com/Article/program/ASP/201311/21832.html