Re: Loading database information from a text file.

2003-06-08 Thread JeRRy
Thanks, worked nicely.

 --- Paul DuBois [EMAIL PROTECTED] wrote:  At 14:52
+1000 6/8/03, JeRRy wrote:
 Hi,
 
 I have a text file with all my database information
 to
 create databases to setting up tables.  I have
 looked
 throught the mysql docs onto how to load these on
 from
 the mysql prompt.  But all I can find is:
 
 load data infile filename.txt into table whatever
 
 But this is not what I am looking for. :(  As the
 tables are already defined in the text file and the
 appropiate database name to enter them into.
 
 Is there a way to load these into the database
 directly instead of doing each table seperately
 from
 the mysql prompt? (not web admin)
 
 Thanks in advance.
 
 Kind Regards,
 Jerry
 
 Do you mean that the text file contains SQL
 statements?
 If so, you can execute them like this:
 
 mysql  filename
 
 or maybe (if you don't select the database within
 the file):
 
 mysql dbname  filename
 
 -- 
 Paul DuBois, Senior Technical Writer
 Madison, Wisconsin, USA
 MySQL AB, www.mysql.com
 
 Are you MySQL certified? 
 http://www.mysql.com/certification/
  

http://mobile.yahoo.com.au - Yahoo! Mobile
- Check  compose your email via SMS on your Telstra or Vodafone mobile.

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Loading database information from a text file.

2003-06-08 Thread JeRRy
Okay thanks.

One last thing.

From the mysql prompt how can I generate a database
backup?  (So I can see the database setup in notepad
so I can backup and transfer easily online.)

Jerry

 --- Paul DuBois [EMAIL PROTECTED] wrote:  At 14:52
+1000 6/8/03, JeRRy wrote:
 Hi,
 
 I have a text file with all my database information
 to
 create databases to setting up tables.  I have
 looked
 throught the mysql docs onto how to load these on
 from
 the mysql prompt.  But all I can find is:
 
 load data infile filename.txt into table whatever
 
 But this is not what I am looking for. :(  As the
 tables are already defined in the text file and the
 appropiate database name to enter them into.
 
 Is there a way to load these into the database
 directly instead of doing each table seperately
 from
 the mysql prompt? (not web admin)
 
 Thanks in advance.
 
 Kind Regards,
 Jerry
 
 Do you mean that the text file contains SQL
 statements?
 If so, you can execute them like this:
 
 mysql  filename
 
 or maybe (if you don't select the database within
 the file):
 
 mysql dbname  filename
 
 -- 
 Paul DuBois, Senior Technical Writer
 Madison, Wisconsin, USA
 MySQL AB, www.mysql.com
 
 Are you MySQL certified? 
 http://www.mysql.com/certification/
  

http://mobile.yahoo.com.au - Yahoo! Mobile
- Check  compose your email via SMS on your Telstra or Vodafone mobile.

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Maximum statements per connection problem

2003-06-08 Thread Heikki Tuuri
John,

- Original Message - 
From: John A. Sullivan III [EMAIL PROTECTED]
Newsgroups: mailing.database.mysql
Sent: Sunday, June 08, 2003 7:58 AM
Subject: Maximum statements per connection problem


 I am having a nightmare of a time getting a single transaction across
 multiple tables to work in Borland's Kylix3 with MySQL.  It appears that
 the Borland driver is saying that the MySQL database only supports a
 single active statement per connection.
 When I issue an explicit begin transaction, that appears to count as an
 active statement.  When I then try to issue the update (or insert or
 delete) statement, that appears to be the second active command for the
 existing connection.  Since the Borland driver says the MySQL database
 is only allowing a single active command per connection, it clones a new
 connection to handle the update statement.  Of course, this new
 connection knows nothing of the transaction that was begun by the
 original connection.  This renders transaction support impossible with
 Borland's dbExpress and MySQL (even with InnoDB tables).
 Is there a way to configure MySQL to report that it will allow multiple
 active statements per connection? Otherwise, I'm not sure what to do if
 I want to use transactions (a must for my current project).  Thanks.

people have been complaining about this on Borland mailing lists for at
least a year now. I saw a Borland employee reply there a couple a weeks ago
that the MySQL transaction support is coming to dbExpress. Since Borland is
marketing their own database Interbase, they have somewhat conflicting
interests here.

I believe feedback to Borland or their newsgroups can speed things up.

 -- 
 John A. Sullivan III

Best regards,

Heikki Tuuri
Innobase Oy
http://www.innodb.com
Transactions, foreign keys, and a hot backup tool for MySQL
Order MySQL technical support from https://order.mysql.com/

 Chief Technology Officer
 Nexus Management
 +1 207-985-7880
 [EMAIL PROTECTED]
 ---
 If you are interested in helping to develop a GPL enterprise class
 VPN/Firewall/Security device management console, please visit
 http://iscs.sourceforge.net



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Can't insert data from Apache/PHP

2003-06-08 Thread Becoming Digital
So the next step would be to provide us with the code so that we might try to
help you. :)

Edward Dudlik
Becoming Digital
www.becomingdigital.com


- Original Message -
From: ComCity [EMAIL PROTECTED]
To: Becoming Digital [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Sunday, 08 June, 2003 01:55
Subject: Re: Can't insert data from Apache/PHP


Yep...figured that out.

Thank You

- Original Message -
From: Becoming Digital [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Saturday, June 07, 2003 6:48 PM
Subject: Re: Can't insert data from Apache/PHP


 That points to a fault in your coding because phpMyAdmin *is* PHP running
via
 the web server.

 Edward Dudlik
 Becoming Digital
 www.becomingdigital.com


 - Original Message -
 From: ComCity [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Saturday, 07 June, 2003 21:09
 Subject: More: Can't insert data from Apache/PHP


 It looks like I can insert data through phpMyadmin without issue.  The
only
 place I can't insert data is through PHP running via the web server.

 To: [EMAIL PROTECTED]
 Sent: Saturday, June 07, 2003 5:03 PM
 Subject: Can't insert data from Apache/PHP


  I've had to reinstall Linux/Apache and mySQL.  The databases are
restored,
  the data looks to be there, the permissions look to be there.  However,
I
  can't seem INSERT data into the tablesits the only thing I can't
  do...and I don't see a problem with the permissions.  Don't get any
errors
  on the webpage but nothing happens.  If I do a select, it works just
fine.
  I have the database permissions set wide open for troubleshooting.
 
 
  RWL
  owner X XX
  group X XX
  other  X XX
 
  Owner= mysql
  group= mysql
 
  What am I missing?  Its got to be something stupid and something
small
 
  Thank You very much.
  Michael B.
 


 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]





 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]





-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Loading database information from a text file.

2003-06-08 Thread JeRRy
Hi,

I downloaded the Windows version of mysql.  And just
set it up but currently it works as root and no
password.  Not a real concern as I shut down the mysql
as I finish working as I use it offline.  But I would
like to setup the user account and password as I have
it on my web server so it's easier to update instead
of changing things.

So if I wanted to create another user other than root
how can I do this?

Thanks!

 --- Paul DuBois [EMAIL PROTECTED] wrote:  At 14:52
+1000 6/8/03, JeRRy wrote:
 Hi,
 
 I have a text file with all my database information
 to
 create databases to setting up tables.  I have
 looked
 throught the mysql docs onto how to load these on
 from
 the mysql prompt.  But all I can find is:
 
 load data infile filename.txt into table whatever
 
 But this is not what I am looking for. :(  As the
 tables are already defined in the text file and the
 appropiate database name to enter them into.
 
 Is there a way to load these into the database
 directly instead of doing each table seperately
 from
 the mysql prompt? (not web admin)
 
 Thanks in advance.
 
 Kind Regards,
 Jerry
 
 Do you mean that the text file contains SQL
 statements?
 If so, you can execute them like this:
 
 mysql  filename
 
 or maybe (if you don't select the database within
 the file):
 
 mysql dbname  filename
 
 -- 
 Paul DuBois, Senior Technical Writer
 Madison, Wisconsin, USA
 MySQL AB, www.mysql.com
 
 Are you MySQL certified? 
 http://www.mysql.com/certification/
  

http://mobile.yahoo.com.au - Yahoo! Mobile
- Check  compose your email via SMS on your Telstra or Vodafone mobile.

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: start innodb without transactions

2003-06-08 Thread Carlos Proal
Hi Heikki et al.
I have solve my problem :). The fact about my missed table was my fault, 
because indeed those tables doesnt exist anymore (one developer had deleted 
them).
Even when my db is up and running im figuring out why there is not an option 
to skip commit/rollback pending transactions ?, this way i would have a 
quitely weekend, heheehe, no problem thanx a lot for your help.

Carlos

Original Message Follows
From: Carlos Proal [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: Re: start innodb without transactions
Date: Thu, 05 Jun 2003 23:40:16 -0500
Probably i need to describe the whole story:
I did a huge insert, a file about 100Mb, and mysql crashed/restarted, the 
err file showed:
--
030605 12:11:59  mysqld restarted
030605 12:12:00  InnoDB: Database was not shut down normally.
InnoDB: Starting recovery from log files...
InnoDB: Starting log scan based on checkpoint at
InnoDB: log sequence number 13 1000286684
InnoDB: Doing recovery: scanned up to log sequence number 13 1000286208
InnoDB: Last MySQL binlog file position 0 756499, file name 
./catarina-bin.057
030605 12:12:01  InnoDB: Flushing modified pages from the buffer pool...
030605 12:12:01  InnoDB: Started
/centia01/final/database/mysql/libexec/mysqld: ready for connections
030605 12:14:01  InnoDB: Out of memory in additional memory pool.
InnoDB: InnoDB will start allocating memory from the OS.
InnoDB: You may get better performance if you configure a bigger
InnoDB: value in the MySQL my.cnf file for
InnoDB: innodb_additional_mem_pool_size.
mysqld got signal 10;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
We will try our best to scrape up some info that will hopefully help 
diagnose
the problem, but since we have already crashed, something is definitely 
wrong
and this may fail.

key_buffer_size=67104768
read_buffer_size=131072
sort_buffer_size=524280
max_used_connections=4
max_connections=500
threads_connected=4
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_connections = 
385528
K
bytes of memory
Hope that's ok; if not, decrease some variables in the equation.
--

(i have 256Mb in buffer pool) But the next restart stopped mysql showing:
--
030605 12:14:30  mysqld restarted
030605 12:14:32  InnoDB: Database was not shut down normally.
InnoDB: Starting recovery from log files...
InnoDB: Starting log scan based on checkpoint at
InnoDB: log sequence number 13 1002344016
InnoDB: Doing recovery: scanned up to log sequence number 13 1002343936
InnoDB: 1 transaction(s) which must be rolled back or cleaned up
InnoDB: Trx id counter is 0 119167744
InnoDB: Starting rollback of uncommitted transactions
InnoDB: Rolling back trx with id 0 119167355
030605 12:14:32  InnoDB: Assertion failure in thread 1 in file btr0cur.c 
line 3350
InnoDB: We intentionally generate a memory trap.
InnoDB: Send a detailed bug report to [EMAIL PROTECTED]
mysqld got signal 11;
--

i started with force_recovery and indeed i can recover with mysqldump some 
databases but i was confused because my first try was with a db that 
apparently i cant recover, even inside mysql i get the following:
-
mysql desc facturas;
ERROR 1016: Can't open file: 'facturas.InnoDB'. (errno: 1)
mysql show table status;
+--+--++--++-+-+--+---++-+-++++
| Name | Type | Row_format | Rows | Avg_row_length | Data_length | 
Max_data_length | Index_length | Data_free | Auto_increment | Create_time | 
Update_time | Check_time | Create_options | Comment  
  |
+--+--++--++-+-+--+---++-+-++++
| facturas | NULL | NULL   | NULL |   NULL |NULL |   
 NULL | NULL |  NULL |   NULL | NULL| 
NULL| NULL   | NULL   | Can't open file: 
'facturas.InnoDB'. (errno: 1) |
| presupuestos | NULL | NULL   | NULL |   NULL |NULL |   
 NULL | NULL |  NULL |   NULL | NULL| 
NULL| NULL   | NULL   | Can't open file: 
'presupuestos.InnoDB'. (errno: 1) |
| proveedores  | NULL | NULL  

mysql: bug in update (?)

2003-06-08 Thread Dmitry Kosoy

Hi,

I have a table with 2 fields (among others) with type timestamp (warndate
and date).
I run the following update: update dbowner where warndate = now().
This update affects not only on the field warndate but on the field date
as well.
After it the both fields got the current date and time value.
I changed the name of field date to another and got the same result.

I got the same behavior in many mysql versions include 4.0.12.

Regards,
  Dmitry

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Replication over SSL

2003-06-08 Thread Gareth Davis
I guess that explains alot. Is there any work around with say,
stunnel/ssh etc?

Gareth
On Wed, 2003-06-04 at 23:38, Jim Winstead wrote:
 Hi Gareth.
 
 On Tue, Jun 03, 2003 at 09:59:52AM +0100, Gareth Davis wrote:
  I guess this is right place for this. I'm trying to setup replication
  between two hosts over the Internet.
  
  My problem is that i can't seem to solve an authentication problem
  between the slave and the master. Before I tried this I setup a test
  between two computers here in the office and managed to get it to work.
 
 Replication over SSL connections is not currently supported.
 
 The current plan is that it will be supported in 4.1.
 
 Jim Winstead
 MySQL AB
-- 
Gareth Davis [EMAIL PROTECTED]
Logical Practice Systems Limited


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: start innodb without transactions

2003-06-08 Thread Heikki Tuuri
Carlos,

- Original Message - 
From: Carlos Proal [EMAIL PROTECTED]
Newsgroups: mailing.database.mysql
Sent: Sunday, June 08, 2003 2:14 PM
Subject: Re: start innodb without transactions


 Hi Heikki et al.
 I have solve my problem :). The fact about my missed table was my fault,
 because indeed those tables doesnt exist anymore (one developer had
deleted
 them).

ok, good :). There are no clear corruption reports from Solaris for almost 2
years now.

 Even when my db is up and running im figuring out why there is not an
option
 to skip commit/rollback pending transactions ?, this way i would have a
 quitely weekend, heheehe, no problem thanx a lot for your help.

You definitely had some problem with log files because InnoDB was not able
to scan them at all. Make sure

innodb_log_files_in_group * innodb_log_file_size  2G

If you upgrade to 4.0.13, then the limit is 4G.

To get the database to a consistent state, pending transactions have to be
rolled back in crash recovery. If that is not possible because of
corruption, you have to set innodb_force_recovery to:

3 (SRV_FORCE_NO_TRX_UNDO) do not run transaction rollbacks after recovery;

and dump your tables and recreate the whole tablespace.

 Carlos

Best regards,

Heikki Tuuri
Innobase Oy
http://www.innodb.com
Transactions, foreign keys, and a hot backup tool for MySQL
Order MySQL technical support from https://order.mysql.com/



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Starting MySQL with SSL

2003-06-08 Thread Mark Matthews
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Karam Chand wrote:

 Greetings

 I have MySQL 4.0.13 installed on WinXP machine. From
 the DOCS I read that support for SSL is provided with
 MySQL 4.x. The doc says that I need to install the
 library from openssl.org ( which I did ) and then
 configure mysql with --with-vio and --with-openssl?

 Does it mean that I have compile MySQL from the
 source, or what with option do I need to start
 mysqld-nt-max?

 Thanks in advance.

Due to licensing issues with OpenSSL, MySQL does not ship SSL-enabled
binaries for Windows. If you want to use SSL with MySQL on Windows, you
will have to compile it yourself at this time. We are looking at ways to
fix this licensing issue.

-Mark

- --
For technical support contracts, visit https://order.mysql.com/?ref=mmma

__  ___ ___   __
   /  |/  /_ __/ __/ __ \/ /  Mark Matthews [EMAIL PROTECTED]
  / /|_/ / // /\ \/ /_/ / /__ MySQL AB, SW Dev. Manager - J2EE/Windows
 /_/  /_/\_, /___/\___\_\___/ Flossmoor (Chicago), IL USA
___/ www.mysql.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.1 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQE+4zqftvXNTca6JD8RAkejAJwKUEhigiYIkF9vAu+0+keS93jP2gCgmYEl
2aqR4pis3quQw9WreBeMbAE=
=40HH
-END PGP SIGNATURE-


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: mysql: bug in update (?)

2003-06-08 Thread O'K Web Design
Hi

Your problem lies in your columns.  A timestamp field has the special
property of recording when a record is created or modified.  However, only
the first timestamp column in a row is treated this way.  I hope this helps.
Mike


- Original Message -
From: Dmitry Kosoy [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: June 8, 2003 7:51 AM
Subject: mysql: bug in update (?)



 Hi,

 I have a table with 2 fields (among others) with type timestamp
(warndate
 and date).
 I run the following update: update dbowner where warndate = now().
 This update affects not only on the field warndate but on the field
date
 as well.
 After it the both fields got the current date and time value.
 I changed the name of field date to another and got the same result.

 I got the same behavior in many mysql versions include 4.0.12.

 Regards,
   Dmitry

 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



FW: MySQL: bug in update (?)

2003-06-08 Thread Dmitry Kosoy
Sorry,

Now I understood that this behavior is exactly according to documentation.

-Original Message-
Subject: mysql: bug in update (?)

Hi,

I have a table with 2 fields (among others) with type timestamp (warndate
and date).
I run the following update: update dbowner where warndate = now().
This update affects not only on the field warndate but on the field date
as well.
After it the both fields got the current date and time value.
I changed the name of field date to another and got the same result.

I got the same behavior in many mysql versions include 4.0.12.

Regards,
  Dmitry

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Loading database information from a text file.

2003-06-08 Thread Paul DuBois
At 16:59 +1000 6/8/03, JeRRy wrote:
Okay thanks.

One last thing.

From the mysql prompt how can I generate a database
backup?  (So I can see the database setup in notepad
so I can backup and transfer easily online.)
Not from the mysql prompt.  You want to use the mysqldump
program.
Jerry


--
Paul DuBois, Senior Technical Writer
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
Are you MySQL certified?  http://www.mysql.com/certification/

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Loading database information from a text file.

2003-06-08 Thread Paul DuBois
At 18:40 +1000 6/8/03, JeRRy wrote:
Hi,

I downloaded the Windows version of mysql.  And just
set it up but currently it works as root and no
password.  Not a real concern as I shut down the mysql
as I finish working as I use it offline.  But I would
like to setup the user account and password as I have
it on my web server so it's easier to update instead
of changing things.
So if I wanted to create another user other than root
how can I do this?
There's a chapter in the MySQL Reference Manual on access
control.  Specifically, you want to read the material
about the GRANT statement.
Thanks!



--
Paul DuBois, Senior Technical Writer
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
Are you MySQL certified?  http://www.mysql.com/certification/

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Hi CPU on FreeBSD

2003-06-08 Thread Gunnar Helliesen
On Sat, 22 Jun 2002 17:43:12 -0700 Jeremy Zawodny wrote:
 
 On Sat, Jun 22, 2002 at 07:26:36PM -0500, mos wrote:
 
  We've managed to reproduce this pretty reliably at Yahoo and are
  working to track and fix the bug.  If we find a resolution, I'll post
  a note here.
  
  There have been a few threads regarding high CPU utilization on
  FreeBSD systems.
 
 Yeah, I mostly ingored them because I thought it was a fluke.  
 But it happens much more than I had thought.

It's still happening on the site I first reported it on. We're currently
running max-4.0.11-gamma, but the problem has been present since 3.x.
FreeBSD 4.4 and 4.5.

  The 2nd processor may be causing the problem.
 
 We can reproduce it on a single CPU box too.  The number of 
 CPUs isn't the issue.

Same here. One or more CPUs makes _no_ difference. Load seems to factor in,
though.

Since I made my original post
http://lists.mysql.com/list.php?list=mysqlpost=107745, I've moved the
load (web site access tracking ++) from the single-CPU machine to the SMP
machine. The problem moved right along with the load.

  You may want to contact the original authors to see if they've come
  up with a solution.
 
 I likely will.  Thanks.
 
 Jeremy

Any news?

Gunnar

-- 
Gunnar Helliesen   | Bergen IT Consult | Open Source activist
Systems Consultant | Bergen, Norway| Jaguar enthusiast
[EMAIL PROTECTED]   | www.bitcon.no/~gunnar | Märklin collector

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: mysql: bug in update (?)

2003-06-08 Thread Paul DuBois
At 14:51 +0300 6/8/03, Dmitry Kosoy wrote:
Hi,

I have a table with 2 fields (among others) with type timestamp (warndate
and date).
I run the following update: update dbowner where warndate = now().
This update affects not only on the field warndate but on the field date
as well.
After it the both fields got the current date and time value.
I changed the name of field date to another and got the same result.
I got the same behavior in many mysql versions include 4.0.12.
This is how the TIMESTAMP column type works.  You'll find this section
of the manual to be of interest:
http://www.mysql.com/doc/en/DATETIME.html

Regards,
  Dmitry


--
Paul DuBois, Senior Technical Writer
Madison, Wisconsin, USA
MySQL AB, www.mysql.com
Are you MySQL certified?  http://www.mysql.com/certification/

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Can't insert data from Apache/PHP

2003-06-08 Thread ComCity
Oh sorry...my bad.  :)

I started troubleshooting the code and discovered the problem was the new
register globals which is defaulted to off in PHP 4.22.  The PHP wasn't
holding session and wasn't inserting the records into the mySQL database.
I got it working now by switching the register globals back to ON.

- Original Message -
From: Becoming Digital [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, June 08, 2003 1:35 AM
Subject: Re: Can't insert data from Apache/PHP


 So the next step would be to provide us with the code so that we might try
to
 help you. :)

 Edward Dudlik
 Becoming Digital
 www.becomingdigital.com


 - Original Message -
 From: ComCity [EMAIL PROTECTED]
 To: Becoming Digital [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Sent: Sunday, 08 June, 2003 01:55
 Subject: Re: Can't insert data from Apache/PHP


 Yep...figured that out.

 Thank You

 - Original Message -
 From: Becoming Digital [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Saturday, June 07, 2003 6:48 PM
 Subject: Re: Can't insert data from Apache/PHP


  That points to a fault in your coding because phpMyAdmin *is* PHP
running
 via
  the web server.
 
  Edward Dudlik
  Becoming Digital
  www.becomingdigital.com
 
 
  - Original Message -
  From: ComCity [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Sent: Saturday, 07 June, 2003 21:09
  Subject: More: Can't insert data from Apache/PHP
 
 
  It looks like I can insert data through phpMyadmin without issue.  The
 only
  place I can't insert data is through PHP running via the web server.
 
  To: [EMAIL PROTECTED]
  Sent: Saturday, June 07, 2003 5:03 PM
  Subject: Can't insert data from Apache/PHP
 
 
   I've had to reinstall Linux/Apache and mySQL.  The databases are
 restored,
   the data looks to be there, the permissions look to be there.
However,
 I
   can't seem INSERT data into the tablesits the only thing I can't
   do...and I don't see a problem with the permissions.  Don't get any
 errors
   on the webpage but nothing happens.  If I do a select, it works just
 fine.
   I have the database permissions set wide open for troubleshooting.
  
  
   RWL
   owner X XX
   group X XX
   other  X XX
  
   Owner= mysql
   group= mysql
  
   What am I missing?  Its got to be something stupid and something
 small
  
   Thank You very much.
   Michael B.
  
 
 
  --
  MySQL General Mailing List
  For list archives: http://lists.mysql.com/mysql
  To unsubscribe:
 http://lists.mysql.com/[EMAIL PROTECTED]
 
 
 
 
 
  --
  MySQL General Mailing List
  For list archives: http://lists.mysql.com/mysql
  To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
 


 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]





 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



optimizing a self join

2003-06-08 Thread Lars Nygaard
Hi,

I have a table (named text) looking like this, somewhat simplified:

+---++
| id| string |
+---++
| 1 | Here   |
| 2 | is |
| 3 | some   |
| 4 | text   |
| 5 | .  |
| 6 | And|
| 7 | it's   |
| 8 | in |
| 9 | a  |
| 10| table  |
| 11| .  |
[...]

It contains about 12 million rows, but for simple queries, selects are
very fast (ie. mostly sub-second). However, this self join

mysql SELECT a.string, b.string FROM text a, text b WHERE a.string =
'something' and b.string = 'other' and b.string_id = a.string_id+1;

is comparatively slow (over a minute to retreive 20 rows), suggesting that
indexes are not used.

Does anyone know how to optimize this query, or know of another way to
select string x, if the next string is y?.

An obvious answer would of course be Do you really need a mysql table for
this? There are a gazillion full text indexing packages out there!. Yes,
I do need to store it in a mysql table - it's part of a much larger
database.


Thanks in advance.

Lars Nygaard,
The Text Laboratory,
University of Oslo


SHOW INDEX output:

+---++---+--+-+---+-+--++-+
| Table | Non_unique | Key_name  | Seq_in_index | Column_name | Collation
| Cardinality | Sub_part | Packed | Comment |
+---++---+--+-+---+-+--++-+
| oslo2 |  0 | PRIMARY   |1 | string_id   | A
|12162868 | NULL | NULL   | |
| oslo2 |  1 | string|1 | string  | A
|  434388 | NULL | NULL   | |
| oslo2 |  1 | string|2 | string_id   | A
|12162868 | NULL | NULL   | |
| oslo2 |  1 | string_id |1 | string_id   | A
|12162868 | NULL | NULL   | |
| oslo2 |  1 | string_id |2 | string  | A
|12162868 | NULL | NULL   | |
+---++---+--+-+---+-+--++-+


EXPLAIN SELECT output:

+---++--+-+-+--+--+-+
| table | type   | possible_keys| key | key_len | ref  |
rows | Extra   |
+---++--+-+-+--+--+-+
| a | range  | string   | string  |  40 | NULL |
3159 | where used; Using index |
| b | eq_ref | PRIMARY,string,id| PRIMARY |   4 | func |
1 | where used  |
+---++--+-+-+--+--+-+




-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: passwords in mysql 4.1.0-alpha

2003-06-08 Thread Stefan Hinz
Renán,

 I installed the version 4.1.0-alpha of mysql in
 Windows XP. At the beginning and in general everything
 works very well. But I have a problem of
 incompatibility (I guess). When users are created with
 passwords, those users cannot be connected. Mysql
 says: Client don't support the authentication
 protocol required by server, consider upgrade client.
 What happen 

The length of the password hash (in the mysql.user Password column)
has changed from 16 (MySQL  4.1.0) to 45 bytes (MySQL 4.1.0). You can
still use the old hash length, but this is sort of tricky, and
documentation about this is about to be released in the near future.
Unfortunately, there will be yet another change regarding the Password
column in 4.1.1 that makes documentation of that behaviour a bit more
complicated.

Anyway, what you describe above is a typical problem that arises when
you create a new user (with GRANT) or change an existing user's
password (e.g. with SET PASSWORD), and then try to connect as that
user with an older client (e.g. mysql from 4.0.13). Trying to connect
as that user from a new client should be no problem.

Regards,
--
  Stefan Hinz [EMAIL PROTECTED]
  iConnect GmbH http://iConnect.de
  Heesestr. 6, 12169 Berlin (Germany)
  Telefon: +49 30 7970948-0  Fax: +49 30 7970948-3

[filter fodder: sql, mysql, query]


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Can't send Register ID

2003-06-08 Thread Robson Oliveira
Hi,

I'm trying to send a e-mail with the record register ID from a PHP code query and 
don't show the value.

// Connect to database
$db = mysql_connect (localhost, my_db, passxx);
 
// Select the database

mysql_select_db(my_db, $db); 
 
// Select user registration ID from the database based on the last record string 
$ssecurity_record from the registration page.
 
$register_id = mysql_query( SELECT register_id from table_register WHERE 
$ssecurity_record = ssecurity_record;

echo $register_id = At this time the value is blank when I print the value


Please, If someone know how to print the record value and Select function in php send 
to me.

-rgoliver


Re: Can't send Register ID

2003-06-08 Thread Fred van Engen
Hi,

On Sun, Jun 08, 2003 at 01:53:24PM -0300, Robson Oliveira wrote:
 I'm trying to send a e-mail with the record register ID from a PHP code query and 
 don't show the value.
 
 // Connect to database
 $db = mysql_connect (localhost, my_db, passxx);
  

$db = mysql_connect (localhost, my_db, passxx);
if (!$db) {
  print 'mysql_connect error: '.mysql_error();
}
else {

 // Select the database
 
 mysql_select_db(my_db, $db); 
  

  if (!mysql_select_db(my_db, $db)) {
print 'mysql_select_db error: '.mysql_error();
  }
  else {

 // Select user registration ID from the database based on the last record string 
 $ssecurity_record from the registration page.
  
 $register_id = mysql_query( SELECT register_id from table_register WHERE 
 $ssecurity_record = ssecurity_record;
 

Are you sure it gets this far? Your line above won't compile because of
a missing  and a missing ).

$result = mysql_query( SELECT register_id from table_register WHERE 
$ssecurity_record = ssecurity_record );

if (!result) {
  print 'mysql_query error: '.mysql_error();
}
else {
  $row = mysql_fetch_row($result);
  if (!row) {
print 'mysql_fetch_row: no row, error: '.mysql_error();
  }
  else {
$register_id = $row['register_id'];

 echo $register_id = At this time the value is blank when I print the value
 

  }
}
  }
}


 
 Please, If someone know how to print the record value and Select function in php 
 send to me.
 

Read the manual, check return values, etc. If you're running PHP in
apache, then check the error_log and use the error_log() function
instead of print as I use in the code above.

My code above is untested BTW.


Regards,

Fred.


-- 
Fred van Engen  XB Networks B.V.
email: [EMAIL PROTECTED]Televisieweg 2
tel: +31 36 5462400 1322 AC  Almere
fax: +31 36 5462424 The Netherlands

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Replication over SSL

2003-06-08 Thread Jim Winstead
On Sun, Jun 08, 2003 at 01:08:58PM +0100, Gareth Davis wrote:
 I guess that explains alot. Is there any work around with say,
 stunnel/ssh etc?

Yes, you could certainly use something like stunnel or an ssh tunnel to
forward a port between two machines and do replication over that.

Here's a couple of articles that may help:

  http://www.guydavis.ca/projects/oss/docs/ssh_mysql.jsp
  http://www.stunnel.org/examples/mysql.html

One thing to keep in mind is that when you want to connect to a MySQL
server via a non-standard port on your local machine, you need to
specify the host to connect to as '127.0.0.1', and not 'localhost'. When
using 'localhost', MySQL generally tries to connect using a local Unix
socket, and ignores the port you specify.

Jim Winstead
MySQL AB

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Hi CPU on FreeBSD

2003-06-08 Thread Jeremy Zawodny
On Sun, Jun 08, 2003 at 03:37:17PM +0200, Gunnar Helliesen wrote:
 On Sat, 22 Jun 2002 17:43:12 -0700 Jeremy Zawodny wrote:
  
  On Sat, Jun 22, 2002 at 07:26:36PM -0500, mos wrote:
  
   We've managed to reproduce this pretty reliably at Yahoo and are
   working to track and fix the bug.  If we find a resolution, I'll post
   a note here.
   
   There have been a few threads regarding high CPU utilization on
   FreeBSD systems.
  
  Yeah, I mostly ingored them because I thought it was a fluke.  
  But it happens much more than I had thought.
 

[snip]

 Any news?

Wow, you fond 1-year old thread on this.  Impressive. :-)

Yes, there's good news:

  http://jeremy.zawodny.com/blog/archives/000697.html

Jeremy
-- 
Jeremy D. Zawodny |  Perl, Web, MySQL, Linux Magazine, Yahoo!
[EMAIL PROTECTED]  |  http://jeremy.zawodny.com/

MySQL 4.0.13: up 5 days, processed 170,695,248 queries (358/sec. avg)

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Load Data Local Infile

2003-06-08 Thread John May
OK, tearing my hair out here...

I am trying to get a LOAD DATA LOCAL INFILE command to work.  It 
works when I start the MySQL client with --local-infile=1, but 
never in any other situation.  Starting without this option, or 
submitting the request through PHP or Lasso results in the command 
isn't supported error.

I have tried a million different my.cnf changes, but no luck.

Is there any way to tell MySQL to default to allowing LOAD DATA LOCAL 
INFILE instead of having to specify it in the client login?  I'm 
trying this with both version 3.23.51 and 4.0.12-max.

The even odder thing is that I can get it to work fine on another 
machine running the pre-built 3.23.51 binary from entropy.ch.  AND, 
if I move that build to the 3.23.51 hand-built machine, the error 
returns.

Any ideas GREATLY appreciated.  Thanks!

	- John

--

---
John May : President  http://www.pointinspace.com
Point In Space Internet Solutions [EMAIL PROTECTED]
 LPA Corporate Partner / FSA Associate / ACN Member

  Lasso 5 + 6 / PHP / MySQL / FileMaker Pro Hosting Now Available!

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


MYSQL privileges System

2003-06-08 Thread Mike Walth
Hello:

I was wondering if anyone had any advice to a couple questions.

1)  Can I add additional columns to the user and db tables of mysql.  These
would be for administrative purposes only.

2)  I'm trying to figure out how the privileges effect the system.  I
understand what each one does, but haven't found a clear explanation of what
the difference is in the db table and the user table.  If any one can
explain this I would appreciate it.

3)  I'm looking to come up with the most secure set of privileges for the
user and db tables.  I want the users to be able to select, insert, delete,
create tables, just the basic functions on their database only.  Multiple
databases are hosted on the same mysql server.

