Fw: Mysql/mod_perl/DBI Problem in retireving rows

2002-06-29 Thread Subhrajyoti


Hi,
I am loading a couple of mysql tables through a perl module. Apache loads
this perl module during startup.
But when I query through mod_perl it fetches only limited number of rows
from MYSQL table. rest of the rows are just ignored.
Raw query from the mysql shell yields proper results.
Please tell me what I am doing wrong.

subhro.


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: Problem with a query

2002-06-29 Thread Mikhail Entaltsev

Hi Arul,

 What i meant to say is that My First Query returns 3 rows satisfying two
 conditions Like CI.IndustryID IN (2,3) and Count(C.CompanyID) = 2

 So when i add another OR say (CI.IndustryID IN (2,3) OR C.b2b = 'N') and
 Count(C.CompanyID) = 2

 I guess it should aways have the possibilty of returning more rows or the
 same rows..I wonder how the number of rows returned is decreased with an
OR
 Condition

Don't forget that SQL server will check HAVING clause after all others.
I mean that query plan will be:
1. Select those rows for which WHERE clause = TRUE
2. Group by them.
3. Take only those rows for which HAVING clause =TRUE.

Let's take my example and your queries again...

C.CompanyIDC.B2bCI.IndustryID
64Y2
64Y3
77N2
77N3
77N5
78Y2
78Y3


SELECT C.Companyid,C.B2b
FROM  Company C ,Company C1 , Company_Industries CI,
  Company_Type_Details CTD,Users U,User_Type_Details UTD
Where   C.Companyid=CTD.Companyid AND C.Companyid=U.Companyid
  AND UTD.UserId=U.UserId AND UTD.User_Typeid=2
  AND CTD.Company_Typeid=3 AND CTD.App_Status='APP'
  AND U.UserID  2 AND C.Company_App_Status='APP'
  AND C.Company_Status='ACT'
  AND C.CompanyID = CI.CompanyID
  AND C.CompanyID = C1.CompanyID
  AND (CI.IndustryID IN (2,3) )
Group By
  C.CompanyID,C.B2b
HAVING
 Count(C.CompanyID) = 2

After checking (CI.IndustryID IN (2,3)) we will have rows:
C.CompanyIDC.B2bCI.IndustryID
64Y2
64Y3
77N2
77N3
78Y2
78Y3

Then group by C.CompanyID,C.B2b and Count(C.CompanyID)

C.CompanyIDC.B2bCount(C.CompanyID)
64Y2
77N2
78Y2

after that server will take only record that have Count(C.CompanyID) = 2. In
this case it will take all 3 records.

Next query:
SELECT C.Companyid,C.B2b
FROM  Company C ,Company C1 , Company_Industries CI,
  Company_Type_Details CTD,Users U,User_Type_Details UTD
Where   C.Companyid=CTD.Companyid AND C.Companyid=U.Companyid
  AND UTD.UserId=U.UserId AND UTD.User_Typeid=2
  AND CTD.Company_Typeid=3 AND CTD.App_Status='APP'
  AND U.UserID  2 AND C.Company_App_Status='APP'
  AND C.Company_Status='ACT'
  AND C.CompanyID = CI.CompanyID
  AND C.CompanyID = C1.CompanyID
  AND (CI.IndustryID IN (2,3) OR C.B2b = 'N')
Group By
  C.CompanyID,C.B2b
HAVING
 Count(C.CompanyID) = 2

After checking (CI.IndustryID IN (2,3) OR C.B2b = 'N') we will have rows:
C.CompanyIDC.B2bCI.IndustryID
64Y2
64Y3
77N2
77N3
77N5
78Y2
78Y3

Then group by C.CompanyID,C.B2b and Count(C.CompanyID)
C.CompanyIDC.B2bCount(C.CompanyID)
64Y2
77N3
78Y2

after that server will take only record that have Count(C.CompanyID) = 2. In
this case it will take only:
C.CompanyIDC.B2bCount(C.CompanyID)
64Y2
78Y2

Next query:
SELECT C.Companyid,C.B2b
FROM  Company C ,Company C1 , Company_Industries CI,
  Company_Type_Details CTD,Users U,User_Type_Details UTD
Where   C.Companyid=CTD.Companyid AND C.Companyid=U.Companyid
  AND UTD.UserId=U.UserId AND UTD.User_Typeid=2
  AND CTD.Company_Typeid=3 AND CTD.App_Status='APP'
  AND U.UserID  2 AND C.Company_App_Status='APP'
  AND C.Company_Status='ACT'
  AND C.CompanyID = CI.CompanyID
  AND C.CompanyID = C1.CompanyID
  AND (CI.IndustryID IN (2,3) AND C.B2b = 'N')
