[太原做APP]ASP语言连接 MSSQL的方法?

2018-11-19 11:37:23      点击:

[太原做APP]ASP语言连接 MSSQL的方法?

mssql_datahost = "127.0.0.1" '数据库地址

mssql_dataname = "dataname" '数据库名称

mssql_username = "sa" '数据库用户名

mssql_password = "123" '数据库密码

connstr = "Provider = Sqloledb; User ID = "&mssql_username&"; Password = "&mssql_password&"; Initial Catalog = "&mssql_dataname&"; Data Source = "&mssql_datahost&";"

Set conn = Server.CreateObject("ADODB.CONNECTION")

conn.Open connstr

太原做网站,找小程故事