Thank you for your help in these questions.

Mike Walth
CinoFusion



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Load Data Local Infile

2003-06-08 Thread Rony Koting
If you don't configure MySQL with --enable-local-infile, then LOAD DATA
LOCAL will be disabled by all clients, unless one calls mysql_options(...
MYSQL_OPT_LOCAL_INFILE, 0) in the client

Read the mysql manual from msyql.com about
'manual_MySQL_Database_Administration.html#LOAD_DATA_LOCAL'

Regards,
- Original Message -
From: John May [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, June 09, 2003 2:17 AM
Subject: Load Data Local Infile


 OK, tearing my hair out here...

 I am trying to get a LOAD DATA LOCAL INFILE command to work.  It
 works when I start the MySQL client with --local-infile=1, but
 never in any other situation.  Starting without this option, or
 submitting the request through PHP or Lasso results in the command
 isn't supported error.

 I have tried a million different my.cnf changes, but no luck.

 Is there any way to tell MySQL to default to allowing LOAD DATA LOCAL
 INFILE instead of having to specify it in the client login?  I'm
 trying this with both version 3.23.51 and 4.0.12-max.

 The even odder thing is that I can get it to work fine on another
 machine running the pre-built 3.23.51 binary from entropy.ch.  AND,
 if I move that build to the 3.23.51 hand-built machine, the error
 returns.

 Any ideas GREATLY appreciated.  Thanks!

 - John

 --

 ---
 John May : President  http://www.pointinspace.com
 Point In Space Internet Solutions [EMAIL PROTECTED]

   LPA Corporate Partner / FSA Associate / ACN Member

Lasso 5 + 6 / PHP / MySQL / FileMaker Pro Hosting Now Available!


 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Load Data Local Infile

2003-06-08 Thread John May
Can this only be done at build time?  Or can I enable it after the 
fact?  If so, how?  I tried enable-local-infile as both a setting in 
my.cnf and when calling safe_mysqld both with no luck.

In the meantime, I've found that PHP apparently calls MySQL with the 
local-infile option on - once I downgraded to 4.2.2 from 4.3.0 that 
is.  This at least helps things a bit.

	- John


If you don't configure MySQL with --enable-local-infile, then LOAD DATA
LOCAL will be disabled by all clients, unless one calls mysql_options(...
MYSQL_OPT_LOCAL_INFILE, 0) in the client
Read the mysql manual from msyql.com about
'manual_MySQL_Database_Administration.html#LOAD_DATA_LOCAL'
Regards,
- Original Message -
From: John May [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, June 09, 2003 2:17 AM
Subject: Load Data Local Infile

 OK, tearing my hair out here...

 I am trying to get a LOAD DATA LOCAL INFILE command to work.  It
 works when I start the MySQL client with --local-infile=1, but
 never in any other situation.  Starting without this option, or
 submitting the request through PHP or Lasso results in the command
 isn't supported error.
 I have tried a million different my.cnf changes, but no luck.

 Is there any way to tell MySQL to default to allowing LOAD DATA LOCAL
 INFILE instead of having to specify it in the client login?  I'm
 trying this with both version 3.23.51 and 4.0.12-max.
 The even odder thing is that I can get it to work fine on another
 machine running the pre-built 3.23.51 binary from entropy.ch.  AND,
 if I move that build to the 3.23.51 hand-built machine, the error
 returns.
 Any ideas GREATLY appreciated.  Thanks!

  - John
--

---
John May : President  http://www.pointinspace.com
Point In Space Internet Solutions [EMAIL PROTECTED]
 LPA Corporate Partner / FSA Associate / ACN Member

  Lasso 5 + 6 / PHP / MySQL / FileMaker Pro Hosting Now Available!

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Load Data Local Infile

2003-06-08 Thread John May
The other odd thing I find is that the MySQL manual states:

By default, all MySQL clients and libraries are compiled with 
--enable-local-infile , to be compatible with MySQL 3.23.48 and 
before.

However, I'm using a 4.0.12-max binary (pre-compiled binary direct 
from MySQL's site) on one machine, and enable-local-infile is 
definitely NOT compiled into it...

Have others seen this case contrary to the documentation?

	- John


Can this only be done at build time?  Or can I enable it after the 
fact?  If so, how?  I tried enable-local-infile as both a setting in 
my.cnf and when calling safe_mysqld both with no luck.

In the meantime, I've found that PHP apparently calls MySQL with the 
local-infile option on - once I downgraded to 4.2.2 from 4.3.0 that 
is.  This at least helps things a bit.

	- John


If you don't configure MySQL with --enable-local-infile, then LOAD DATA
LOCAL will be disabled by all clients, unless one calls mysql_options(...
MYSQL_OPT_LOCAL_INFILE, 0) in the client
Read the mysql manual from msyql.com about
'manual_MySQL_Database_Administration.html#LOAD_DATA_LOCAL'
Regards,
- Original Message -
From: John May [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, June 09, 2003 2:17 AM
Subject: Load Data Local Infile
  OK, tearing my hair out here...
 
  I am trying to get a LOAD DATA LOCAL INFILE command to work.  It
  works when I start the MySQL client with --local-infile=1, but
  never in any other situation.  Starting without this option, or
  submitting the request through PHP or Lasso results in the command
  isn't supported error.
 
  I have tried a million different my.cnf changes, but no luck.
 
  Is there any way to tell MySQL to default to allowing LOAD DATA LOCAL
  INFILE instead of having to specify it in the client login?  I'm
  trying this with both version 3.23.51 and 4.0.12-max.
 
  The even odder thing is that I can get it to work fine on another
  machine running the pre-built 3.23.51 binary from entropy.ch.  AND,
  if I move that build to the 3.23.51 hand-built machine, the error
  returns.
 
  Any ideas GREATLY appreciated.  Thanks!
 
  - John
--

---
John May : President  http://www.pointinspace.com
Point In Space Internet Solutions [EMAIL PROTECTED]
 LPA Corporate Partner / FSA Associate / ACN Member

  Lasso 5 + 6 / PHP / MySQL / FileMaker Pro Hosting Now Available!

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Re: Load Data Local Infile

2003-06-08 Thread Mark Matthews
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

John May wrote:

 The other odd thing I find is that the MySQL manual states:


 By default, all MySQL clients and libraries are compiled with
 --enable-local-infile , to be compatible with MySQL 3.23.48 and before.


 However, I'm using a 4.0.12-max binary (pre-compiled binary direct from
 MySQL's site) on one machine, and enable-local-infile is definitely NOT
 compiled into it...

 Have others seen this case contrary to the documentation?

 - John

You don't say what OS you're on, but this was broken in Windows builds
until MySQL 4.0.13 (which is the latest stable version, btw.)

-Mark
- --
For technical support contracts, visit https://order.mysql.com/?ref=mmma

__  ___ ___   __
   /  |/  /_ __/ __/ __ \/ /  Mark Matthews [EMAIL PROTECTED]
  / /|_/ / // /\ \/ /_/ / /__ MySQL AB, SW Dev. Manager - J2EE/Windows
 /_/  /_/\_, /___/\___\_\___/ Flossmoor (Chicago), IL USA
___/ www.mysql.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.1 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQE+46F7tvXNTca6JD8RAqwZAJwNVmxY0KhQXm5NXpcAyiSTFKRp6gCfVwnj
UAMdENoo/r4wH8izEQwTYrU=
=g6z4
-END PGP SIGNATURE-


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Load Data Local Infile

2003-06-08 Thread Rony Koting
configuring is only be done on build time procedure.
I supposed (not sure) that your problem is with your precompiled binary. I
dont really know whether the default precompiled binary building with enable
LOAD DATA or not.
so , you can try install it with mysql source .(not precompile binary).

Regards.

ROny
- Original Message -
From: John May [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, June 09, 2003 3:31 AM
Subject: Re: Load Data Local Infile


 The other odd thing I find is that the MySQL manual states:


 By default, all MySQL clients and libraries are compiled with
 --enable-local-infile , to be compatible with MySQL 3.23.48 and
 before.


 However, I'm using a 4.0.12-max binary (pre-compiled binary direct
 from MySQL's site) on one machine, and enable-local-infile is
 definitely NOT compiled into it...

 Have others seen this case contrary to the documentation?

 - John


 Can this only be done at build time?  Or can I enable it after the
 fact?  If so, how?  I tried enable-local-infile as both a setting in
 my.cnf and when calling safe_mysqld both with no luck.
 
 In the meantime, I've found that PHP apparently calls MySQL with the
 local-infile option on - once I downgraded to 4.2.2 from 4.3.0 that
 is.  This at least helps things a bit.
 
  - John
 
 
 If you don't configure MySQL with --enable-local-infile, then LOAD DATA
 LOCAL will be disabled by all clients, unless one calls
mysql_options(...
 MYSQL_OPT_LOCAL_INFILE, 0) in the client
 
 Read the mysql manual from msyql.com about
 'manual_MySQL_Database_Administration.html#LOAD_DATA_LOCAL'
 
 Regards,
 - Original Message -
 From: John May [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Monday, June 09, 2003 2:17 AM
 Subject: Load Data Local Infile
 
 
OK, tearing my hair out here...
   
I am trying to get a LOAD DATA LOCAL INFILE command to work.  It
works when I start the MySQL client with --local-infile=1, but
never in any other situation.  Starting without this option, or
submitting the request through PHP or Lasso results in the command
isn't supported error.
   
I have tried a million different my.cnf changes, but no luck.
   
Is there any way to tell MySQL to default to allowing LOAD DATA
LOCAL
INFILE instead of having to specify it in the client login?  I'm
trying this with both version 3.23.51 and 4.0.12-max.
   
The even odder thing is that I can get it to work fine on another
machine running the pre-built 3.23.51 binary from entropy.ch.  AND,
if I move that build to the 3.23.51 hand-built machine, the error
returns.
   
Any ideas GREATLY appreciated.  Thanks!
   
- John

 --

 ---
 John May : President  http://www.pointinspace.com
 Point In Space Internet Solutions [EMAIL PROTECTED]

   LPA Corporate Partner / FSA Associate / ACN Member

Lasso 5 + 6 / PHP / MySQL / FileMaker Pro Hosting Now Available!


 --
 MySQL General Mailing List
 For list archives: http://lists.mysql.com/mysql
 To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: Load Data Local Infile

2003-06-08 Thread John May
OS X (10.1 Client and 10.2 Server).

My 3.23.51 builds seem to have the same problem.

Since PHP access it properly, and the MySQL client can with the 
proper variable setting, I guess I'll just leave it alone.

	- John


-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
John May wrote:

 The other odd thing I find is that the MySQL manual states:

 By default, all MySQL clients and libraries are compiled with
 --enable-local-infile , to be compatible with MySQL 3.23.48 and before.
 However, I'm using a 4.0.12-max binary (pre-compiled binary direct from
 MySQL's site) on one machine, and enable-local-infile is definitely NOT
 compiled into it...
 Have others seen this case contrary to the documentation?

 - John
You don't say what OS you're on, but this was broken in Windows builds
until MySQL 4.0.13 (which is the latest stable version, btw.)
-Mark
- --
For technical support contracts, visit https://order.mysql.com/?ref=mmma
__  ___ ___   __
   /  |/  /_ __/ __/ __ \/ /  Mark Matthews [EMAIL PROTECTED]
  / /|_/ / // /\ \/ /_/ / /__ MySQL AB, SW Dev. Manager - J2EE/Windows
 /_/  /_/\_, /___/\___\_\___/ Flossmoor (Chicago), IL USA
___/ www.mysql.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.1 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQE+46F7tvXNTca6JD8RAqwZAJwNVmxY0KhQXm5NXpcAyiSTFKRp6gCfVwnj
UAMdENoo/r4wH8izEQwTYrU=
=g6z4
-END PGP SIGNATURE-


--

---
John May : President  http://www.pointinspace.com
Point In Space Internet Solutions [EMAIL PROTECTED]
 LPA Corporate Partner / FSA Associate / ACN Member

  Lasso 5 + 6 / PHP / MySQL / FileMaker Pro Hosting Now Available!

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]


Linux install problem

2003-06-08 Thread Steve Mansfield
Having run MySQL successfully for a while in a WAMP environment, I'm trying
to set up on Linux now (and am a real Linux newbie). I'm using the 4.3.1
version that came as an RPM with SuSE 8.2. The problem is - it doesn't work.

Here's where the various elements have installed to:

/usr/bin
various mysql progs  scripts, incl
mysql
mysqladmin
mysql_install_db
safe_mysqld
 etc

/usr/sbin
mysqld

/var/lib/mysql
mysql.sock
mysql.log
linux-bin.001 etc

when I run mysql_install_db (in /usr/bin), it creates the 'mysql' dir in
var/lib/mysql - so the path to the default database files becomes:
/var/lib/mysql/mysql/

From /usr/bin, I run:
safe_mysqld --user=mysql 
and get the message
Starting mysqld daemon with databases from /var/lib/mysql
but then the daemon shuts down straight away.

When I look in the log file, I find:
/usr/sbin/mysqld: Can't find file: './mysql/host.frm' (errno: 13)

It looks as though the mysql_install_db has put the files in the wrong
place. Can anyone give me some advice as to how I sort this out...? Thanks.

Steve


Re: CAUTION! ALERT! WARNING! Newbie on board :)

2003-06-08 Thread Don Read

On 07-Jun-2003 Andre wrote:

snip

Please don't hi-jack threads. 
By replying to a message and changing the subject, you screw-up the
threading features of most mail clients.

If you want to start a new thread then please start with a new message.

snip

 
 1) Any ideas where I might begin to look to find out what is the
 problem? Yeah, i'm already considering getting a different host for my
 domain since alot of the back end stuff I care about fails to work at
 this host -- but their uptime for my web pages is so good.
 
 2) Are there any common configuration/installation/user errors that
 contribute to a database not accepting data in the rows?
 

A. register_globals is turned off, so the the global variables aren't set.

B. The php user does not have 'Insert' privileges.
run SHOW GRANTS FOR [EMAIL PROTECTED]

 3) what else might you suggest?
 