Group By
  C.CompanyID,C.B2b
HAVING
 Count(C.CompanyID) = 2

After checking (CI.IndustryID IN (2,3) AND C.B2b = 'N') we will have rows:
C.CompanyIDC.B2bCI.IndustryID
77N2
77N3

Then group by C.CompanyID,C.B2b and Count(C.CompanyID)
C.CompanyIDC.B2bCount(C.CompanyID)
77  

Mysql C API problems

2002-06-29 Thread Hugo Veiga

hi there 

the present serves for some clearing some doubts i have: 

1 - if i wanna make an action based on the fact that a query i just made 
won't return results (empty set), how can i test that? 

will this do? 
if(!mysql_query(myData, query) 
{ 
   results = mysql_store_results(myData); 

   if(mysql_num_rows() == 0) 
   { 
   //action; 
   } 
} 

2 - if the the row is made of one single field wich in turn is an integer, 
how can i address to it's value? 

will this do? 
row = mysql_fetch_row( results ); 

if(row[0]!=NULL) 
{ 
tempo=_registo[0]-decimals; //?!??!?!? 
//other actions here
}//if 

thank u in advance, 
Compliments 




-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Hidden rows in table.

2002-06-29 Thread Jonas Olofsson

Hi.

I have just started to use MySQL and I have come up with a strange
problem.

I have a table with 28 rows. When I do 'SELECT * FROM table_name;' in
the MySQL client it only shows 12 of these rows. But if i specify one of
the rows that are not shown with the first command, like 'SELECT * FROM
table_name WHERE id='25';' this row is shown.

Any suggestions what might be wrong?

//
Jonas Olofsson 


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: Mysql C API problems

2002-06-29 Thread Dean Harding

 1 - if i wanna make an action based on the fact that a query i just
made 
 won't return results (empty set), how can i test that? 

 will this do? 
 if(!mysql_query(myData, query) 
 { 
results = mysql_store_results(myData); 

if(mysql_num_rows() == 0) 
{ 
//action; 
} 
 } 

That's right, except mysql_num_rows() takes a pointer to the results you
get from mysql_store_results(), so it looks like this:

if( mysql_num_rows( result ) == 0 )
{
// action
}

 2 - if the the row is made of one single field wich in turn is an
integer, 
 how can i address to it's value? 

Like this:

MYSQL_ROW row = mysql_fetch_row( result );
int value = atoi( row[0] );

Dean Harding


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: Mysql C API problems

2002-06-29 Thread Georg Richter

On Saturday, 29. June 2002 11:15, Hugo Veiga wrote:

Hello Hugo,

 will this do?
 if(!mysql_query(myData, query)
 {
results = mysql_store_results(myData);

-if(mysql_num_rows() == 0)
+if (!mysql_num_rows(results))
{
//action;
}
 }

with the above correction it should work :)

 will this do?
 row = mysql_fetch_row( results );

 if(row[0]!=NULL)
 {
 tempo=_registo[0]-decimals; //?!??!?!?
 //other actions here
 }//if


The values in row are always represented as strings, so you have to use atoi, 
atol, atof depends on the type, to convert it:

if ((row = mysql_fetch_row(results)) != NULL) {
  tempo = atoi(row[0]); 
}

Regards Georg

mysql, query

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: Hidden rows in table.

2002-06-29 Thread Mikhail Entaltsev

Jonas,

try to execute this command:

SELECT count(1) FROM table_name;

Result should be 28. Do you have 28?

Mikhail.

- Original Message -
From: Jonas Olofsson [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Saturday, June 29, 2002 11:20
Subject: Hidden rows in table.


 Hi.

 I have just started to use MySQL and I have come up with a strange
 problem.

 I have a table with 28 rows. When I do 'SELECT * FROM table_name;' in
 the MySQL client it only shows 12 of these rows. But if i specify one of
 the rows that are not shown with the first command, like 'SELECT * FROM
 table_name WHERE id='25';' this row is shown.

 Any suggestions what might be wrong?

 //
 Jonas Olofsson


 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)

 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail
[EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




function call ????

2002-06-29 Thread toby -



hi guyz

how do i call a phpfile into another phpfile 

like i wanna call cat_disply.php from within article.php
so dat it displays all the categories WHERE im giving it a call

now i did this in c/c++
i CALLED files as i call functions

but is this possible in php ?

thnx a million

toby .



sql,query

_
Send and receive Hotmail on your mobile device: http://mobile.msn.com


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




problems in './congigure' C++ API lirary for MySQL

2002-06-29 Thread Joonas Aalto

Hi!

Packet for 'C++ API  library for MySQL' is 'mysql++-1.7.9.tar.gz'.

At first I type 'automake' and it complain 'not found next files:
AUTHORS, NEWS, INSTALL, COPYING and ChangeLog'.

I can write next 'autoconf' as README said and it will go great. But
then if I type './configure', everything will going cool, but then
after:

checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for objdir... .libs
creating libtool
loading cache ./config.cache

..will come:

checking whether to enable maintainer-specific portions of
Makefiles...no
checking for MySQL library directory... configure: error: Didn't find
the mysql library dir in ''


Whole think stop to it! Why What I can do for fix it??

Please answer to my e-mail address: [EMAIL PROTECTED]


By: Joonas Aalto

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




saving modified image to blob

2002-06-29 Thread andy

Hi there,

I would like to save a jpg into a blob field of mysql. The function
underneath works fine if I read the image from the temporary destination
where php did put it after uploading.

My problem is, that I would like to do some funky stuff to the image like
changing colors or adding watermarks. So I have several functions ahead
before I used to store them successfully to the file system. Now I would
like to store it to a blob field, but this does not work. Like I said it
works to store the temp file, but not the other one. I guess it has to do
with something regarding the imagejpeg function.

Here is what I tryed:
  #
   # save image to db into blob

   // this does not work (outputImg is a the colorcorrected file)
 $data = addslashes($outputImg);

// this one would work
   # $data = addslashes(fread(fopen($picture_location, r),
filesize($picture_location)));

  $stmt =
   INSERT INTO test.picture_test
(file_name, file_type, picture)
VALUES
('$name', '$picture_location_type', '$data')
  ;
  execute_stmt($stmt, $link);
  #

Maybe some of you guy has a good idea on that.

Thanx for any help,

Andy

query



-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail mysql-unsubscribe-##L=##[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




error : make test

2002-06-29 Thread Richard Pijnenburg

Hello,

I've tried to install mysql 4.0.1 Alpha.
The configuration did not give me any error's
The make also worked just fine.
But when I run make test I get the following error:

ERROR: /down/new/mysql-4.0.1-alpha/mysql-test/var/run/master.pid was not
created in 30 seconds;  Aborting
make: *** [test] Error 1


My config line is:

./configure --prefix=/usr/local/mysql --enable-large-files
--without-debug --with-mysqld-user=mysql


I hope some one can help me.

Thanks in advanced.

Richard Pijnenburg
The Netherlands



-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




MySQL 4.1 with Stored Procedure release date?

2002-06-29 Thread Julian Htun

Does anybody knows estimated release date of MySQL ver 4.1 with Stored
Procedure?

Thanks,
-Julian


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: Hidden rows in table.

2002-06-29 Thread Jonas Olofsson

 Jonas,
 
 try to execute this command:
 
 SELECT count(1) FROM table_name;
 
 Result should be 28. Do you have 28?
 
 Mikhail.

Yes, it says:

--
SELECT count(1) FROM table_name;

+--+
| count(1) |
+--+
|   28   |
+--+
1 row in set (0.00 sec)
--
//
Jonas Olofsson

  Hi.
 
  I have just started to use MySQL and I have come up with a strange 
  problem.
 
  I have a table with 28 rows. When I do 'SELECT * FROM 
 table_name;' in 
  the MySQL client it only shows 12 of these rows. But if i 
 specify one 
  of the rows that are not shown with the first command, like 
 'SELECT * 
  FROM table_name WHERE id='25';' this row is shown.
 
  Any suggestions what might be wrong?
 
  //
  Jonas Olofsson
 
 
  
 -
  Before posting, please check:
 http://www.mysql.com/manual.php   (the manual)
 http://lists.mysql.com/   (the list archive)
 
  To request this thread, e-mail [EMAIL PROTECTED]
  To unsubscribe, e-mail
 [EMAIL PROTECTED]
  Trouble unsubscribing? Try: 
 http://lists.mysql.com/php/unsubscribe.php
 
 
 
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail 
 [EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
 
 


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: Hidden rows in table.

2002-06-29 Thread Jocelyn Fournier

Hi,

Perhaps the table is corrupted ? (the second query uses index if they is one
whereas the first doesn't).
REPAIR TABLE reports nothing wrong ?

Regards,
  Jocelyn
- Original Message -
From: Mikhail Entaltsev [EMAIL PROTECTED]
To: Jonas Olofsson [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Saturday, June 29, 2002 5:26 PM
Subject: Re: Hidden rows in table.


 Jonas,

 I think that the problem is not in MySQL server, but may be it is in MySQL
 client.
 Do you use standard (command line) MySQl client?

 Mikhail.

 - Original Message -
 From: Jonas Olofsson [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Saturday, June 29, 2002 16:39
 Subject: RE: Hidden rows in table.


   Jonas,
  
   try to execute this command:
  
   SELECT count(1) FROM table_name;
  
   Result should be 28. Do you have 28?
  
   Mikhail.
 
  Yes, it says:
 
  --
  SELECT count(1) FROM table_name;
 
  +--+
  | count(1) |
  +--+
  |   28   |
  +--+
  1 row in set (0.00 sec)
  --
  //
  Jonas Olofsson
 
Hi.
   
I have just started to use MySQL and I have come up with a strange
problem.
   
I have a table with 28 rows. When I do 'SELECT * FROM
   table_name;' in
the MySQL client it only shows 12 of these rows. But if i
   specify one
of the rows that are not shown with the first command, like
   'SELECT *
FROM table_name WHERE id='25';' this row is shown.
   
Any suggestions what might be wrong?
   
//
Jonas Olofsson
   
   
   
   -
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)
   
To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail
   [EMAIL PROTECTED]
Trouble unsubscribing? Try:
   http://lists.mysql.com/php/unsubscribe.php
   
  
  
  
   -
   Before posting, please check:
  http://www.mysql.com/manual.php   (the manual)
  http://lists.mysql.com/   (the list archive)
  
   To request this thread, e-mail [EMAIL PROTECTED]
   To unsubscribe, e-mail
   [EMAIL PROTECTED]
   Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
  
  
 
 
  -
  Before posting, please check:
 http://www.mysql.com/manual.php   (the manual)
 http://lists.mysql.com/   (the list archive)
 
  To request this thread, e-mail [EMAIL PROTECTED]
  To unsubscribe, e-mail
 [EMAIL PROTECTED]
  Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
 


 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)

 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail
[EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php






-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: problems in './congigure' C++ API lirary for MySQL

2002-06-29 Thread Mikhail Entaltsev

Joonas,

 checking for MySQL library directory... configure: error: Didn't find
 the mysql library dir in ''

I had the same problem couple days ago, and I fixed it manually (just edit
configure.in file).
In this file path to MySQl library directory is
/usr/local/mysql/lib/mysql, I changed it to /usr/local/mysql/lib.
But I had a lot of other problems during installation.
So in my case correct steps were:
1. Change directory to mysql++-1.7.9 root. In my case it was
/install/mysql++-1.7.9,
but it depends where did you untar file.
2. libtoolize -f
3. aclocal
4. Edit ./configure.in file.
4. automake
5. autoconfigure
5. ./configure
6. make
7. make install

Best regards,

Mikhail.


- Original Message -
From: Joonas Aalto [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Saturday, June 29, 2002 16:25
Subject: problems in './congigure' C++ API lirary for MySQL


 Hi!

 Packet for 'C++ API  library for MySQL' is 'mysql++-1.7.9.tar.gz'.

 At first I type 'automake' and it complain 'not found next files:
 AUTHORS, NEWS, INSTALL, COPYING and ChangeLog'.

 I can write next 'autoconf' as README said and it will go great. But
 then if I type './configure', everything will going cool, but then
 after:

 checking if libtool supports shared libraries... yes
 checking whether to build shared libraries... yes
 checking whether to build static libraries... yes
 checking for objdir... .libs
 creating libtool
 loading cache ./config.cache

 ..will come:

 checking whether to enable maintainer-specific portions of
 Makefiles...no
 checking for MySQL library directory... configure: error: Didn't find
 the mysql library dir in ''


 Whole think stop to it! Why What I can do for fix it??

 Please answer to my e-mail address: [EMAIL PROTECTED]


 By: Joonas Aalto

 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)

 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail
[EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: MySQL 4.1 with Stored Procedure release date?

2002-06-29 Thread Cal Evans

last I heard it was 'sometime before the end of the year.'

=C=

*
* Cal Evans
* Journeyman Programmer
* Techno-Mage
* http://www.calevans.com
*
 

-Original Message-
From: Julian Htun [mailto:[EMAIL PROTECTED]]
Sent: Saturday, June 29, 2002 9:34 AM
To: [EMAIL PROTECTED]
Subject: MySQL 4.1 with Stored Procedure release date?


Does anybody knows estimated release date of MySQL ver 4.1 with Stored
Procedure?

Thanks,
-Julian


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: function call ????

2002-06-29 Thread Cal Evans

wrong mailing list. (This is abuse, you want arguments...down the hall, to
your left.)

=C=

*
* Cal Evans
* Journeyman Programmer
* Techno-Mage
* http://www.calevans.com
*


-Original Message-
From: toby - [mailto:[EMAIL PROTECTED]]
Sent: Saturday, June 29, 2002 6:05 AM
To: [EMAIL PROTECTED]
Subject: function call 




hi guyz

how do i call a phpfile into another phpfile 

like i wanna call cat_disply.php from within article.php
so dat it displays all the categories WHERE im giving it a call

now i did this in c/c++
i CALLED files as i call functions

but is this possible in php ?

thnx a million

toby .



sql,query

_
Send and receive Hotmail on your mobile device: http://mobile.msn.com


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: how to create tables ....isam .... ????

2002-06-29 Thread Paul DuBois

At 6:11 + 6/29/02, toby - wrote:
thnx a million paul

got that  :)

So ... why do you want to do this?

well i get really irretated of seein row# 66 right after 5

So basically, it's just a psychological thing on your part, right?

but seriously i dont know the + or - points of the types
besides my project supervisor just declared v DONT NEED isam
since v dont NEED row 6 after 5  n  not 66
:S  :( 

Okay.  For some information related to the differences between ISAM
and MyISAM, read this section of the manual:

http://www.mysql.com/doc/M/y/MyISAM.html

Then believe your project supervisor. :-)

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




install

2002-06-29 Thread Page Works Web Solutions

Hi all,
   I'm a newbie at this, so here's a newbie question.  I have installed
MySql on a Cobalt Raq 4 running Linux via a .pkg file.  All seemed to go
well, I am able to get into the MySql directory via telnet but no commands
seem to work.  See session below.  Can anyone help me with putting a root
pass word on this?

[admin admin]$ mysql
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 10 to server version: 3.23.37

Type 'help;' or '\h' for help. Type '\c' to clear the buffer

mysql bin/mysqladmin -password testpassword;
ERROR 1064: You have an error in your SQL syntax near
'bin/mysqladmin -password
testpassword' at line 1
mysql bin/safe_mysqld ;
ERROR 1064: You have an error in your SQL syntax near 'bin/safe_mysqld ' at
lin
e 1
mysql bin/safe_mysqld  \g
ERROR 1064: You have an error in your SQL syntax near 'bin/safe_mysqld ' at
lin
e 1
mysql bin/safe_mysqld 
- ;
ERROR 1064: You have an error in your SQL syntax near 'bin/safe_mysqld ' at
lin
e 1
mysql bin/mysqladmin -p ping
- ;
ERROR 1064: You have an error in your SQL syntax near 'bin/mysqladmin -p
ping' a
t line 1

Thanks,
Shawn


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




re: External MySQL access from Windows

2002-06-29 Thread Dennis

Its not clear from the docs if external mySQL databases (say running on a 
linux system) can be linked to Windows database with myODBC. Does this work 
bi-directionally (ie can I retrieve info from the linux databases and 
update records on the linux box with queries from windows?

Thanks,

DB


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: install

2002-06-29 Thread Cal Evans

The commands you are typing are shell commands.  You are in the mysql
client.  Try:
use mysql;
select * from user;

You need to be at a shell prompy to issue bin/mysqladmin -password
testpassword

HTH,
=C=

*
* Cal Evans
* Journeyman Programmer
* Techno-Mage
* http://www.calevans.com
*


-Original Message-
From: Page Works Web Solutions [mailto:[EMAIL PROTECTED]]
Sent: Saturday, June 29, 2002 12:07 PM
To: [EMAIL PROTECTED]
Subject: install


Hi all,
   I'm a newbie at this, so here's a newbie question.  I have installed
MySql on a Cobalt Raq 4 running Linux via a .pkg file.  All seemed to go
well, I am able to get into the MySql directory via telnet but no commands
seem to work.  See session below.  Can anyone help me with putting a root
pass word on this?

[admin admin]$ mysql
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 10 to server version: 3.23.37

Type 'help;' or '\h' for help. Type '\c' to clear the buffer

mysql bin/mysqladmin -password testpassword;
ERROR 1064: You have an error in your SQL syntax near
'bin/mysqladmin -password
testpassword' at line 1
mysql bin/safe_mysqld ;
ERROR 1064: You have an error in your SQL syntax near 'bin/safe_mysqld ' at
lin
e 1
mysql bin/safe_mysqld  \g
ERROR 1064: You have an error in your SQL syntax near 'bin/safe_mysqld ' at
lin
e 1
mysql bin/safe_mysqld 
- ;
ERROR 1064: You have an error in your SQL syntax near 'bin/safe_mysqld ' at
lin
e 1
mysql bin/mysqladmin -p ping
- ;
ERROR 1064: You have an error in your SQL syntax near 'bin/mysqladmin -p
ping' a
t line 1

Thanks,
Shawn


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: External MySQL access from Windows

2002-06-29 Thread Cal Evans

yes.  Using myODBC you can connect with any ODBC client and issue any valid
sql statement. (Personally, I use VFP but it's dumber brother Access will
work also.)

=C=

*
* Cal Evans
* Journeyman Programmer
* Techno-Mage
* http://www.calevans.com
*


-Original Message-
From: Dennis [mailto:[EMAIL PROTECTED]]
Sent: Saturday, June 29, 2002 12:17 PM
To: [EMAIL PROTECTED]
Subject: re: External MySQL access from Windows


Its not clear from the docs if external mySQL databases (say running on a
linux system) can be linked to Windows database with myODBC. Does this work
bi-directionally (ie can I retrieve info from the linux databases and
update records on the linux box with queries from windows?

Thanks,

DB


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php



-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: Hidden rows in table.

2002-06-29 Thread Jonas Olofsson

 Hi,
 
 Perhaps the table is corrupted ? (the second query uses index 
 if they is one whereas the first doesn't). REPAIR TABLE 
 reports nothing wrong ?
 
 Regards,
   Jocelyn

Just use that, and now it seems to work...

Thanks everyone...

//
Jonas



-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: MySQL 4.1 with Stored Procedure release date?

2002-06-29 Thread Gerald R. Jensen

Julian:

In my experience, MySQL doesn't project release dates. The surest way to
avoid pulling a Microsoft (miss release dates) is not to project release
dates in the first place.

As I understand it, they are working through the to-do list
(http://www.mysql.com/doc/T/O/TODO_MySQL_4.0.html) in 4.0.x, then will begin
work on 4.1.x.

Could be awhile ... but then again, it will likely be worth the wait.

Gerald Jensen


- Original Message -
From: Julian Htun [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Saturday, June 29, 2002 9:34 AM
Subject: MySQL 4.1 with Stored Procedure release date?


Does anybody knows estimated release date of MySQL ver 4.1 with Stored
Procedure?

Thanks,
-Julian


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail
[EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php





-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: Broken build of 3.23.51?

2002-06-29 Thread Steven Roussey

 From: Michael Bacarella [mailto:[EMAIL PROTECTED]]
 Not the case for me.  I tried the prebuilt binary and then my own
 built binary within 30 minutes of each other (the time of day when
 we had the lowest loads) and there was a clear difference.
 Unusable (40 loadav) vs. humming along smoothly (0.5 loadav).

I saw my load go over 340 (which I did not think was possible) where it
usually is  5. I'm not using the max version as you are so that is not
part of it. 

The only thing I can think of is glibc stuff that MySQL does special for
their releases.

Also, are you using Linux or something else?

Sincerely,
Steven Roussey
http://Network54.com/?pp=e





-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




InnoDB RAW devices under Solaris?

2002-06-29 Thread Lou Picciano / Essex Systems

RE: MySQL 4.01-max, InnoDB, Solaris, Raw device support

Has anyone had any specific experience implementing an InnoDB tablespace
under Sparc Solaris?

A specific few lines in my.cnf would be very helpful...

As we are using a SparcStorage Array, our device pathnames look something
like:

Innodb_data_file_path=/dev/rdsk/c1t4d0s7:1Gnewraw   (OR)
Innodb_data_file_path=/dev/dsk/c1t4d0s7:1Gnewraw

Either of these options gives us an operating system error number 2 ...

Are there specific Solaris slices we should be using??  Can't find any docs
on this.

Please note: using 'standard' InnoDB filespaces, everyting works AOK...

Any help is appreciated.

Lou


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: InnoDB RAW devices under Solaris?

2002-06-29 Thread Paul DuBois

At 15:01 -0400 6/29/02, Lou Picciano / Essex Systems wrote:
RE: MySQL 4.01-max, InnoDB, Solaris, Raw device support

Has anyone had any specific experience implementing an InnoDB tablespace
under Sparc Solaris?

A specific few lines in my.cnf would be very helpful...

As we are using a SparcStorage Array, our device pathnames look something
like:

Innodb_data_file_path=/dev/rdsk/c1t4d0s7:1Gnewraw   (OR)
Innodb_data_file_path=/dev/dsk/c1t4d0s7:1Gnewraw

Either of these options gives us an operating system error number 2 ...

Are there specific Solaris slices we should be using??  Can't find any docs
on this.

Please note: using 'standard' InnoDB filespaces, everyting works AOK...

Any help is appreciated.

innodb_data_file_path is interpreted relative to (i.e., is textually
concatentated to) innodb_data_home_dir.  You might want to set the
latter to / and remove / from the _path values.


Lou


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: Load problems with 3.23.51

2002-06-29 Thread Michael Widenius


Hi!

 Steven == Steven Roussey [EMAIL PROTECTED] writes:

Steven I tried the skip-name-resolve and it had no effect. So there goes my
Steven hypothesis. 

Steven Here are the results from test:

Steven Benchmark DBD suite: 2.14
Steven Date of test:2002-06-24 11:19:19
Steven Running tests on:Linux 2.4.16-0.13smp i686
Steven Arguments:
Steven Comments:
Steven Limits from:
Steven Server version:  MySQL 3.23.51 log

cut

Steven TOTALS  2098.00  436.22  126.65  562.87

The above looks quite ok.

On a Intel Xeon 2M cache, 4x700 Mhz, 2G, key_buffer=16M, gcc 3.1
machine I get:

TOTALS  3399.00  664.19  179.00  843.19

(This is a newer benchmark version with some new tests, but still
comparable)

So at least there is nothing strange with the basic MySQL queries on
the machine.

Now there are two different possible problems:

- A problem with the thread library that causes a problem when using
  many threads.
- Some query / specific feature that you use that is slower like
  before. (For example a query that doesn't use indexes anymore).

Could you by any change check by using the slow query log if there is
some specific query that is causing problems ?

Another option is to run the 3.23.51 server for a while and when you
get a load problem do 'mysqladmin proc ext'.  This command should show
us if MySQL is using more table scans than usual.

Regards,
Monty

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: Bug#151302: mysql-server: transparent gzip support on selected columns

2002-06-29 Thread Christian Hammers

Hello MySQL developers

I forward this in behalf of a Debian user who filed a bug report against
the Debian package.

bye,

-christian-

On Fri, Jun 28, 2002 at 07:21:26PM +, [EMAIL PROTECTED] wrote:
 Package: mysql-server
 Version: 3.23.50-1
 Severity: wishlist
 
 
 Currently I have about 4 records in a table that use to consume 800mb of space. 
(about 23kb per row).  Now I'm compressing the column that stores the text as a blob 
with gzip compression.  Now that table only uses 64mb of space. (about 1600 bytes per 
row)
 
 I'd like the compression on selected columns/tables/databases to be gzip compressed. 
 It's benifical to my table structure in my case because the blob column stores an 
XML document, and has good compression.  I never need to select the documents by 
search paramaters on the column, so the only runtime difference would be 
compressing(insert/updates) and decompressing(selects) that column on the fly.
 
 Thanks.
 
 -- System Information
 Debian Release: 3.0
 Kernel Version: Linux pcbkits.com 2.2.20 #1 Wed Mar 20 20:01:51 EST 2002 i686 unknown
 
 Versions of the packages mysql-server depends on:
 ii  adduser3.47   Add and remove users and groups
 ii  debconf1.1.11 Debian configuration management system
 ii  libc6  2.2.5-6GNU C Library: Shared libraries and Timezone
 ii  libdbi-perl1.28-1 The Perl5 Database Interface by Tim Bunce
 ii  libmysqlclient 3.23.50-1  mysql database client library
 ii  libstdc++2.10- 2.95.4-9   The GNU stdc++ library
 ii  libwrap0   7.6-9  Wietse Venema's TCP wrappers library
 ii  mysql-client   3.23.50-1  mysql database client binaries
 ii  perl   5.6.1-7Larry Wall's Practical Extraction and Report
 ii  psmisc 21-3   Utilities that use the proc filesystem
 ii  zlib1g 1.1.4-1compression library - runtime

ROBOT: php mysql


-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: Load problems with 3.23.51

2002-06-29 Thread Steven Roussey

 Another option is to run the 3.23.51 server for a while and when you
 get a load problem do 'mysqladmin proc ext'.  This command should show
 us if MySQL is using more table scans than usual.

The load problem shows up immediately.

+--++
| Variable_name| Value  |
+--++
| Aborted_clients  | 172|
| Aborted_connects | 87 |
| Bytes_received   | 92732  |
| Bytes_sent   | 631789 |
| Com_admin_commands   | 0  |
| Com_alter_table  | 0  |
| Com_analyze  | 0  |
| Com_backup_table | 0  |
| Com_begin| 0  |
| Com_change_db| 990|
| Com_change_master| 0  |
| Com_check| 0  |
| Com_commit   | 0  |
| Com_create_db| 0  |
| Com_create_function  | 0  |
| Com_create_index | 0  |
| Com_create_table | 1  |
| Com_delete   | 8  |
| Com_drop_db  | 0  |
| Com_drop_function| 0  |
| Com_drop_index   | 0  |
| Com_drop_table   | 0  |
| Com_flush| 0  |
| Com_grant| 0  |
| Com_insert   | 49 |
| Com_insert_select| 0  |
| Com_kill | 0  |
| Com_load | 0  |
| Com_load_master_table| 0  |
| Com_lock_tables  | 0  |
| Com_optimize | 0  |
| Com_purge| 0  |
| Com_rename_table | 0  |
| Com_repair   | 0  |
| Com_replace  | 11 |
| Com_replace_select   | 0  |
| Com_reset| 0  |
| Com_restore_table| 0  |
| Com_revoke   | 0  |
| Com_rollback | 0  |
| Com_select   | 402|
| Com_set_option   | 0  |
| Com_show_binlogs | 0  |
| Com_show_create  | 0  |
| Com_show_databases   | 0  |
| Com_show_fields  | 0  |
| Com_show_grants  | 0  |
| Com_show_keys| 0  |
| Com_show_logs| 0  |
| Com_show_master_status   | 0  |
| Com_show_open_tables | 0  |
| Com_show_processlist | 2  |
| Com_show_slave_status| 0  |
| Com_show_status  | 46 |
| Com_show_tables  | 0  |
| Com_show_variables   | 0  |
| Com_slave_start  | 0  |
| Com_slave_stop   | 0  |
| Com_truncate | 0  |
| Com_unlock_tables| 0  |
| Com_update   | 183|
| Connections  | 316|
| Created_tmp_disk_tables  | 1  |
| Created_tmp_tables   | 5  |
| Created_tmp_files| 0  |
| Delayed_insert_threads   | 0  |
| Delayed_writes   | 0  |
| Delayed_errors   | 0  |
| Flush_commands   | 1  |
| Handler_delete   | 430|
| Handler_read_first   | 5  |
| Handler_read_key | 564|
| Handler_read_next| 5441   |
| Handler_read_prev| 0  |
| Handler_read_rnd | 62 |
| Handler_read_rnd_next| 3406   |
| Handler_update   | 172|
| Handler_write| 123|
| Key_blocks_used  | 773|
| Key_read_requests| 5199   |
| Key_reads| 770|
| Key_write_requests   | 1067   |
| Key_writes   | 133|
| Max_used_connections | 121|
| Not_flushed_key_blocks   | 0  |
| Not_flushed_delayed_rows | 0  |
| Open_tables  | 147|
| Open_files   | 193|
| Open_streams | 0  |
| Opened_tables| 155|
| Questions| 1662   |
| Select_full_join | 0  |
| Select_full_range_join   | 0  |
| Select_range | 16 |
| Select_range_check   | 0  |
| Select_scan  | 75 |
| Slave_running| OFF|
| Slave_open_temp_tables   | 0  |
| Slow_launch_threads  | 29 |
| Slow_queries | 54 |
| Sort_merge_passes| 0  |
| Sort_range   | 19 |
| Sort_rows| 52 |
| Sort_scan| 5  |
| Table_locks_immediate| 499|
| Table_locks_waited   | 188|
| Threads_cached   | 64 |
| Threads_created  | 122|
| Threads_connected| 58 |
| Threads_running  | 11 |
| Uptime   | 81 |
+--++

  8:15pm  up 1 day, 23:48,  1 user,  load average: 49.13, 15.49, 3.84

+-+--++-++--
+--+--+
| Id  | User | Host   | db  | Command| Time
| State| Info
|
+-+--++-++--
+--+--+
| 7   | webuser 

Re: saving modified image to blob

2002-06-29 Thread Georg Richter

On Saturday, 29. June 2002 15:10, andy wrote:
Hi Andy,

What shows mysql_errno after mysql_query?!
Why you don't use mysql_real_escape_string (or mysql_escape_string for PHP 
Version  4.1.1) instead of addslashes?!

Regards

Georg

-
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/   (the list archive)

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail [EMAIL PROTECTED]
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php