I'm new in php. I have some doubt in connect to my oracle. In my php server, I'm using ODBC to set the connection to my ORACLE server. I'm not sure how php can establish the connection. I had try to use odbc_connect but it was unsuccessful.
I can successfully establish my oracle connection using ASP script. My script is something like below:
<%
ConnDSN="DSN=ServiceName;uid=user;pwd=password"
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.Open ConnDSN
SQLQuery1 = "select username from user where userid='11111'"
set rs1 = conn.execute(SQLQuery1)
response.write "User < 15: <b>" & rs1(0) & "</b><br>"
rs1.Close
set rs1=nothing
Conn.Close
SET Conn = Nothing
%>
I'm wonder how ADODB connection can be done in PHP or there is other way to do the same thing using PHP.
I really appreciate someone can advise me on this.
Thanks
I can successfully establish my oracle connection using ASP script. My script is something like below:
<%
ConnDSN="DSN=ServiceName;uid=user;pwd=password"
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.Open ConnDSN
SQLQuery1 = "select username from user where userid='11111'"
set rs1 = conn.execute(SQLQuery1)
response.write "User < 15: <b>" & rs1(0) & "</b><br>"
rs1.Close
set rs1=nothing
Conn.Close
SET Conn = Nothing
%>
I'm wonder how ADODB connection can be done in PHP or there is other way to do the same thing using PHP.
I really appreciate someone can advise me on this.
Thanks