apache1.3.9+php4+informix on linux 6.0 , ifx_connect() error 
Author Message
 apache1.3.9+php4+informix on linux 6.0 , ifx_connect() error

Hi,i'm a beginner of php programming.
I have installed apache1.3.9+php4+informix .
I have an error on my first php programming ,
so difficult for me to solve.
Following source is part of php surce,i guess make a error.(line number +
source)
--------------------------------------------------

10 if($op1 == "next")
11 szQuery = "select custor_num,fname,lname,company
                     from customer
                     where customer_num >= ".$RecNo1;
12 else
13 $szQuery = "select customer_num,fname,lname,company
                       from customer
                       where customer_num <= ".$RecNo1."
                       order by customer_num desc";
14
15 $HandleCR =  ifx_prepare($szQuery,HandleDB,IFX_SCROLL);
16 if(!$HandleCR)
17 {
18   printf("cannot prepare(%s),(%s)\n",
             ifx_error(),ifx_errormsg());
19   ifx_close($HandleDB);
20   return $ArrCustomer;
21 }
--------------------------------------------------
error status is followed.
--------------------------------------------------
Warning: Informix: Too many open links (0) in
/usr/local/apache/htdocs/jay/customer.html on line 9

Warning: ifx_query : 0 (type -1) is not a Informix link index in
/usr/local/apache/htdocs/jay/customer.html on line 15

cannot prepare(E [SQLSTATE=),()
Warning: ifx_close : 0 (type -1) is not an Informix link index in
/usr/local/apache/htdocs/jay/customer.html on line 19
--------------------------------------------------

i think there was no error when compiling & installing
apache1.3.9+php4+informix.
Help me!!, please.

added  the html file created by phpinfo() function.
(configurations of my system.)



Wed, 18 Jun 1902 08:00:00 GMT
 apache1.3.9+php4+informix on linux 6.0 , ifx_connect() error

Quote:

> Hi,i'm a beginner of php programming.
> I have installed apache1.3.9+php4+informix .
> I have an error on my first php programming ,
> so difficult for me to solve.
> Following source is part of php surce,i guess make a error.(line
> number +
> source)
> --------------------------------------------------


How and where do you error check the $HandleDB is valid?

Quote:
> 10 if($op1 == "next")
> 11 szQuery = "select custor_num,fname,lname,company
>                      from customer
>                      where customer_num >= ".$RecNo1;
> 12 else
> 13 $szQuery = "select customer_num,fname,lname,company
>                        from customer
>                        where customer_num <= ".$RecNo1."
>                        order by customer_num desc";

Why does szQuery on 11 not have the $ prefix that is on line 13,
or vice versa?

Quote:
> 14
> 15 $HandleCR =  ifx_prepare($szQuery,HandleDB,IFX_SCROLL);
> 16 if(!$HandleCR)
> 17 {
> 18   printf("cannot prepare(%s),(%s)\n",
>              ifx_error(),ifx_errormsg());
> 19   ifx_close($HandleDB);
> 20   return $ArrCustomer;
> 21 }
> --------------------------------------------------
> error status is followed.
> --------------------------------------------------
> Warning: Informix: Too many open links (0) in
> /usr/local/apache/htdocs/jay/customer.html on line 9

It sounds like you've got a connect problem on line 9.

Quote:
> Warning: ifx_query : 0 (type -1) is not a Informix link index in
> /usr/local/apache/htdocs/jay/customer.html on line 15

This is probably failing because HandleDB is not valid.

Quote:
> cannot prepare(E [SQLSTATE=),()
> Warning: ifx_close : 0 (type -1) is not an Informix link index in
> /usr/local/apache/htdocs/jay/customer.html on line 19

Ditto.

Quote:
> --------------------------------------------------

> i think there was no error when compiling & installing
> apache1.3.9+php4+informix.
> Help me!!, please.

> added  the html file created by phpinfo() function.
> (configurations of my system.)

--

Guardian of DBD::Informix v0.60 -- see http://www.perl.com/CPAN
#include <disclaimer.h>


Wed, 18 Jun 1902 08:00:00 GMT
 apache1.3.9+php4+informix on linux 6.0 , ifx_connect() error

Quote:

> Hi,i'm a beginner of php programming.
> I have installed apache1.3.9+php4+informix .
> I have an error on my first php programming ,
> so difficult for me to solve.
> Following source is part of php surce,i guess make a error.(line
> number +
> source)
> --------------------------------------------------

> 10 if($op1 == "next")

And, further to my previous analysis, since you are using Apache,
the problem is probably related to the environment variables you
do (or, much more likely, don't) have set while Apache is running.

--

Guardian of DBD::Informix v0.60 -- see http://www.perl.com/CPAN
#include <disclaimer.h>



Wed, 18 Jun 1902 08:00:00 GMT
 apache1.3.9+php4+informix on linux 6.0 , ifx_connect() error

Quote:


> > Hi,i'm a beginner of php programming.
> > I have installed apache1.3.9+php4+informix .
> > I have an error on my first php programming ,
> > so difficult for me to solve.
> > Following source is part of php surce,i guess make a error.(line
> > number +
> > source)
> > --------------------------------------------------

> > 10 if($op1 == "next")

> And, further to my previous analysis, since you are using Apache,
> the problem is probably related to the environment variables you
> do (or, much more likely, don't) have set while Apache is running.

I am totally new to doing PHP/informix stuff myself. What env variables
should be set in Apache for this to work properly?

Just getting started, I have not been able to get an ifx_connect() to
work yet. I put in a bogus username and I got the same errors, so I'm
not even getting to the DB server.

Here are my errors after a simple

(even thought the warning refers to ifx_pconnect):

Warning: ifx_pconnect : E [SQLSTATE=IX 000 SQLCODE=-461] in
/home/apache/sslhtdocs/itug_98/testdb.php3 on line 7
Unable to load locale categories.

TIA,
Chuck

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.



Wed, 18 Jun 1902 08:00:00 GMT
 
 [ 4 post ] 

 Relevant Pages 

1. Linux + Oracle8 + PHP3 + Apache1.3

2. RedHat Linux 6.0 and Informix JDBC problem

3. DBD-Informix 6.0 on Linux

4. informix ids 7.30 UC7 with Linux RedHat 6.0 (K 2.2.5-15)

5. Informix 4GL on RedHat Linux 6.0 not working

6. Accessing PostgreSQL through Apache and PHP4 on Linux

7. Oracle8i + Linux + PHP4

8. IBM DB2 and PHP4 on linux

9. Newbie Linux MySQL PHP4 Question

10. Linux, Ingres, Php4, Apache

11. Informix, Apache, and PHP4: sqlhosts, onconfig?


 
Powered by phpBB® Forum Software