您好,欢迎访问一九零五行业门户网

MySQL和.Net2.0配合使用_PHP教程

mysql现在的最新版本是5.x.第一次接触它是在大二的时候,用php,那时好像还是4.x版本。
mysql5增加很多新的功能,开始支持:存储过程、触发器、视图、信息架构视图等...
mysql在安装时一如既往的比较复杂,往往就是一个失败的提示,没有什么其它提示原因。
这是一篇文章,比较mysql和sqlserver的,http://htm.winsteps.net/database/331.htm
mysql中文网站http://www.mysql.cn/上资料很少,大多是些安装帮助。
要查资料还是去mysql的网站http://www.mysql.com/。
mysql现在有提供的各种连接工具(http://dev.mysql.com/downloads/connector/),.net下可以用的有connector/odbc和connector/net。
odbc连接效率可能稍低,最好还是用net直接的连接
这篇文章介绍了各种连接方法http://www.mysql.com/news-and-events/press-release/release_2002_10.html
1:odbc连接
现在的版本是3.51,安装之后,可以这样操作:
// string constr = driver = {mysql odbc 3.51 driver}; server = localhost; database =test; uid = root; password=;;
//string constr = driver={mysql odbc 3.51 driver};server=localhost;database=test;user=root;password=;option=3;;
string constr = provider = mysql odbc 3.51 driver; server = localhost; database =test; uid = root; password=;;
try
{
oledbconnection connection = new oledbconnection(constr);
connection.open();
}
catch(exception ex)
{
messagebox.show(ex.message);
}
2:net连接:
mysql connector net 1.0.7:有net1.0;net.1;net2.0;mono1.0四个版本的connector。免费
corelab.mysql 3.5:这是个商业的版本,试用期30天。
下边的代码是使用mysql connector net 的例子。注意:他的parameter的前缀是“?”而不是“@”。这个问题比较特殊。corelab里面的parameter的前缀就是“@”.
http://www.bkjia.com/phpjc/631036.htmlwww.bkjia.comtruehttp://www.bkjia.com/phpjc/631036.htmltecharticlemysql现在的最新版本是5.x.第一次接触它是在大二的时候,用php,那时好像还是4.x版本。 mysql5增加很多新的功能,开始支持:存储过程、触发...
其它类似信息

推荐信息