1234567891011121314151617181920212223242526 |
- <%Session.CodePage=65001%>
- <%
- On Error Resume Next
- Dim Conn
- Sub OpenConn()
- On Error Resume Next
- Dim ConnStr
- ConnStr = "DRIVER={PostgreSQL ODBC Driver(UNICODE)}; SERVER=127.0.0.1; port=5432; DATABASE=stoneu; UID=postgres; PWD=stoneu_4k;"
- Set Conn = Server.CreateObject("ADODB.Connection")
- Conn.open ConnStr
- If Err Then
- Err.Clear
- Set Conn = Nothing
- Response.Write "Connection Error!"
- Response.End
- End If
- End Sub
- Sub CloseConn()
- On Error Resume Next
- If IsObject(Conn) Then
- Conn.Close
- Set Conn = Nothing
- End If
- End Sub
- %>
|