<!--#include file="../inc/database_name.asp" -->
<%
Response.Buffer=True
IsSqlDataBase=0	'定义数据库类别，0为Access数据库，1为SQL数据库
If IsSqlDataBase=0 Then
'''''''''''''''''''''''''''''' Access数据库 '''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Db = "../database/"&dataname&""	'数据库路径
ConnStr="Provider=Microsoft.Jet.OLEDB.4.0;Data Source="&Server.MapPath(db)
SqlNowString="getdate()"
SqlChar="'"
IsSqlVer="ACCESS"
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Else
'''''''''''''''''''''''''''''' SQL数据库 ''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
SqlLocalName   ="(local)"	'连接IP  [ 本地用 (local) 外地用IP ]
SqlUserName    ="sa"		'用户名
SqlPassword    ="wishcn.com"		'用户密码
SqlDatabaseName="job_wishcn"		'数据库名
ConnStr = "Provider=Sqloledb;User ID=" & SqlUserName & "; Password=" & SqlPassword & "; Initial CataLog = " & SqlDatabaseName & "; Data Source=" & SqlLocalName & ";"
SqlNowString="getdate()"
IsSqlVer="SQL"
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
END IF
'''''''''''''''''''''''''''''' 网站出错信息显示开始 '''''''''''''''''''''''''''''''''''''''''''''''''
On Error Resume Next
Set conn = Server.CreateObject("ADODB.Connection")
conn.commandtimeout=90
conn.open ConnStr
If Err Then
err.Clear
Set Conn = Nothing
Response.Write "<br><br><br><br><br><br><br><div align='center'>数据库连接出错!请检查连接数据库的参数及字符串设置是否正确！</div>"
Response.End
'''''''''''''''''''''''''''''' 网站出错信息显示结束 '''''''''''''''''''''''''''''''''''''''''''''''''
End If
%>