|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stay one step ahead of the competition. Evaluate and give feedback
on some of the hottest web development tools on the market today.
Make your opinion heard! Click
Here
|
|
#1
|
|||
|
|||
|
problem searching and display using php with oracle
Problem
Currently i am creating a system using php that integreate with oracle database.I am having a problem to display the result that retrieve the data from database When the user try to search the details of the particular staff. Below is the coding to retrieve and display the result. Note: Connecting to the database using OCI8 is successfull. PHP Code:
Bellow is the error messages that display when run this code! Warning: ociexecute(): supplied argument is not a valid OCI8-Statement resource in c:\program files\apache group\apache\htdocs\searc_only_view.php on line 71 Warning: ocifetchinto(): supplied argument is not a valid OCI8-Statement resource in c:\program files\apache group\apache\htdocs\searc_only_view.php on line 109 Notes: For the full coding --->URL, If u cannot view, please right click and click view source. Last edited by pabloj : June 9th, 2004 at 03:14 AM. |
|
#2
|
||||
|
||||
|
I've done some development with Php and Oracle 9.2 using Oracle extension (not OCI) but I hope this code can help:
PHP Code:
__________________
My blog about OpenSource Databases PDF tutorials about OSS databases, DBMonster ... Please contribute to Open Source Development, fill bug reports!!! Developer Shed eSupport Commented my.ini/my.cnf (PLEASE ADD YOUR OWN CONFIG TRICK) An introduction to database normalization Natural or Surrogate key Custom ordering for your results Correlated and uncorrelated subqueries Don't turn your outer joins into inner joins |
|
#3
|
|||
|
|||
|
problem with searching
tahnks for the respon.. FYI i'm using OCI because the there are a better than ORA. my problem is that searching command can be displayed only by static the searching not using the interface or $staff_id address reference
<?php if(!empty($do)) { if($do == "staff_id") { $search = "SELECT LIABILITIES.LIAB_ID FROM LIABILITIES,EMPLOYEE WHERE EMPLOYEE.STAFF_ID = LIABILITIES.STAFF_ID AND EMPLOYEE.STAFF_ID='$staff_id'; } if($do == "staff_name"){ //$search ="SELECT reservation.Resv_Id, reservation.No_PerChild, reservation.Resv_Arri, reservation.Resv_Dept, room.Ro_Type FROM reservation, room WHERE reservation.Ro_Id=room.Ro_Id and reservation.Resv_Id ='$Resv_Id';"; } $search_result = OCIParse($conn,$search); $search_res = OCIExecute($search_result); ?> the bold text refer to the problem..it only display when i'm state the WHERE EMPLOYEE.STAFF_ID = LIABILITIES.STAFF_ID AND EMPLOYEE.STAFF_ID='12345' hope that can somebody help me to solve the problem. |
![]() |
| Viewing: Dev Shed Forums > Databases > Oracle Development > problem searching and display using php with oracle |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|