Re: Having a big problem in libmysqlclient.a with apache and php

2001-04-12 Thread David Beech


On 11 Apr 2001, at 18:07, Mohamed Ould wrote:
  apache "make" abort with these errors:
  usr/local/mysql/lib/libmysqlclient.a(my_compress.o
  ): In function `my_uncompress':
  my_compress.o(.text+0x9a): undefined reference to
  `uncompress'
  /usr/local/mysql/lib/libmysqlclient.a(my_compress.
  o): In function `my_compress_alloc':
  my_compress.o(.text+0x12a): undefined reference to
  `compress' collect2: ld returned 1 exit status
  make[2]: *** [target_static] Erreur 1 make[2]:

Look at what "make" is telling you Mohamed. During the 
linking stage of the make process the linker (ld) cannot
find references to either uncompress or compress. This 
means that gcc, which calls the linker, cannot find zlib.
This can be due to either:

- Missing library, or
- Misconfigured library search path (unlikely)

Normally zlib lives in /usr/lib. Check to see if you have a 
number of files like:

libz.a  libz.so  libz.so.1  libz.so.1.1.3  libzvt.a  libzvt.so  
libzvt.so.2  libzvt.so.2.2.3

(ls /usr/lib/libz*)

If not, find them and stick them there. Check also that
/etc/ld.so.conf contains /usr/lib as a library search path.

You can also run
ldconfig -p | less
to see what search paths are configured.

Sometimes RPM doesn't work too well.

David

-
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: I Need your help

2001-04-12 Thread David Beech

On 11 Apr 2001, at 11:16, [EMAIL PROTECTED] wrote:

 Good morning,
 Please,
 I use MySql, I would use INTERSECT/UNION functions and they
 don't work, I need help,
 
 My query is :
 
 select E.*, ME.Emplacement, E.Url,E.EMail, C.Name From
 Entreprise E, Mot_Entreprise ME, Mot M, Categorie C where
 (E.ID=ME.ID) and (ME.CodeMot=M.CodeMot) and (M.Mot like
 'word1%') and C.CategoryCode=E.SubCategoryCode order by
 ME.Emplacement
 
 INTERSECT
 
 select E.*, ME.Emplacement, E.Url,E.EMail, C.Name From
 Entreprise E, Mot_Entreprise ME, Mot M, Categorie C where
 (E.ID=ME.ID) and (ME.CodeMot=M.CodeMot) and (M.Mot like
 'word2%') and C.CategoryCode=E.SubCategoryCode order by
 ME.Emplacement
 
 
 Thank you.

Is this an late April Fool's prank? Why not use OR with 
the (M.Mot like 'wordX%') phrases? AFAIK there is no 
INTERSECT verb in MySQL. Is there?

David


-
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 and PHP issue

2001-04-12 Thread David Beech

On 11 Apr 2001, at 18:59, David wrote:

 I tried posting this in the PHP newsgroup but received no
 response so thought I would try here since issue involves
 MySQL
 

The easiest solution is to use lists, eg:

ul
 liAdmin/li
 ul
  liNetworking/li
  ul
   liping
   litraceroute
   liecho
  /ul
 /ul
/ul

rather than table data cells and amend your code to o/p 
the list tags, eg.

UL
LI?  echo "$submenu"; ?/LI
UL
LI
a href="? echo "$url"; ? " ? echo "$element";? 
/a /LI

etc

David

-
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: Incredibly Stuck on Errcode 2 File not found in mysqlimport

2001-04-12 Thread David Beech

On 12 Apr 2001, at 17:53, Lucy wrote:

 Hi
 I'm incredibly stuck.  I've been through the lists over and over, and manual is
 silent on this detail, and have found no solution.  The Unix remote host fails
 to find the text file to import from my pc, Win2000.  The TABLE is created
 already.  The text file is fine.  I've done this via "load data infile" on
 localserver on my pc in MySQL no problem.
 
if you mysqlimport or mysql (client) on the win2k box then:
 
run program on win2k (ie mysqlimport or mysql client)
connect to the remote unix host, eg
c:\mysql\binmysql -u fred -p -h unix.somewhere.com DATABASE
enter password:
etc

mysqlload data local infile "d:/units.txt" replace into table units; etc

ie Run the client from where the data is but connect to the remote. I don't
think LOAD is supposed to work the way you are trying to use it.

The alternative is to ftp the data from win2k to UNIX then run mysqlimport
on the UNIX side.

David




 This is syntax I've tried:
 command prompt $mysqlimport -u  -p -h x --local DBNAME [problem
 part not finding try1.txt]
 "Errcode: 2 file try1.txt not found for table try1"
 
 Where do I place the text file on my pc for remote host to find it?
 How do I tell it where to go?
 The try1.txt is sitting on my pc, in d drive.
 Please can anyone help, and make my Easter?  Cheers, Lucy
 
 



-
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: Select

2001-04-12 Thread David Beech

On 12 Apr 2001, at 13:54, Jim Zarvis wrote:

 What is good clean sql syntax to accomplish the following with MySQL:
 SELECT * FROM tablename WHERE value is in array of values
 
 i.e. (psudocode)
 
 Assume I have a field called ID in my table, and that I have 20 Rows (with
 ID's 1-20)
 
 myarray = (1,3,4)
 
 I want to return all the fields where ID = 1 and 3 and 4
 
 I should get three rows back.
 
 
 JZ
 
 

Perhaps:

SELECT * FROM tablename WHERE value = LOWEND and value = 
HIGHEND

-
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: connecting to mysql using php

2001-04-12 Thread David Beech

On 12 Apr 2001, at 16:03, josh kneedler wrote:

 i'm trying to connect to mysql using php so that i can do web based 
 queries of my tables. i'm new at this so here are some questions:
 1. is localhost just the ip of my server or is it also the path to 
 where mysql is on my server?

Just the hostname or IP. MySQL runs wth port 3306 by default so
when you do  @mysql_connect("localhost", "root", "mypasswd");
you will be automagically connected to the MySQL server. You then
need to determine which database to use, eg:

mysql_select_db($DBNAME, $db);

$DBNAME is the database, $db the connection you opened.

 2. if root is the login name should it be my login or just stay as root?

Which login do you mean? The *NIX login or your MySQL user name?
You should set up a user in MySQL user table with the appropriate
privileges and log in as that user.

 3. is mypasswd the same password i enter when i'm in the mysql 
 evironment in reference to (mysql -u root -p)?
 

Yes, see 2 above also.

David
 once i can declare the dbcnx variable i'll be able to do queries with php.
 josh
 
   // Connect to the database server
$dbcnx = @mysql_connect("localhost",
 "root", "mypasswd");
if (!$dbcnx) {
  echo( "PUnable to connect to the " .
"database server at this time./P" );
  exit();
}
 
 -- 
 dreaming america : visual media studio
 503.222.2242 : http://dreamingamerica.com
 ...:::. http://rangermag.com :::...:::.:.v.1.i.2...::
 



-
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