09 2013 档案
C#获取数据库表信息,列信息
摘要:获取表的信息:conn.Open();string[] restrictions = new string[4];restrictions[1] = "dbo"; DataTable table = conn.GetSchema("Tables", restrictions); conn.Close(); 返回的table是表的所有信息,而不仅仅是名字,可以通过如下语句查看这些信息:foreach (System.Data.DataRow row in table.Rows){foreach (System.Data.DataColumn col in
阅读全文
浙公网安备 33010602011771号