PHP - Php And Oracle 10g Configration Help
hello every body,
I am trying to connect the oracle 10g with PHP code but my all code get error and does not get connection from the server database so i need the help from your site. can you help me My Code is:- <?php $db_host="xxx.xxx.xx.xxx"; // Host name $db_username="xxx"; // Mysql username $db_password="xxx"; // Mysql password $db_name="XE"; // Database name $tbl_name="USER_DETAIL"; // Table name // Connect to server and select database. try { $conn = "(DESCRIPTION=(ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = xxx.xxx.xx.xxx)(PORT = 1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVER_NAME=MYDB)))" ; $c= oci_connect($db_username, $db_password, $conn); $d=new PDO("oci:db_name=$conn",$db_username, $db_password); } catch(PDOException $e) { trigger_error("Could not connect to database",E_USER-ERROR); } Similar TutorialsI have this code that will get the absent dates for all employees, how can i make it for one specific employee using oracle id? code: $res = $conn->query("SELECT s.oracleid , s.staffname , date_format(date, '%W %d/%m/%Y') as absent FROM staff s CROSS JOIN date d LEFT JOIN attendance_records a ON s.oracleid = a.oracleid AND d.date = DATE(a.clockingindate) WHERE a.oracleid IS NULL ORDER BY s.oracleid, d.date "); the records i am concerned about is for the attendance records table, I have oracle id in that table. Hello, I need to interrupt the execution of an oracle query if it is taking more than 10 seconds, and give user a message informing him about execution timeout. I googled a lot but i didn't find anything useful. Is there any way to set a time limit to oci_execute. I cannot modify DB settings... Any Idea? Thnks I using.. Hey guys, I`m having problems finding information on how to insert a image on a blob column trough odbc on a oracle database. Does anyone knows where can i find it, or can anyone help me with sample code? I really need to use odbc functions (cant use oci8 ) Tanks for your time reading this and for the possible input you may add on this. Sincerely Arestas |