A. Use mysql_query() || die(mysql_error()) construct instead of 
   guessing at what the error is.

$qry=INSERT INTO foo VALUES('$bar', '$baz', '$bohica');
$res=mysql_query($qry) ||
  die ('PError :BR' .mysql_errno .' ' .mysql_error() .'P');

B. add a debug function:

function debug($fl, $ln, $msg='') {
global $debugon;

if ($debugon)) {
printf(\n!-- Debug %s %s:\n, $fl , $ln);
print_r($msg);
echo \n --\n;
}
}

$debugon=1;

$qry=INSERT INTO foo VALUES('$bar', '$baz', '$bohica');
debug(__FILE__, __LINE__, $qry);

Then look at page source to see if the query is what you think it is.

snip 

Regards,
-- 
Don Read   [EMAIL PROTECTED]
-- It's always darkest before the dawn. So if you are going to 
   steal the neighbor's newspaper, that's the time to do it.
(53kr33t w0rdz: sql table query)


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



forming foreign keys

2003-06-08 Thread Nils Valentin
Hello Mysql list,

I try to create foreign keys in a innodb database. I read through some threats 
and the manual, and several online resources, but somehow I am missing 
something.


What I try to do is recreate the keys and their functions of the mysql 
database (privilege database) as a innodb database, including foreign keys to 
illustrate the relations.

The copy of the mysql privilege database is called mysql_privileges_db_inno.

The 6 tables structure host, user, db etc. was copied to the innodb database 
and then modified with ALTER.

Now when I try to create  a foreign key I get the famous Error 1105 which 
tells me that I didnt form the request for the foreign key proberly.

mysql ALTER TABLE db ADD FOREIGN KEY (User) REFERENCES user (User);
ERROR 1005: Can't create table './mysql_privileges_db_inno/#sql-2e8_10.frm' 
(errno: 150)

Could anybody be so kind  pointing me to the right direction ?

Any help much appreciated.  

-- 

Valentin Nils
Internet Technology

 E-Mail: [EMAIL PROTECTED]
 URL: http://www.knowd.co.jp
http://www.knowd.co.jp/staff/nils/mysql-error-codes.html


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]