一 : 结果
二: 代码
using System;
using System.Collections.Generic;
using System.Data;
using System.Text;
using Microsoft.Practices.EnterpriseLibrary.Data.Sql;
using System.Data.SqlClient;
namespace list
{
class Program
{
static void Main(string[] args)
{
string connectionString = "server=.;uid=sa;pwd=123456;database=ceshifu;Connect Timeout=100;";
string sql = "SELECT top 1 cpClientId from SaClientPersonal where cpCredentialsId='360121199911061234'";
SqlCommand cmd = new SqlCommand();
cmd.CommandType = CommandType.Text;
cmd.CommandText = sql;
SqlDatabase database = new SqlDa