游客发表

VS2005连接MySQL数据库的实际操作流程

发帖时间:2025-11-03 13:24:01

VS2005连接MySQL数据库的实际操作流程
复制string connStr = String.Format("server=;user id={1}; password={2}; database={3}; pooling=false;port=3306",连接 "127.0.0.1", "test", "test", "test");   MySQLConnection myConn = newMySQLConnection(connStr);   myConn.Open();   MySQLCommand cmd = myConn.CreateCommand();   string sql1 = "CREATE TEMPORARY TABLE tmp_table (maxonline int,srv_ip VARCHAR(30),fld_date datetime)";   string sql2 = @"insert into tmp_table SELECT 33,ip1,2007-5-5";   1.2.3.4.5.6.

    热门排行

    友情链接