Problom with creating database

2002-09-17 Thread rdkurth


I have a brand new install of mysql . I have set every thing up just
like I have on many Linux server but this one I am getting an error
when I try to create a database from the Command line from and PHP
script or from phpMyAdmin. Could somebody tell me what this error
is and how I can fix it. I have un-installed and re installed mysql at
least 3 times and I can not get it to work.

1006: Can't create database 'control'. (errno: 122)

-- 
Best regards,
 rdkurth  mailto:[EMAIL PROTECTED]


-
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




mysql4.0.3-beta with delphi5.0

2002-09-17 Thread kayamboo
Hello friends
Is there anyone using mysql with delphi5.0
I will be very thankful to get some tips to connect to  a remote server
running mysql4.0.3-beta using delphi5.0 odbc dsn.
I am able to connect with a local server but can't with a remote server.
I can't find any help in the delphi sites.

Any tips or suggestion urls will be greatly appreciated

Regards
Kayamboo Suresh

sql,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: InnoDB Win2k Service doesn't start

2002-09-17 Thread Heikki Tuuri

Matthew,

- Original Message -
From: Matthew Fallshaw [EMAIL PROTECTED]
Newsgroups: mailing.database.mysql
Sent: Tuesday, September 17, 2002 5:40 AM
Subject: Re: InnoDB Win2k Service doesn't start


 [EMAIL PROTECTED] (Matthew Fallshaw) wrote in message
news:[EMAIL PROTECTED]...
  Now, I've done some searching on the newsgroup on this matter and came
  up with the advice to start from a command prompt (so I could see the
  error messages being generated)... here's the rub: it starts perfectly
  well with
  C:\mysql\binmysqld-max-nt --console


 And after a bit more testing, it's the --console bit that keeps the
 server alive (keeping by DOS prompt captive):
 ---
 C:\mysql\binmysqld-max-nt --console
 020917 12:38:44  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.
 020917 12:38:45  InnoDB: Started
 mysqld-max-nt: ready for connections

 ---
 (there's no prompt there - I have to CTRL-C to close)

 Without the --console the command runs without any messages and
 returns me to a prompt (without the server active):

you have to use either the --console option or the --standalone option when
you run from the command line in Windows.

 ---
 C:\mysql\binmysqld-max-nt

 C:\mysql\bin
 ---

 Any ideas anyone? Please?

Was the original problem that the mysqld in the service does not support
InnoDB? Then probably the wrong executable has been installed as the
service. Please see the MySQL manual
http://www.mysql.com/doc/en/NT_start.html about how to remove mysqld.exe,
mysqld-opt.exe, or mysqld-nt.exe from being a service, and how to install
mysqld-max.exe or mysqld-max-nt.exe as a service.

 M@

Best regards,

Heikki Tuuri
Innobase Oy
---
Order technical MySQL/InnoDB support at https://order.mysql.com/
See http://www.innodb.com for the online manual and latest news on InnoDB

sql 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




openbsd 3.1 problem

2002-09-17 Thread Bartomiej Dolata

hi,

i am having problems with mysql 3.23.52
compiled from the sources and being ran
on openbsd 3.1.

it ocassionaly (a few times a day) gets signal 11.
there is no specific query (most often its just 
count(*) from a table) that causes that.

i tried recompiling with custom options (e.g. -O2 instead of -O3,
no proc nor arch optimisations) but behaviour
is the same.

i did not have these problems with 3.23.49 running on the 
same hardware under openbsd 2.8

how can i debug the problem ? solve it ?

best regards,
terry




-
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




unified logins

2002-09-17 Thread Stephan Stapel

Hi there!

We are thinking about setting up a unified login system in our company. This
involves linux/ irix machines (possibly through nis), windows machines
(through samba) and mysql servers. The question is, how to integrate the
mysql user/ password system into our machine login system (nis), i.e. how
the same username/ password which is used for system login might be used to
login to the mysql database and how to convert system group memberships to
access rights on certain databases/ tables. The other way round, using
pam_myqsl, to use mysql usernames/ passwords for logging in to the system,
wouldn't work as we are planning to use OpenAFS in the near future which
requires it's on password setup...

I saw some fairly old postings on the list so I would like to know whether
there are any current efforts in creating such an interface.

I hope that anyone has help on this.

Kind regards,

Stephan


-
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: The my.cnf and InnoDB tables

2002-09-17 Thread Heikki Tuuri

Dyego,

- Original Message -
From: Dyego Souza do Carmo [EMAIL PROTECTED]
Newsgroups: mailing.database.mysql
Sent: Monday, September 16, 2002 10:26 PM
Subject: The my.cnf and InnoDB tables



 The options in my.cnf

 record_buffer
 join_buffer
 sort_buffer
 key_buffer

 are used by InnoDB ?


record_buffer - yes
join_buffer -yes
sort_buffer -yes
key_buffer - no, except that some temporary tables are MyISAM type and they
use key_buffer.

Note that MySQL uses record_buffer, join_buffer, and sort_buffer on
per-thread basis. Be careful that mysqld does not exceed the Linux x86
memory limit 2 GB.

key_buffer is global, not per-thread.


 -
   ++  Dyego Souza do Carmo   ++   Dep. Desenvolvimento
 -

Best regards,

Heikki Tuuri
Innobase Oy
---
InnoDB - transactions, hot backup, and foreign key support for MySQL
See http://www.innodb.com, download MySQL-Max from http://www.mysql.com






  E S C R I B A   I N F O R M A T I C A
 -
 The only stupid question is the unasked one (somewhere in Linux's HowTo)
 Linux registred user : #230601
 --
 $ look into my eyes
 look: cannot open my eyes
 -
Reply: [EMAIL PROTECTED]

 sql,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




Access denied for user

2002-09-17 Thread luoya li



Hi
I just installed a mysql 3.23.52. I want to set a password for root. But 
when I execute :

C:\mysql\bin\mysqladmin -u root password aaa

system remind:
mysqladmin:connect to server at 'localhost' failed
error: Access denied for user:'root@localhost'(using password:No)

Please tell me why?

thanks for any help.

Alice



_
MSN Photos is the easiest way to share and print your photos: 
http://photos.msn.com/support/worldwide.aspx


-
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: Compiling error 3.23.51 under RedHat 7.3

2002-09-17 Thread Michiel Klaver

Take a look at the MySQL Changelog for the newer version:

Changed handling of gethostbyname() to make the client library thread-safe
even if gethostbyname_r doesn't exist.

So, get the new source, and it should compile without errors...

Michiel Klaver.



-
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




search question

2002-09-17 Thread Meltem Demirkus

Hi,
Is there any other efficient way (--except using LIKE)of searching a keyword
in mysql ...

thanks


-
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




search question

2002-09-17 Thread Meltem Demirkus



 Hi,
 Is there any other efficient way (--except using LIKE)of searching a
keyword
 in mysql ...

 thanks



-
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




A simple error about mysql

2002-09-17 Thread Roger Sun

Hi,every one:
pls help me.

i have downloaded a mysql 3.23.52 server and client linux rpm package.
i installed them on rh7.2

everything is ok.

and the mysqld daemon has also been started.

but when i try to change the root password using the folloing command:

/usr/bin/mysqladmin -u root password 'new-password'

there is an error :

ERROR 1045: Access denied for user: 'root@localhost' (Using password: NO)


i can't also using root account to login mysql

 mysql -uroot 
ERROR 1045: Access denied for user: 'root@localhost' (Using password: NO)


when i login like mysql 

i can login,but i just can use test database, 

what had happended?  how can i resolve this problem?

thank you very much,


Best regards,
Roger




-
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: table creation error with innodb/ sql,query

2002-09-17 Thread kayamboo
Thanks a lot Chris
It worked for me.

But I refered somewhere , that using excessive index will eat up resources.
So is it mandatory to use index even if I am not using them for something
like search?

regards
Kayamboo Suresh
- Original Message -
From: "Chris Tucker" [EMAIL PROTECTED]
To: "kayamboo" [EMAIL PROTECTED]
Sent: Tuesday, September 17, 2002 5:35 PM
Subject: Re: table creation error with innodb/ sql,query


 InnoDB requires that you have an index on both ends of a foreign key
 constraint.  Thus, you need to index the "type" field of the person
 table.  Change your create statement to:
 CREATE TABLE person(
name VARCHAR(50) NOT NULL PRIMARY KEY,
type VARCHAR(50) NOT NULL,
dob DATE,
INDEX (type),
FOREIGN KEY(type) REFERENCES relation(type) ON DELETE CASCADE
 ) TYPE = INNODB ;

 And you should have no problems (note that if "type" was not the primary
 key on the "relation" table you would also have to explicitly declare an
 index for that column).

 Chris

 On Mon, 2002-09-16 at 22:45, kayamboo wrote:
  Hello experts
  I am trying to create innodb tables with foreign key relations but I get
  error 150 meaning that foregin key constraint can't be established.
 
  Here are  the statements
 
  1.CREATE TABLE relation( type VARCHAR(50) NOT NULL PRIMARY KEY)TYPE =
  INNODB;
 
  2.CREATE TABLE person( name VARCHAR(50) NOT NULL PRIMARY KEY, type
  VARCHAR(50) NOT NULL, dob DATE,
 FOREIGN KEY(type) REFERENCES
  relation(type) ON DELETE CASCADE ) TYPE = INNODB ;
 
  But if I remove the type = innodb in the second statement, it is
executed.
  Then I am using the ALTER TABLE syntax to create innodb tables.
 
  Any advice to avoid this alter table syntax? Or my create statement is
  wrong?
 
  Thanks in advance
 
  Regards
  Kayamboo Suresh
 
  sql,query,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
 
 
 




-
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


question about fulltext index

2002-09-17 Thread xuefer tinys

when will we be able to set our own word determination?
when will mysql support multibyte fulltext index

_
ÏíÓÃÊÀ½çÉÏ×î´óµÄµç×ÓÓʼþϵͳ¡ª MSN Hotmail¡£http://www.hotmail.com/cn


-
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: table creation error with innodb/ sql,query

2002-09-17 Thread Chris Tucker

Using indices will slow down inserts/updates on columns, and will use
some amount of storage space (dependant on the size of the columns
indexed, the number of columns indexed, etc.).  However, they
significantly improve performance when doing lookups in a table, which
is especially important when executing joins (as you will most likely be
doing between two tables tied by a foreign key).  Thus, even if InnoDB
did not require you to have an index on your FK columns (which it
absolutely does), it almost certainly makes sense to have indices there
anyway.

-Chris

On Tue, 2002-09-17 at 02:03, kayamboo wrote:
 Thanks a lot Chris
 It worked for me.
 
 But I refered somewhere , that using excessive index will eat up resources.
 So is it mandatory to use index even if I am not using them for something
 like search?
 
 regards
 Kayamboo Suresh
 - Original Message -
 From: Chris Tucker [EMAIL PROTECTED]
 To: kayamboo [EMAIL PROTECTED]
 Sent: Tuesday, September 17, 2002 5:35 PM
 Subject: Re: table creation error with innodb/ sql,query
 
 
  InnoDB requires that you have an index on both ends of a foreign key
  constraint.  Thus, you need to index the type field of the person
  table.  Change your create statement to:
  CREATE TABLE person(
 name VARCHAR(50) NOT NULL PRIMARY KEY,
 type VARCHAR(50) NOT NULL,
 dob DATE,
 INDEX (type),
 FOREIGN KEY(type) REFERENCES relation(type) ON DELETE CASCADE
  ) TYPE = INNODB ;
 
  And you should have no problems (note that if type was not the primary
  key on the relation table you would also have to explicitly declare an
  index for that column).
 
  Chris
 
  On Mon, 2002-09-16 at 22:45, kayamboo wrote:
   Hello experts
   I am trying to create innodb tables with foreign key relations but I get
   error 150 meaning that foregin key constraint can't be established.
  
   Here are  the statements
  
   1.CREATE TABLE relation( type VARCHAR(50) NOT NULL PRIMARY KEY)TYPE =
   INNODB;
  
   2.CREATE TABLE person( name VARCHAR(50) NOT NULL PRIMARY KEY, type
   VARCHAR(50) NOT NULL, dob DATE,
  FOREIGN KEY(type) REFERENCES
   relation(type) ON DELETE CASCADE ) TYPE = INNODB ;
  
   But if I remove the type = innodb in the second statement, it is
 executed.
   Then I am using the ALTER TABLE syntax to create innodb tables.
  
   Any advice to avoid this alter table syntax? Or my create statement is
   wrong?
  
   Thanks in advance
  
   Regards
   Kayamboo Suresh
  
   sql,query,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
  
  
  
 
 
 
 
 



-
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




INSERT IGNORE

2002-09-17 Thread Alec . Cawley

According to the manual, if INSERT IGNORE finds a row already present in
the table, it does not update the row with the new data. How can I get the
opposite behaviour? In my case, there shouldn't be a record with the unique
ID I am inserting. But if there is, my recovery behaviour is to delete the
old one and then do the insert again - I don't care what the old data was,
my new data is correct for the new situation. Can I get MySQL to do that
for me?

  Alec Cawley




-
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




Simple SELECT/CONCAT query?

2002-09-17 Thread Claire Forchheimer


Hi,

I have a question on how to make a simple search...

I have two columns in a MySQLdb-table: item, price
 
I want to list all items with their prices. However, items with the same
price should be concatenated.

 
I've looked through the manual - but can't figure out how to concat
rows
 
This is the result I'm looking for:
 
ItemPrice
 --
Item 125
Item 2, Item 633
Item 335
etc
 
/claire



-
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: ODBC ADO and microsoft

2002-09-17 Thread Chuck Amadi

Bryan Koschmann - GKT wrote:

Hi,

We have an accounting program that was writting in visual basic and runs
on microsoft sql. I was told it uses ADO by the programmer (please note,
I'm not all up on this subject as I should be). I'm wondering if it would
be possible to connect to it somehow from a mysql client and do some
simple queries? Or am I going about this the wrong way? I haven't gotten
him convinced yet to convert/port it to MySQL just yet, as he says MySQL
isn't proven well enough yet *sigh* Yeah I know :) I believe he mumbled
something about problems with transactional support and ADO.

Any help would be great! Thanks!

   Bryan


-
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

Hi there this might help - I use very often Myodbc and Mysql-Front with 
M$ Access 2000 DB and I'm led to beleieve there is support for ADO and 
if you use MySql v4 and InnoDB or BDB (I prefer InnoDB ) and alter table 
to InnoDB you have got transactional support Sorry this feature is loud 
and kicking.
Plz check out this link If not I'm sure someone in the group will 
confirm Plz correct me if I'm wrong .

http://www.mysql.com/products/myodbc/features.html

-- 
Regards 
Chuck Amadi
ICT Dept Systems Programmer
Rhaglenydd Systemau Adran ICT





-
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 doesn't use datetime index?

2002-09-17 Thread sufcrusher

Hi

I have this weird problem, any help is much appreciated. I tried a lot of
things and searched in the documentation, etc. but haven't found a solution
yet.

I have a table 'LogSessions' with a field 'dDateCreation' (datetime type),
which has a normal index on it. A simple query like the following uses the
index just fine:

SELECT COUNT(*)
FROM LogSessions
WHERE LogSessions.dDateCreation = '2001-01-01 00:00:00' AND
LogSessions.dDateCreation = '2001-06-30 23:59:59'

However, as soon as I add a JOIN it stops using the index (3.5+ million
records), I don't understand why.

SELECT COUNT(*)
FROM LogSessions
 INNER JOIN Sessions ON LogSessions.iSessionID=Sessions.ID
WHERE LogSessions.dDateCreation = '2001-01-01 00:00:00' AND
LogSessions.dDateCreation = '2001-06-30 23:59:59'

An EXPLAIN says this:

tabletypepossible_keyskeykey_lenref rowsExtra
LogSessions ALL  IDX_LogSessions_dDateCreation,IDX_LogSessions_iSessionID
3698297 where used
Sessions  eq_ref  PRIMARY PRIMARY 4 LogSessions.iSessionID 1 Using index

It reports the two possible_keys but neither is actually used (key is
empty).

Another test I did is use this WHERE clause (equal instead of
greater-than/smaller-than):
WHERE LogSessions.dDateCreation = '2001-01-01 00:00:00'

Now the index is used again (even with the JOIN), but of course this is not
what I need.

Am I missing something?

Thanks,
Jannes Faber





-
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: search question

2002-09-17 Thread sufcrusher

FULLTEXT index, look in  http://www.mysql.com/manual.php

Jannes Faber

- Original Message - 
From: Meltem Demirkus [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, September 17, 2002 10:33 AM
Subject: search question


 
 
  Hi,
  Is there any other efficient way (--except using LIKE)of searching a
 keyword
  in mysql ...
 
  thanks
 
 
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)




-
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: INSERT IGNORE

2002-09-17 Thread Joseph Bueno

Hi,

Look at REPLACE statement.

Regards
-- 
Joseph Bueno

[EMAIL PROTECTED] wrote:
 According to the manual, if INSERT IGNORE finds a row already present in
 the table, it does not update the row with the new data. How can I get the
 opposite behaviour? In my case, there shouldn't be a record with the unique
 ID I am inserting. But if there is, my recovery behaviour is to delete the
 old one and then do the insert again - I don't care what the old data was,
 my new data is correct for the new situation. Can I get MySQL to do that
 for me?
 
   Alec Cawley
 


-
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: INSERT IGNORE

2002-09-17 Thread Mark Goodge

At 10:24 17/09/2002 +0100, [EMAIL PROTECTED] wrote:
According to the manual, if INSERT IGNORE finds a row already present in
the table, it does not update the row with the new data. How can I get the
opposite behaviour? In my case, there shouldn't be a record with the unique
ID I am inserting. But if there is, my recovery behaviour is to delete the
old one and then do the insert again - I don't care what the old data was,
my new data is correct for the new situation. Can I get MySQL to do that
for me?

The command you're looking for is REPLACE.

Mark


-
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




R: Simple SELECT/CONCAT query?

2002-09-17 Thread Danilo Maurizio

Try with a self-inflicted left join on the field price.

select a.item,b.item,price 
from table a 
left join table b on a.price=b.price
and a.item!=b.item

You should have:

a.Item   b.Item Price
 ---
Item 125
Item 2   Item 6   33
Item 335

Obviously this works only if there are two items with the same price.
With more than two it doesn't work.

Ciao
Danilo

-Messaggio originale-
Da: Claire Forchheimer [mailto:[EMAIL PROTECTED]] 
Inviato: martedì 17 settembre 2002 11.40
A: [EMAIL PROTECTED]
Oggetto: Simple SELECT/CONCAT query? 



Hi,

I have a question on how to make a simple search...

I have two columns in a MySQLdb-table: item, price
 
I want to list all items with their prices. However, items with the same
price should be concatenated.

 
I've looked through the manual - but can't figure out how to concat
rows
 
This is the result I'm looking for:
 
ItemPrice
 --
Item 125
Item 2, Item 633
Item 335
etc
 
/claire



-
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




Timestamp issue in mysql

2002-09-17 Thread Prafulla Girgaonkar

Hello
Following is the description of the problem being faced.

Problem:
The first timestamp column in a table is set to current date-time value as soon as we 
update one or more columns in the table.

Example:

The guest information is stored in a table named GUEST. The schema for it is as below.

create table guest (guestID int, arrivalDate timestamp, departureDate timestamp, 
status char(1));

Above table is populated using following queries.

insert into guest values (1, '2002-09-30',  '2002-10-14', 'Y');
insert into guest values (2, '2002-09-20',  '2002-10-01', 'Y');
insert into guest values (3, '2002-09-15',  '2002-09-25', 'Y');
insert into guest values (4, '2002-09-12',  '2002-09-20', 'Y');


If we use following query to update the status from Y to N, then arrivalDate column is 
set to CURRENT(system) date-time value.

update guest set status = 'N';

Does anybody have any information on this issue?

Thanx in advance.

Prafulla

-
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




Timestamp issue

2002-09-17 Thread Prafulla Girgaonkar


Mysql Version::

Server version  3.23.47-nt
Protocol version10
Connection  . via named pipe
UNIX socket MySQL

OS::
Windows NT 4.0 Workstation


Hello
Following is the description of the problem being faced.

Problem:
The first timestamp column in a table is set to current date-time value as soon as we 
update one or more columns in the table.

Example:

The guest information is stored in a table named GUEST. The schema for it is as below.

create table guest (guestID int, arrivalDate timestamp, departureDate timestamp, 
status char(1));

Above table is populated using following queries.

insert into guest values (1, '2002-09-30',  '2002-10-14', 'Y');
insert into guest values (2, '2002-09-20',  '2002-10-01', 'Y');
insert into guest values (3, '2002-09-15',  '2002-09-25', 'Y');
insert into guest values (4, '2002-09-12',  '2002-09-20', 'Y');


If we use following query to update the status from Y to N, then arrivalDate column is 
set to CURRENT(system) date-time value.

update guest set status = 'N';

Does anybody have any information on this issue?

Thanx in advance.

Prafulla

-
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




Index File locked

2002-09-17 Thread Mustafa Yelmer

Hello,

Sometimes, index file of tables (tablename.MYI) locked by sistem then i
cannot runt any query. So, i restart sytem.

Myodbc database used, Delphi based program with Myodbc, i think this problem
caused by it, but i did not find any solution without restarting my server.

Dou you know solution of this condition?

Thanks
Mustafa Yelmer


-
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




plz reply

2002-09-17 Thread shahana qureshi

hi 
i faced a problem in connecting mysql with vb6 
through odbc driver 
sometime it works well but some time it gives error
message can't initialize provider. catastrophic
error

when i fulsh host then again it works for some time
but again gives same problems.
plz send me solution to my problem if there is any 

regards 
shahana


__
Do you Yahoo!?
Yahoo! News - Today's headlines
http://news.yahoo.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




Re: A simple error about mysql

2002-09-17 Thread Roger Sun

Hi Klaus,
Thank you very much,
i have found the reason.

in fact ,my files and directory's properties are not correct.
i reinstall mysql according the doc
:http://www.mysql.com/documentation/mysql/bychapter/manual_Installing.html#L
inux-RPM

and now everything is ok.


Best regards,
Roger


- Original Message -
From: Franz, Fa. PostDirekt MA [EMAIL PROTECTED]
To: Roger Sun [EMAIL PROTECTED]
Sent: Tuesday, September 17, 2002 5:23 PM
Subject: AW: A simple error about mysql


 Hi Roger,

 as far as i understood , you can login with the
 mysql-client , just by typing in 'mysql'.
 If so , than try for localhost:
 GRANT ALL PRIVILIGES ON *.* TO root@localhost IDENTIFIED BY 'password'
WITH
 GRANT OPTION;
 FLUSH PRIVILIGES;

 And for any other host:
 GRANT ALL PRIVILIGES ON *.* TO root@'%' IDENTIFIED BY 'password' WITH
GRANT
 OPTION
 FLUSH PRIVILIGES;

 Leave the session open and try your a new connect with the passwords you
set
 above ,
 so that in case it doesn't work , you are still connected and not locked
out
 from your own server ;)

 mfg
 Klaus





-
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: Timestamp issue

2002-09-17 Thread Mikhail Entaltsev

Prafulla,

please check documentation http://www.mysql.com/doc/en/DATETIME.html
...
The TIMESTAMP column type provides a type that you can use to automatically
mark INSERT or UPDATE operations with the current date and time. If you have
multiple TIMESTAMP columns, only the first one is updated automatically.
...
You need to change type of fields from timestamp to datetime.

Best regards,
Mikhail.


- Original Message -
From: Prafulla Girgaonkar [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Tuesday, September 17, 2002 1:19 PM
Subject: Timestamp issue



Mysql Version::

Server version  3.23.47-nt
Protocol version10
Connection  . via named pipe
UNIX socket MySQL

OS::
Windows NT 4.0 Workstation


Hello
Following is the description of the problem being faced.

Problem:
The first timestamp column in a table is set to current date-time value as
soon as we update one or more columns in the table.

Example:

The guest information is stored in a table named GUEST. The schema for it is
as below.

create table guest (guestID int, arrivalDate timestamp, departureDate
timestamp, status char(1));

Above table is populated using following queries.

insert into guest values (1, '2002-09-30',  '2002-10-14', 'Y');
insert into guest values (2, '2002-09-20',  '2002-10-01', 'Y');
insert into guest values (3, '2002-09-15',  '2002-09-25', 'Y');
insert into guest values (4, '2002-09-12',  '2002-09-20', 'Y');


If we use following query to update the status from Y to N, then arrivalDate
column is set to CURRENT(system) date-time value.

update guest set status = 'N';

Does anybody have any information on this issue?

Thanx in advance.

Prafulla

-
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




Strange MySQL Crash

2002-09-17 Thread Valery Dachev

Hello,

I've just had a MySQL crash on a very simple operation. I have the
following table:
***
+---+---+--+-+-++
| Field | Type  | Null | Key | Default | Extra  |
+---+---+--+-+-++
| id| bigint(20)|  | PRI | NULL| auto_increment |
| id_cat| tinyint(4)| YES  | | NULL||
| uid   | varchar(255)  | YES  | | NULL||
| url   | varchar(255)  | YES  | | NULL||
| title | varchar(255)  | YES  | | NULL||
| newsintro | varchar(180)  | YES  | | NULL||
| news  | text  | YES  | | NULL||
| date  | timestamp(14) | YES  | | NULL||
| file  | varchar(255)  | YES  | | NULL||
| one   | text  |  | | ||
| two   | text  |  | | ||
| three | text  |  | | ||
+---+---+--+-+-++
***

With the following contents:
***
+++--+--+---+--+---++--+-+-+---+
| id | id_cat | uid  | url  | title | newsintro
|| news  | date   | file | 
|one | two | three |
+++--+--+---+--+---++--+-+-+---+
|  1 |  5 | 1| 2| obicham da obicham da obicham | mrazia da mrazia da 
|mrazia da mrazia | cukam si cukam si cukam si cukam si cukam ... | 20020917121937 | 
|NULL | | |   |
|  2 | 23 | 3| NULL | neshto, koeto niama   | da bude namereno 
|| nikude| 20020917121954 | NULL | 
|| |   |
|  3 |   NULL | NULL | NULL | neshto ne obicham | NULL 
|| NULL  | 20020917122055 | NULL | 
|| |   |
+++--+--+---+--+---++--+-+-+---+
**

However the following query caused the server to die with signal 11:
***
mysql SELECT `id`,`title`,`newsintro`,`news` FROM tblname WHERE 0 OR ( BINARY `title` 
LIKE '%oBiChaM%' ) OR ( BINARY `newsintro` LIKE '%oBiChaM%' ) OR ( BINARY `news` LIKE 
'%oBiChaM%' );
ERROR 2013: Lost connection to MySQL server during query
***

Here it the contents of my mysql.err log:
***
mysqld got signal 11;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked agaist 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=16773120
record_buffer=131072
sort_buffer=2097144
max_used_connections=0
max_connections=100
threads_connected=1
It is possible that mysqld could use up to
key_buffer_size + (record_buffer + sort_buffer)*max_connections = 233979 K
bytes of memory
Hope that's ok, if not, decrease some variables in the equation

Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
Stack range sanity check OK, backtrace follows:
0x80cec24
0x40031a44
0x80cd252
0x80ac46f
0x80addaf
0x80f4122
0x80f3e56
0x80ed3ea
0x80d5dcd
0x80d9ce0
0x80d4ff1
0x80d43d7
Stack trace seems successful - bottom reached
Please read http://www.mysql.com/doc/U/s/Using_stack_trace.html and follow
instructions on how to resolve the stack trace. Resolved
stack trace is much more helpful in diagnosing the problem, so please do
resolve it
Trying to get some variables.
Some pointers may be invalid and cause the dump to abort...
thd-query at 0x83e5628 = SELECT `id`,`title`,`newsintro`,`news` FROM
tblname WHERE 0 OR ( BINARY `title` LIKE '%oBiChaM%' ) OR ( BINARY
`newsintro` LIKE '%oBiChaM%' ) OR ( BINARY `news` LIKE '%oBiChaM%' )
thd-thread_id=1

Successfully dumped variables, if you ran with --log, take a look at the
details of what thread 1 did to cause the crash.  In some cases of really
bad corruption, the values shown above may be invalid

The manual page at http://www.mysql.com/doc/C/r/Crashing.html contains
information that should help you find out what is causing the crash
***

I 

Searching MySQL fields in PHP forms

2002-09-17 Thread David Durham

help with Searching MySQL fields in PHP forms.

We have a couple of search pages on our site and I would like to know what 
wild card characters can be used, for example % before or after a keyword. 
If there is a list could someone please point me in the right direction.

Thanks.

-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




Regarding Mysql4.0

2002-09-17 Thread ch kalyan

hello sir,,

I have downloaded Beta version of Mysql 4.0.3

I didnt find any source code in it..

Will u please inform me how can i get source code in

it

Thanking u...

Kalyan
__
Give your Company an email address like
ravi @ ravi-exports.com.  Sign up for Rediffmail Pro today!
Know more. http://www.rediffmailpro.com/signup/


-
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: Re MySQL on Redhat 7.3

2002-09-17 Thread Peter Goggin

I have got the msql server running and now need to configure it. In
particular I want to set it up to use innodb tables.  When I set up mysql on
win98 I used the mysql-max release which comes with  built in Innodb support
and provides sample my.cnf files with the instructions for setting up Innodb
table spaces.  I cannot find anything similar from the RedHat installation.
The rpms installed are:
mysql-3.23.49-3
mysql-devel-3.23.49-3
mysql-client9-3.23.22-6
mysql-server3.23.49-3

On looking at the mysql site, it looks as though I need another rpm,
mysql-max-3.23.49-3 which should be installed after the others. Is this
correct and if so where can I down load it. (the current version is 3.23.52)

Regards

Peter Goggin




-
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: Regarding Mysql4.0

2002-09-17 Thread Iikka Meriläinen

Hello,

The normal binary packages don't include source code. You have to download
the source code package (also available from those download pages). For
most users this will suffice, but the source is also available on
BitKeeper server (see the Technical Reference for installing from the
source tree). There is no specific source download for -max versions as
the code is the same as in normal versions.

Regards,
Iikka

On 17 Sep 2002, ch kalyan wrote:

 hello sir,,

 I have downloaded Beta version of Mysql 4.0.3

 I didnt find any source code in it..

 Will u please inform me how can i get source code in

 it

 Thanking u...

 Kalyan
 __
 Give your Company an email address like
 ravi @ ravi-exports.com.  Sign up for Rediffmail Pro today!
 Know more. http://www.rediffmailpro.com/signup/


 -
 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


**
* Iikka Meriläinen   *
* E-mail: [EMAIL PROTECTED] *
* Vaala, Finland *
**


-
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: Re MySQL on Redhat 7.3

2002-09-17 Thread muriel et stephane


- Original Message -
From: Peter Goggin [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, September 17, 2002 3:55 PM
Subject: Re: Re MySQL on Redhat 7.3


 I have got the msql server running and now need to configure it. In
 particular I want to set it up to use innodb tables.  When I set up mysql
on
 win98 I used the mysql-max release which comes with  built in Innodb
support
 and provides sample my.cnf files with the instructions for setting up
Innodb
 table spaces.  I cannot find anything similar from the RedHat
installation.
 The rpms installed are:
 mysql-3.23.49-3
 mysql-devel-3.23.49-3
 mysql-client9-3.23.22-6
 mysql-server3.23.49-3

 On looking at the mysql site, it looks as though I need another rpm,
 mysql-max-3.23.49-3 which should be installed after the others. Is this
 correct and if so where can I down load it. (the current version is
3.23.52)

i may be wrong but i guess you shouldn't need mysqlmax... all you need is to
specify that you want innodb at the compile time. For this, you should get
the source and not the binaries when you untar your mysql tar.gz (by the
way, why not using the last one 3.23.52 ?), you'll find a file called
INSTALL-SOURCE in which you'll read :

* If you want to configure `mysqld' with some extra features that are
 NOT in the standard binary distributions.  Here is a list of the
 most common extra options that you may want to use:

* `--with-berkeley-db'

* `--with-innodb'

* `--with-raid'

* `--with-libwrap'

* `--with-named-z-lib  (This is done for some of the binaries)'

* `--with-debug[=full]'


Have fun ;-))

Stephane


-
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: HELP - MYSQL databases disappearing!

2002-09-17 Thread Brian . Duke

Is your win2k server networked? does it have multiple users? I would first
check the various profiles to ensure it was not moved to a different
profile. Next I would ask did the administrator install the server? if
another username installed the server even with admin rights that server is
now officially part and parcel of that user only. Next I would investigate
where the server was installed. There are a number of directories that are
auto deleted every time you reboot. Look for unusually large ~.tmp files.
Like ~exp0023.tmp or perhaps File00452.tmp. If the server crashes and a
program is up in memory windows has a nasty habit of spitting the file in
memory immediately to the disk without giving you more than a small hint
what the original name was. 

My suspicion is you won't find any of these. Here's a typical scenario...
The server is set-up with a cleaning scheduler. Every night at midnight the
system runs a virus check, a scandisk and a defrag then empties the temp
files and reboots. The Mysql program is running at the same time. Mysql is
using a section of memory that is also used by defrag. Microsoft sometimes
lets programs share memory space but some programs (virus checkers and excel
are the worst) fail to give the memory back. A good midnight query is run.
It crashes. The program is dropped into the Temp bin as ~ql883.tmp the
server runs the cleanup process and finds a huge tmp file it cannot put in
the trash bin because of it's size (mysql server + query + tables  trashbin
size) therefore for your convenience Microsoft auto deletes the file. Then
reboots. 

You might get a warning that the server cannot be found but that would be
it. 

-Original Message-
From: Mike Taffi [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 16, 2002 1:21 PM
To: [EMAIL PROTECTED]
Subject: HELP - MYSQL databases disappearing!
Importance: High


Does anyone know why a MYSQL database would just disappear and how I might
prevent it from happening in the future?  I run it on win2k advanced server.

Much obliged,

Mike Taffi




-
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




Unable to add index

2002-09-17 Thread Mike Lucente

Hello,

I cannot add an index to one of my tables. I get the following message:

mysql alter table devlog add index (dt_status);
ERROR 1030: Got error 127 from table handler

I've run 'myisamchk -o table' on the table in question.

What should I try next?

Version: Server version  3.23.29a-gamma
OS: RedHat Linux 7.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




RE: Replication, unable to connect.

2002-09-17 Thread Michael Komitee

Nod, the passwords are correct, I was attempting to hide my temporary bad choice of a 
password, but did so poorly which you spotted.

The problem indeed was the master.info file. When I was originally setting this up I 
had accidentally set the my.cnf file on the slave to look for a remote port of 3303. I 
fixed that in the my.cnf file but it never propagated to the master.info file, 
unbeknownst to me. When I grabbed all the bin logs from the master and went to 
configure the master.info file to point to the right bin log, I noticed the error, 
changed it, and was able to begin replication.

I was then getting the common error of a 30 second net_read_timeout being used instead 
of the 1 hour slave_read_timeout causing messages reguarding an inability to read a 
packet when the connection timed out due to inactivity of the database. 

I fixed that by changing the net_read_timeout to 3600 from 30 which is what was 
reccomended in other threads. I am however unconvinced that this fixed the problem 
with the problem reading packets, logically this shows me that the system simply times 
out less often, and after an hour of inactivity the same error will occur. --have you 
or anyone else any other idea of how to actually fix the problem? --is upping the 
net_read_timeout a valid solution, or will it effect other things?

Thanks in advance, and good eye on spotting the mix-matched passwords.

-Original Message-
From: Jeremy Zawodny [mailto:[EMAIL PROTECTED]]
Sent: Monday, September 16, 2002 8:22 PM
To: Michael Komitee
Cc: [EMAIL PROTECTED]
Subject: Re: Replication, unable to connect.


On Mon, Sep 16, 2002 at 12:51:27PM -0400, Michael Komitee wrote:
 First a lil info, I'm trying to have a mysql slave server (10.0.0.2)
 connect to a mysql master server (10.0.0.1) for replication using a
 replication account named replication, with a password password. The
 servers are running on port 3306 on both machines.
 
 The slave's my.cnf file has the following information (whereas it deals
 with replication)
 [client]
 port= 3306
 socket  = /dir/to/mysql.sock
 [mysqld]
 server-id   = 2
 master-host=10.103.1.40
 master-user=replicate
 master-password=replicate
 master-port=3306
 master-connect-retry=60
 port= 3306
 socket  = /dir/to/mysql.sock
 skip-locking
 *snip
 
 When I attempt to start the server I get an error, the output is as
 follows:
 
 # mysqld 
 020916 11:28:51  InnoDB: Started
 mysqld: ready for connections
 020916 11:28:51  Slave thread: error connecting to master: Can't connect
 to MySQL server on '10.0.0.1' (111) (107), retry in 60 sec
 
 --it then continues to attempt to start the server every 60 seconds, but
 fails with the same error.

Well, the config file above doesn't match what you've told us so far.
One says the user is replicate while the other says replication.
Which is right?

 This first lead me to believe I had a problem with either the
 replication account, or general connectivity between the servers, so I
 attempted to connect to the master from the slave using the mysql client
 software.

Wise move.

 # mysql -h 10.0.0.1 -u replicate -p
 Enter password:
 Welcome to the MySQL monitor.  Commands end with ; or \g.
 Your MySQL connection id is 7 to server version: 3.23.51-log
 
 Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
 
 mysql
 
 --it works, so connectivity is not an issue, nor is the replicate
 account an issue, yet for some reason the mysql slave cannot contact the
 master.
 I'm missing something, but dont know what it is. Any ideas?

Is there a master.info file on the slave yet?  If so, does it contain
the wrong info?  (I suspect not, but it's worth checking.)

Do you see anything in the error log on the master?  Does the
replication account have the right privileges?

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

MySQL 3.23.51: up 41 days, processed 857,222,887 queries (238/sec. avg)

-
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: Is there a find_first in MySQL

2002-09-17 Thread Brent Baisley

You may be only expecting one and only one row, but you should always 
check if more than one row was retrieved for whatever reason. If more 
than one row was retrieved, something went wrong and you should code 
accordingly.
That said, you are interested in the LIMIT clause that someone else on 
the list already mentioned. Although I would set a LIMIT 2, which would 
allow you to check if more than one row was retrieved.
I only use LIMIT 1 when I am deleting and I only expect to be deleting 
only one record. That way a coding error won't suddenly delete the whole 
database.

On Sunday, September 15, 2002, at 09:08 PM, Tim Johnson wrote:

 However, since I'm just retrieving  one and only one row, is
 there a query (like find-first) that would be more efficient?

--
Brent Baisley
Systems Architect
Landover Associates, Inc.
Search  Advisory Services for Advanced Technology Environments
p: 212.759.6400/800.759.0577


-
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 can not install the benchmark module for SQL

2002-09-17 Thread Egor Egorov

root,
Saturday, September 14, 2002, 9:55:54 AM, you wrote:

Description:
r I want to install MySQL-bench-3.23.52.1.i386.rpm with KDE RPM
r I get as answer: MySQL-DBI-perl-bin needed.
r I already had downloaded and installed this module:
r  Mysql-DBI-perl-bin-1.1825-1.i386,rpm
r I repeated(changed name) with MySQL-DBI-perl-bin-1.1825-1.i386.rpm
r Same result.
r What do I do wrong?

Install MySQL-bench-3.23.52.1.i386.rpm with --nodeps option.



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Egor Egorov
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.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




re: Problom with creating database

2002-09-17 Thread Egor Egorov

rdkurth,
Tuesday, September 17, 2002, 9:43:37 AM, you wrote:

rasdn I have a brand new install of mysql . I have set every thing up just
rasdn like I have on many Linux server but this one I am getting an error
rasdn when I try to create a database from the Command line from and PHP
rasdn script or from phpMyAdmin. Could somebody tell me what this error
rasdn is and how I can fix it. I have un-installed and re installed mysql at
rasdn least 3 times and I can not get it to work.

rasdn 1006: Can't create database 'control'. (errno: 122)

$ perror 122
Error code 122:  Disk quota exceeded



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Egor Egorov
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.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




re: A simple error about mysql

2002-09-17 Thread Victoria Reznichenko

Roger,
Tuesday, September 17, 2002, 11:57:36 AM, you wrote:

RS i have downloaded a mysql 3.23.52 server and client linux rpm package.
RS i installed them on rh7.2

RS everything is ok.

RS and the mysqld daemon has also been started.

RS but when i try to change the root password using the folloing command:

RS /usr/bin/mysqladmin -u root password 'new-password'

RS there is an error :

RS ERROR 1045: Access denied for user: 'root@localhost' (Using password: NO)


RS i can't also using root account to login mysql

RS mysql -uroot
RS ERROR 1045: Access denied for user: 'root@localhost' (Using password: NO)

RS when i login like mysql 

RS i can login,but i just can use test database, 

RS what had happended?  how can i resolve this problem?

Roger, did you have MySQL server installed before? If so, you should
use the old root password. If you don't remember a password you can reset
it according to the following instruction:
  http://www.mysql.com/doc/en/Resetting_permissions.html


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.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




re: Mysql doesn't use datetime index?

2002-09-17 Thread Egor Egorov

sufcrusher,
Monday, September 16, 2002, 11:28:37 PM, you wrote:

s I have this weird problem, any help is much appreciated. I tried a lot of
s things and searched in the documentation, etc. but haven't found a solution
s yet.

s I have a table 'LogSessions' with a field 'dDateCreation' (datetime type),
s which has a normal index on it. A simple query like the following uses the
s index just fine:

s SELECT COUNT(*)
s FROM LogSessions
s WHERE LogSessions.dDateCreation = '2001-01-01 00:00:00' AND
s LogSessions.dDateCreation = '2001-06-30 23:59:59'

s However, as soon as I add a JOIN it stops using the index (3.5+ million
s records), I don't understand why.

s SELECT COUNT(*)
s FROM LogSessions
s  INNER JOIN Sessions ON LogSessions.iSessionID=Sessions.ID
s WHERE LogSessions.dDateCreation = '2001-01-01 00:00:00' AND
s LogSessions.dDateCreation = '2001-06-30 23:59:59'

s An EXPLAIN says this:

s tabletypepossible_keyskeykey_lenref rowsExtra
s LogSessions ALL  IDX_LogSessions_dDateCreation,IDX_LogSessions_iSessionID
s 3698297 where used
s Sessions  eq_ref  PRIMARY PRIMARY 4 LogSessions.iSessionID 1 Using index

s It reports the two possible_keys but neither is actually used (key is
s empty).

s Another test I did is use this WHERE clause (equal instead of
s greater-than/smaller-than):
s WHERE LogSessions.dDateCreation = '2001-01-01 00:00:00'

s Now the index is used again (even with the JOIN), but of course this is not
s what I need.

In some cases MySQL doesn't use indexes. How many rows there are in your table? I see 
in the first 
SELECT MySQL examines 3698297 rows. Is it less than 30% of the rows in the table?

  http://www.mysql.com/doc/en/MySQL_indexes.html



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Egor Egorov
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.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




re: log file...

2002-09-17 Thread Victoria Reznichenko

antispam,
Monday, September 16, 2002, 11:25:31 PM, you wrote:

aafdn   my log file (hostname.log) was soo large and i just deleted it(back up) and 
created a new file called hostname.log but mysql does not stores anything in the log 
file.. (i did mysqladmin
aafdn log-flush and server stop and start ) does not work.. it is not storing the 
log.. 

Start mysqld with --log option:
  http://www.mysql.com/doc/en/Query_log.html


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.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




re: search question

2002-09-17 Thread Egor Egorov

Meltem,
Tuesday, September 17, 2002, 11:33:56 AM, you wrote:

 Is there any other efficient way (--except using LIKE)of searching a
MD keyword
 in mysql ...

REGEXP, full-text search depends on what you need. Why don't you like
'LIKE'?
http://www.mysql.com/doc/en/Pattern_matching.html
http://www.mysql.com/doc/en/String_comparison_functions.html
http://www.mysql.com/doc/en/Fulltext_Search.html



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Egor Egorov
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.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




re: Delete syntax

2002-09-17 Thread Victoria Reznichenko

smudholkar,
Tuesday, September 17, 2002, 12:26:05 AM, you wrote:

saadc I am trying to write a delete query that will remove 
saadc records from one table based on information from 
saadc another table. In this example, there is a table called 
saadc accounting which contains two fields: username and 
saadc sessiontime and another table called users with two 
saadc fields: username and password. I would like records to 
saadc be deleted from the users table if the session time in 
saadc the accounting table exceeds a certain value, say 1000. 
saadc I have written the following statement:

saadc delete from users where accounting.username = 
saadc users.username and accounting.sessiontime  1000;

saadc The statement fails to execute  with the following 
saadc error: “Unknown table ‘accounting’ in where clause” and 
saadc I can’t figure out why. Your help is greatly 
saadc appreciated, thanks in advance!

Because you don't specify table 'accounting' in the FROM clause. take
a look at correct syntax for multi-table delete:
http://www.mysql.com/doc/en/DELETE.html


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.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




re: mysql4.0.3-beta with delphi5.0

2002-09-17 Thread Victoria Reznichenko

kayamboo,
Tuesday, September 17, 2002, 9:43:07 AM, you wrote:

k Is there anyone using mysql with delphi5.0
k I will be very thankful to get some tips to connect to  a remote server
k running mysql4.0.3-beta using delphi5.0 odbc dsn.
k I am able to connect with a local server but can't with a remote server.
k I can't find any help in the delphi sites.

k Any tips or suggestion urls will be greatly appreciated

Did you get any error? If so, what error message did you receive?
Check that user has permissions to connect from remote host. Is your
server behind a firewall?


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.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




re: Timestamp issue in mysql

2002-09-17 Thread Victoria Reznichenko

Prafulla,
Tuesday, September 17, 2002, 2:12:58 PM, you wrote:

PG Following is the description of the problem being faced.

PG Problem:
PG The first timestamp column in a table is set to current date-time value as soon as 
we update one or more columns in the table.

It's a normal behaviour of TIMESTAMP column:
 http://www.mysql.com/doc/en/DATETIME.html


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.net http://www.ensita.net/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Victoria Reznichenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.net
   ___/   www.mysql.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




RE: Unable to add index

2002-09-17 Thread Victor Pendleton

Mike,
Erro 127 means that the table is marked as crashed. You should run a
check and repair if necessary.
Error code 127:  Unknown error
127 = Record-file is crashed

I hope this helps.



-Original Message-
From: Mike Lucente [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, September 17, 2002 9:00 AM
To: [EMAIL PROTECTED]
Subject: Unable to add index


Hello,

I cannot add an index to one of my tables. I get the following message:

mysql alter table devlog add index (dt_status);
ERROR 1030: Got error 127 from table handler

I've run 'myisamchk -o table' on the table in question.

What should I try next?

Version: Server version  3.23.29a-gamma
OS: RedHat Linux 7.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

-
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: Win2000 error message when Starting mysql

2002-09-17 Thread Iikka Meriläinen

Hello,

This error doesn't give any information on what is exactly wrong with
MySQL. See mysql\data\mysql.err or mysql\data\yourhostname.err logs for
more information. Also check your my.cnf.

Regards,
Iikka

On Tue, 17 Sep 2002, Chris Stanley wrote:

 When I try to start Mysql service under services on a Win2000 machine I get
 the following error message.
  'Could not Start the MySql service on local computer.
 Error 1067: The process terminated unexpectedly'

 I am new to MySql so any help given will be much appreciated.

 Thankyou in advance

 Chris Stanley




 -
 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


**
* Iikka Meriläinen   *
* E-mail: [EMAIL PROTECTED] *
* Vaala, Finland *
**


-
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 doesn't use datetime index?

2002-09-17 Thread Jannes Faber

Thanks for your reply!

I had read about the 30% too, however in the SELECT query without the INNER
JOIN the EXPLAIN result is this:

table type possible_keys key key_len ref rows Extra
LogSessions range IDX_LogSessions_dDateCreation
IDX_LogSessions_dDateCreation 8  812548 where used; Using index

800,000 / 3,600,000  30%

Also (I'm not an expert on the details) I imagine an index on a datetime
field as a sorted list or tree. So I assume specifying boundaries in my
WHERE clause ( LogSessions.dDateCreation = '2001-01-01 00:00:00' AND
LogSessions.dDateCreation = '2001-06-30 23:59:59' ) should drastically
reduce the number of records (without much overhead) that need to be
checked/joined, no matter if it results in 10%, 30% or 50% ?

In the meantime, I did find out that it's not the JOIN that causes the
problem, if I add another WHERE clause, it also stops using the index. In
fact this seems even more weird to me because the extra field (iActionType)
I check now _also_ has an index of it's own. For honesty's sake I should add
that this last index is probably not really effective because only '1' and
'2' are valid values for iActionType, the majority however are 1, so I'd say
that's a lot of records that can be skipped.

 WHERE LogSessions.dDateCreation = '2001-01-01 00:00:00' AND
 LogSessions.dDateCreation = '2001-06-30 23:59:59' AND
LogSessions.iActionType=2

BTW: I also tried using 'USE INDEX (...)' and 'IGNORE INDEX (...)' stuff,
doesn't help anything though.

Hmm... I just tried to adjust the dates to get the results over a smaller
period (2 months instead of half a year): then it starts using the index
again.The flip-over point seems to be around 600,000 records, about 20%.
I'll go do some timings to see if it's really slower, maybe it was just my
impression.

Thanks again!
Jannes Faber

- Original Message -
From: Egor Egorov [EMAIL PROTECTED]
Sent: Tuesday, September 17, 2002 4:10 PM
Subject: re: Mysql doesn't use datetime index?


 sufcrusher,
 Monday, September 16, 2002, 11:28:37 PM, you wrote:

 s I have a table 'LogSessions' with a field 'dDateCreation' (datetime
type),
 s which has a normal index on it. A simple query like the following uses
the
 s index just fine:

 s SELECT COUNT(*)
 s FROM LogSessions
 s WHERE LogSessions.dDateCreation = '2001-01-01 00:00:00' AND
 s LogSessions.dDateCreation = '2001-06-30 23:59:59'

 s However, as soon as I add a JOIN it stops using the index (3.5+ million
 s records), I don't understand why.

 s SELECT COUNT(*)
 s FROM LogSessions
 s  INNER JOIN Sessions ON LogSessions.iSessionID=Sessions.ID
 s WHERE LogSessions.dDateCreation = '2001-01-01 00:00:00' AND
 s LogSessions.dDateCreation = '2001-06-30 23:59:59'

 s An EXPLAIN says this:

 s tabletypepossible_keyskeykey_lenref rowsExtra
 s LogSessions ALL
IDX_LogSessions_dDateCreation,IDX_LogSessions_iSessionID
 s 3698297 where used
 s Sessions  eq_ref  PRIMARY PRIMARY 4 LogSessions.iSessionID 1 Using
index

 s It reports the two possible_keys but neither is actually used (key is
 s empty).

 s Another test I did is use this WHERE clause (equal instead of
 s greater-than/smaller-than):
 s WHERE LogSessions.dDateCreation = '2001-01-01 00:00:00'

 s Now the index is used again (even with the JOIN), but of course this is
not
 s what I need.

 In some cases MySQL doesn't use indexes. How many rows there are in your
table? I see in the first
 SELECT MySQL examines 3698297 rows. Is it less than 30% of the rows in the
table?

   http://www.mysql.com/doc/en/MySQL_indexes.html




-
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




Win2000 error message when Starting mysql

2002-09-17 Thread Chris Stanley

When I try to start Mysql service under services on a Win2000 machine I get
the following error message.
 'Could not Start the MySql service on local computer.
Error 1067: The process terminated unexpectedly'

I am new to MySql so any help given will be much appreciated.

Thankyou in advance

Chris Stanley




-
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: Unable to add index

2002-09-17 Thread Mike Lucente

Isn't that what 'myisamchk -o' does?

On Tue, 17 Sep 2002, Victor Pendleton wrote:

 Mike,
   Erro 127 means that the table is marked as crashed. You should run a
 check and repair if necessary.
   Error code 127:  Unknown error
   127 = Record-file is crashed
 
 I hope this helps.
 
 
 
 -Original Message-
 From: Mike Lucente [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 17, 2002 9:00 AM
 To: [EMAIL PROTECTED]
 Subject: Unable to add index
 
 
 Hello,
 
 I cannot add an index to one of my tables. I get the following message:
 
 mysql alter table devlog add index (dt_status);
 ERROR 1030: Got error 127 from table handler
 
 I've run 'myisamchk -o table' on the table in question.
 
 What should I try next?
 
 Version: Server version  3.23.29a-gamma
 OS: RedHat Linux 7.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
 
 -
 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
 

-- 
Mike Lucente
CTO
[EMAIL PROTECTED]
561-218-5527


-
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




optimizer bug in selecting fields that don´t belong to the index used by mysql/innodb

2002-09-17 Thread rafarife

 Description:
 Heikki,

1) There is only one record with 'GARCIA MANCILLA,S.L'.
2) Mysql reported 53 scanned rows when I ran your mock-up query on your mock-up 
table. This is ok.
3) I'm using mysql.exe client (sometimes I use front-end) and i don´t think it 
removes the LIMIT 50 
   from my query.
4) I'm using mysqld-max-nt 4.0.3 beta.

I have sent to pub/mysql/secret  the table clientes (clientes.txt) and the my.ini 
file
in the compressed file named clientes.zip.

I tell you my test.

a) I ran the following query:
Select Cod,Nom,Nif,Nombre_comercial from Clientes Where (Nom = 'a2618' And 
Cod'059336') 
Or Nom'a2618' Order by Nom ASC, Cod ASC Limit 50;

Time:0.08 secs.
Handler_read_next: 1850 
  
(You can verify it through the file clientes.txt I sent)

b) I changed the table type to MyIsam, and I ran the above query:
Select Cod,Nom,Nif,Nombre_comercial from Clientes Where (Nom = 'a2618' And 
Cod'059336') 
Or Nom'a2618' Order by Nom ASC, Cod ASC Limit 50;

Time:0.00 secs.
Handler_read_next: 49

So, I have no problems with your mock-up table because (I think) it has not too 
many fields.
Also, in my real table, the query is only slow with Innodb table handler. It's 
fast with MyIsam
table handler.

I would like you can guess what the problem is and I thank you for your attention. 

thanks in advance,
Rafa.   

How-To-Repeat:
Select Cod,Nom,Nif,Nombre_comercial from Clientes Where (Nom = 'a2618' And 
Cod'059336') 
Or Nom'a2618' Order by Nom ASC, Cod ASC Limit 50;

Fix:
-

Synopsis:optimizer bug in selecting fields that don´t belong to the index used by 
mysql/innodb

Submitter-Id:   submitter ID
Originator: Rafa
Organization:   Pecomark
MySQL support:  none
Severity:   non-critical
Priority:   medium
Category:   mysqld-max-nt
Class:  sw-bug
Release:mysqld 4.0.3 beta(InnoDB)

Exectutable:   mysqld-max-nt
Environment:   Pentium III-MMX, 500 MHZ, 540 MB
System:Windows 2000
Compiler:  -
Architecture:  i


__
The NEW Netscape 7.0 browser is now available. Upgrade now! 
http://channels.netscape.com/ns/browsers/download.jsp 

Get your own FREE, personal Netscape Mail account today at http://webmail.netscape.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




mysqlbug

2002-09-17 Thread Winnie Kwok

after install mysql

[root@localhost mysql]./scripts/mysql_install_db
bash:./scripts/mysql_install_db:no such file or directory

Is the files not install ?

_
MSN Photos is the easiest way to share and print your photos: 
http://photos.msn.com/support/worldwide.aspx


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

2002-09-17 Thread Iikka Meriläinen

Hello,

Check your working directory (type pwd) and check if the scripts directory
exists at all (type ls).

What version did you install and on what operating system? Was it a binary
or a source release?

Regards,
Iikka

On Tue, 17 Sep 2002, Winnie Kwok wrote:

 after install mysql

 [root@localhost mysql]./scripts/mysql_install_db
 bash:./scripts/mysql_install_db:no such file or directory

 Is the files not install ?

 _
 MSN Photos is the easiest way to share and print your photos:
 http://photos.msn.com/support/worldwide.aspx


 -
 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


**
* Iikka Meriläinen   *
* E-mail: [EMAIL PROTECTED] *
* Vaala, Finland *
**


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

2002-09-17 Thread Paul DuBois

At 16:45 + 9/17/02, Winnie Kwok wrote:
after install mysql

[root@localhost mysql]./scripts/mysql_install_db
bash:./scripts/mysql_install_db:no such file or directory

Is the files not install ?

If you installed a binary distribution, look in the bin directory
where mysql and the other client programs are installed.

-
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




Someone has to know something on MySQLGUI?? - PLZ HLP!

2002-09-17 Thread David Kramer

Can anyone point me in the direction of some good doc on MYSQLGUI for Win2K?
Looking for Install/Setup notes..  Also is the Flash Light Tool Kit needed
to run the GUI?

Thanks,

DK

David Kramer
Software Developer
Reflect.com
Direct: 415.369.4856
Cell: 650.302.7889


-
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




External files w/ MySQL ???

2002-09-17 Thread Batman, Brad

Hello...

You'll have to excuse my ignorance, I'm new to MySQL and I've been hunting
online for hours yesterday and couldn't find the answer.  Maybe you out
there can help.  I'm wondering if it's possible to upload external documents
ie: (word, pdf's,etc) into a MySQL database?  We've been able to get this to
work w/ Cold Fusion and Access, but I'm trying to do it with PHP and MySQL
and I'm coming up short.

Thank you for any info you have.

Brad  


DISCLAIMER: The information contained in this transmission may be legally
privileged and/or confidential information. Any dissemination, distribution
or copying of this transmission by anyone other than the intended recipient
is strictly prohibited. If you receive this in error, please inform the
sender immediately and remove any record of this message.



-
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




How to overwrite the /var/lib/mysql path during installation?

2002-09-17 Thread Tam,Aaron

I'm installing the mysql-max-3.23.52-pc-linux-gnu-i686 version.  But I don't
have the root permission, and don't have the /var/lib/ access permission.
And I got the following error when I ran the ./configure commend.  Do anyone
know how to change the /var/lib/mysql directory to something else?

Thanks in advance.

To help you a bit, I am now going to create the needed MySQL databases
and start the MySQL server for you.  If you run into any trouble, please
consult the MySQL manual, that you can find in the Docs directory.

mkdir: cannot create directory `/var/lib/mysql/mysql': Permission denied
chmod: getting attributes of `/var/lib/mysql/mysql': No such file or
directory
mkdir: cannot create directory `/var/lib/mysql/test': Permission denied
chmod: getting attributes of `/var/lib/mysql/test': No such file or
directory

-
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




aggregate functions producing bad data

2002-09-17 Thread Richard Unger

My query:

SELECT 
count(id), 
count( IF(call_end - call_start  5, id, NULL) ), 
count( IF(call_end - call_start = 5, id, NULL) )
FROM 
t_calllog_calls;

My result:

1994
1956
35

However, 1956 + 35 != 1994.

Running MySQL 3.23.49-nt

Cheers,
Rich

-
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: aggregate functions producing bad data

2002-09-17 Thread Brian Reichert

On Tue, Sep 17, 2002 at 11:59:42AM -0700, Richard Unger wrote:
 My query:
 
 SELECT 
   count(id), 
   count( IF(call_end - call_start  5, id, NULL) ), 
   count( IF(call_end - call_start = 5, id, NULL) )
 FROM 
   t_calllog_calls;
 
 My result:
 
 1994
 1956
 35
 
 However, 1956 + 35 != 1994.
 
 Running MySQL 3.23.49-nt

One thing I'd check:  what happens if t_calllog_calls.id is NULL?

 Cheers,
 Rich

-- 
Brian 'you Bastard' Reichert[EMAIL PROTECTED]
37 Crystal Ave. #303Daytime number: (603) 434-6842
Derry NH 03038-1713 USA Intel architecture: the left-hand path

-
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: aggregate functions producing bad data

2002-09-17 Thread Gelu Gogancea

Hi,
I think you should try to use 0 instead of NULL

Regards,

Gelu
_
G.NET SOFTWARE COMPANY

Permanent e-mail address : [EMAIL PROTECTED]
  [EMAIL PROTECTED]
- Original Message - 
From: Richard Unger [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, September 17, 2002 9:59 PM
Subject: aggregate functions producing bad data


My query:

SELECT 
count(id), 
count( IF(call_end - call_start  5, id, NULL) ), 
count( IF(call_end - call_start = 5, id, NULL) )
FROM 
t_calllog_calls;

My result:

1994
1956
35

However, 1956 + 35 != 1994.

Running MySQL 3.23.49-nt

Cheers,
Rich

-
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: aggregate functions producing bad data

2002-09-17 Thread Richard Unger

I _thought_ it was the fault of the aggregate function, but now I'm really confused!  
When I produce them as 3 separate queries, I still get numbers that don't add up:

mysql select count(id) from t_calllog_calls;
+---+
| count(id) |
+---+
|  1994 |
+---+
1 row in set (0.00 sec)

mysql select count(id) from t_calllog_calls where call_end - call_start  5;
+---+
| count(id) |
+---+
|  1956 |
+---+
1 row in set (0.00 sec)

mysql select count(id) from t_calllog_calls where call_end - call_start = 5;
+---+
| count(id) |
+---+
|35 |
+---+

-Original Message-
From: Richard Unger 
Sent: Tuesday, September 17, 2002 12:00 PM
To: '[EMAIL PROTECTED]'
Subject: aggregate functions producing bad data


My query:

SELECT 
count(id), 
count( IF(call_end - call_start  5, id, NULL) ), 
count( IF(call_end - call_start = 5, id, NULL) )
FROM 
t_calllog_calls;

My result:

1994
1956
35

However, 1956 + 35 != 1994.

Running MySQL 3.23.49-nt

Cheers,
Rich

-
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: aggregate functions producing bad data

2002-09-17 Thread Richard Unger

That would just give me 1994 for all 3 columns of output.  What I want to know is how 
many calls were longer than 5 seconds, how many were = 5 seconds, and the total 
number of calls.

Cheers,
Rich


 -Original Message-
 From: Gelu Gogancea [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 17, 2002 12:08 PM
 To: Richard Unger; [EMAIL PROTECTED]
 Subject: Re: aggregate functions producing bad data
 
 
 Hi,
 I think you should try to use 0 instead of NULL
 
 Regards,
 
 Gelu
 _
 G.NET SOFTWARE COMPANY
 
 Permanent e-mail address : [EMAIL PROTECTED]
   [EMAIL PROTECTED]
 - Original Message - 
 From: Richard Unger [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Tuesday, September 17, 2002 9:59 PM
 Subject: aggregate functions producing bad data
 
 
 My query:
 
 SELECT 
 count(id), 
 count( IF(call_end - call_start  5, id, NULL) ), 
 count( IF(call_end - call_start = 5, id, NULL) )
 FROM 
 t_calllog_calls;
 
 My result:
 
 1994
 1956
 35
 
 However, 1956 + 35 != 1994.
 
 Running MySQL 3.23.49-nt
 
 Cheers,
 Rich
 
 -
 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: aggregate functions producing bad data

2002-09-17 Thread Richard Unger

id is the primary key.  There are no entries in the DB where id=NULL

Cheers,
Rich

 -Original Message-
 From: Brian Reichert [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 17, 2002 12:16 PM
 To: Richard Unger
 Cc: [EMAIL PROTECTED]
 Subject: Re: aggregate functions producing bad data
 
 
 On Tue, Sep 17, 2002 at 11:59:42AM -0700, Richard Unger wrote:
  My query:
  
  SELECT 
  count(id), 
  count( IF(call_end - call_start  5, id, NULL) ), 
  count( IF(call_end - call_start = 5, id, NULL) )
  FROM 
  t_calllog_calls;
  
  My result:
  
  1994
  1956
  35
  
  However, 1956 + 35 != 1994.
  
  Running MySQL 3.23.49-nt
 
 One thing I'd check:  what happens if t_calllog_calls.id is NULL?
 
  Cheers,
  Rich
 
 -- 
 Brian 'you Bastard' Reichert  [EMAIL PROTECTED]
 37 Crystal Ave. #303  Daytime number: (603) 434-6842
 Derry NH 03038-1713 USA   Intel 
 architecture: the left-hand path
 

-
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: aggregate functions producing bad data

2002-09-17 Thread Dan Nelson

In the last episode (Sep 17), Brian Reichert said:
 On Tue, Sep 17, 2002 at 11:59:42AM -0700, Richard Unger wrote:
  My query:
  
  SELECT 
  count(id), 
  count( IF(call_end - call_start  5, id, NULL) ), 
  count( IF(call_end - call_start = 5, id, NULL) )
  FROM 
  t_calllog_calls;
  
  My result:
  
  1994
  1956
  35
  
  However, 1956 + 35 != 1994.
  
  Running MySQL 3.23.49-nt
 
 One thing I'd check:  what happens if t_calllog_calls.id is NULL?

Also check if call_end or call_start are NULL; that will cause both IFs
to fail.  Don't you love NULLs :)
 
-- 
Dan Nelson
[EMAIL PROTECTED]

-
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: aggregate functions producing bad data

2002-09-17 Thread mtoth

what does
  Select count(id) from t_calllog_calls where id IS NULL
give you?


On Tue, 17 Sep 2002, Richard Unger wrote:

 That would just give me 1994 for all 3 columns of output.  What I want to know is 
how many calls were longer than 5 seconds, how many were = 5 seconds, and the total 
number of calls.

 Cheers,
 Rich


  -Original Message-
  From: Gelu Gogancea [mailto:[EMAIL PROTECTED]]
  Sent: Tuesday, September 17, 2002 12:08 PM
  To: Richard Unger; [EMAIL PROTECTED]
  Subject: Re: aggregate functions producing bad data
 
 
  Hi,
  I think you should try to use 0 instead of NULL
 
  Regards,
 
  Gelu
  _
  G.NET SOFTWARE COMPANY
 
  Permanent e-mail address : [EMAIL PROTECTED]
[EMAIL PROTECTED]
  - Original Message -
  From: Richard Unger [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Sent: Tuesday, September 17, 2002 9:59 PM
  Subject: aggregate functions producing bad data
 
 
  My query:
 
  SELECT
  count(id),
  count( IF(call_end - call_start  5, id, NULL) ),
  count( IF(call_end - call_start = 5, id, NULL) )
  FROM
  t_calllog_calls;
 
  My result:
 
  1994
  1956
  35
 
  However, 1956 + 35 != 1994.
 
  Running MySQL 3.23.49-nt
 
  Cheers,
  Rich
 
  -
  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: aggregate functions producing bad data

2002-09-17 Thread Richard Unger

 -Original Message-
 From: Dan Nelson [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 17, 2002 12:31 PM
 To: Brian Reichert
 Cc: Richard Unger; [EMAIL PROTECTED]
 Subject: Re: aggregate functions producing bad data
 
 
 In the last episode (Sep 17), Brian Reichert said:
  On Tue, Sep 17, 2002 at 11:59:42AM -0700, Richard Unger wrote:
   My query:
   
   SELECT 
 count(id), 
 count( IF(call_end - call_start  5, id, NULL) ), 
 count( IF(call_end - call_start = 5, id, NULL) )
   FROM 
 t_calllog_calls;
   
   My result:
   
   1994
   1956
   35
   
   However, 1956 + 35 != 1994.
   
   Running MySQL 3.23.49-nt
  
  One thing I'd check:  what happens if t_calllog_calls.id is NULL?
 
 Also check if call_end or call_start are NULL; that will 
 cause both IFs
 to fail.  Don't you love NULLs :)
  

Ooh, good suggestion.  I hadn't thought of that!

...but no, none of the call_start or call_end fields are NULL.

Yeah, I love nulls :)

Cheers,
Rich

-
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: aggregate functions producing bad data

2002-09-17 Thread Richard Unger

mysql Select count(id) from t_calllog_calls where id IS NULL;
+---+
| count(id) |
+---+
| 0 |
+---+
1 row in set (0.00 sec)

 -Original Message-
 From: mtoth [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 17, 2002 12:39 PM
 To: Richard Unger
 Cc: [EMAIL PROTECTED]
 Subject: RE: aggregate functions producing bad data
 
 
 what does
   Select count(id) from t_calllog_calls where id IS NULL
 give you?
 
 
 On Tue, 17 Sep 2002, Richard Unger wrote:
 
  That would just give me 1994 for all 3 columns of output.  
 What I want to know is how many calls were longer than 5 
 seconds, how many were = 5 seconds, and the total number of calls.
 
  Cheers,
  Rich
 
 
   -Original Message-
   From: Gelu Gogancea [mailto:[EMAIL PROTECTED]]
   Sent: Tuesday, September 17, 2002 12:08 PM
   To: Richard Unger; [EMAIL PROTECTED]
   Subject: Re: aggregate functions producing bad data
  
  
   Hi,
   I think you should try to use 0 instead of NULL
  
   Regards,
  
   Gelu
   _
   G.NET SOFTWARE COMPANY
  
   Permanent e-mail address : [EMAIL PROTECTED]
 [EMAIL PROTECTED]
   - Original Message -
   From: Richard Unger [EMAIL PROTECTED]
   To: [EMAIL PROTECTED]
   Sent: Tuesday, September 17, 2002 9:59 PM
   Subject: aggregate functions producing bad data
  
  
   My query:
  
   SELECT
   count(id),
   count( IF(call_end - call_start  5, id, NULL) ),
   count( IF(call_end - call_start = 5, id, NULL) )
   FROM
   t_calllog_calls;
  
   My result:
  
   1994
   1956
   35
  
   However, 1956 + 35 != 1994.
  
   Running MySQL 3.23.49-nt
  
   Cheers,
   Rich
  
   
 -
   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: aggregate functions producing bad data

2002-09-17 Thread Jay

On my server the MySQL database decided to die on me.  So I killed it and
restarted and that didn't work.  So I just rebooted the machine.  Now I'm
getting this error below.

Invalid SQL: SELECT COUNT(*) AS messages FROM privatemessage WHERE userid=1
mysql error: Can't open file: 'privatemessage.MYD'. (errno: 145)

mysql error number: 1016

Anyone know what is going on?

Thanks.


-
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: aggregate functions producing bad data

2002-09-17 Thread Gelu Gogancea

Hi,
 One thing I'd check:  what happens if t_calllog_calls.id is NULL?
...is not count.

Regards,

Gelu
_
G.NET SOFTWARE COMPANY

Permanent e-mail address : [EMAIL PROTECTED]
  [EMAIL PROTECTED]
- Original Message -
From: Brian Reichert [EMAIL PROTECTED]
To: Richard Unger [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Tuesday, September 17, 2002 10:16 PM
Subject: Re: aggregate functions producing bad data


 On Tue, Sep 17, 2002 at 11:59:42AM -0700, Richard Unger wrote:
  My query:
 
  SELECT
  count(id),
  count( IF(call_end - call_start  5, id, NULL) ),
  count( IF(call_end - call_start = 5, id, NULL) )
  FROM
  t_calllog_calls;
 
  My result:
 
  1994
  1956
  35
 
  However, 1956 + 35 != 1994.
 
  Running MySQL 3.23.49-nt


  Cheers,
  Rich

 --
 Brian 'you Bastard' Reichert [EMAIL PROTECTED]
 37 Crystal Ave. #303 Daytime number: (603) 434-6842
 Derry NH 03038-1713 USA Intel architecture: the left-hand path

 -
 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: aggregate functions producing bad data

2002-09-17 Thread Gelu Gogancea

...or you can try :
 SELECT
 count(*),
 count( IF(call_end - call_start  5, id, NULL) ),
 count( IF(call_end - call_start = 5, id, NULL) )
 FROM
 t_calllog_calls;

Regards,

Gelu
_
G.NET SOFTWARE COMPANY

Permanent e-mail address : [EMAIL PROTECTED]
  [EMAIL PROTECTED]
- Original Message -
From: Brian Reichert [EMAIL PROTECTED]
To: Richard Unger [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Tuesday, September 17, 2002 10:16 PM
Subject: Re: aggregate functions producing bad data


 On Tue, Sep 17, 2002 at 11:59:42AM -0700, Richard Unger wrote:
  My query:
 
  SELECT
  count(id),
  count( IF(call_end - call_start  5, id, NULL) ),
  count( IF(call_end - call_start = 5, id, NULL) )
  FROM
  t_calllog_calls;
 
  My result:
 
  1994
  1956
  35
 
  However, 1956 + 35 != 1994.
 
  Running MySQL 3.23.49-nt

 One thing I'd check:  what happens if t_calllog_calls.id is NULL?

  Cheers,
  Rich

 --
 Brian 'you Bastard' Reichert [EMAIL PROTECTED]
 37 Crystal Ave. #303 Daytime number: (603) 434-6842
 Derry NH 03038-1713 USA Intel architecture: the left-hand path

 -
 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: Forcing a sort order in a join

2002-09-17 Thread Gerald Clark

Using DESC on an index only works with V 4.

Philip Smolen wrote:

I'm trying to make a query faster.  It seems simple, but I can't make it
work.

This is a common case for me:
SELECT *
FROM very_large_table
WHERE (simple_condition)
ORDER BY an_indexed_field DESC
LIMIT 5;
For simple queries this works as expected.  MySQL starts at the end of the




-
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




Moving from MS-SQL to MySQL

2002-09-17 Thread Patrick Fowler

Hello,

We are thing about moving from MS-SQL to MySQL.  We are in the very early
planning of creating a data warehouse.  Does anyone have any information
regarding the +/- of using MySQL vs MS-SQL.  The db will at most be 20gb
with about 100 users.

A few questions would be:
Is there a way to authenticate users without with their win2k login and not
have to type in the login/passwd again?
Is MySQL as flexable as MS-SQL with scheduling task and process.

DB = MySQL
OS = RH Linux 7.3
HW = New IBM xSeries hardware.

Thanks for any information you may provide.

DBA / Unix Administrator
Patrick Fowler
Wynit, Inc.
6847 Ellicott Drive
East Syracuse, NY 13057
V (315) 437-7617 x2172
F (315) 437-0432
 


-
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




'gmake install' with DESTDIR puts files in bad place

2002-09-17 Thread Mike Cuddy

Description:
When doing a 'gmake install' with DESTDIR= set, 'libs' directory 
is not installed properly

How-To-Repeat:
(build MySQL)
gmake DESTDIR=`pwd`/.install

Notice that a directory '.install..' gets created in the current 
directory.  

If a trailing slash is included with 'DESTDIR', then a 'libs' 
directory is created in the current directory.
The directory contains the following files:

libbtr.alibeval.a   liblock.a   libos.a librow.alibut.a
libbuf.alibfil.aliblog.alibpage.a   libsrv.a
libcom.alibfsp.alibmach.a   libpars.a   libsync.a
libdata.a   libfut.alibmem.alibque.alibthr.a
libdict.a   libha.a libmtr.alibread.a   libtrx.a
libdyn.alibibuf.a   libodbc.a   librem.alibusr.a

Fix:
The Makefile's in innobase/...  set the variable 'libsdir=' to 
'../libs'.  This breaks in the presence of DESTDIR.  As I'm not
sure  the correct install location of these libraries, I cannot
suggest a fix.

Submitter-Id:  
Originator:
Organization:
Ponte Communications, Inc.
MySQL support: none
Synopsis:  'gmake install' with DESTDIR puts innodb 'libs' in wrong place
Severity:  non-critical
Priority:  low
Category:  mysql
Class: sw-bug
Release:   mysql-4.0.3-beta (Source distribution)

Environment:

System: SunOS colossus 5.8 Generic_108528-01 sun4u sparc SUNW,Ultra-5_10
Architecture: sun4

(portions of report elided, they are not from the machine where the build
is taking place)

Some paths:  /usr/local/bin/perl /usr/local/bin/make /opt/sfw/bin/gmake 
/opt/sfw/bin/gcc /usr/ucb/cc

-
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: aggregate functions producing bad data

2002-09-17 Thread mtoth

Is call_end - call_start a integer, maybe the range is to big and it is
eval'd as NULL or false.  shrug.



On Tue, 17 Sep 2002, Gelu Gogancea wrote:

 Hi,
  One thing I'd check:  what happens if t_calllog_calls.id is NULL?
 ...is not count.

 Regards,

 Gelu
 _
 G.NET SOFTWARE COMPANY

 Permanent e-mail address : [EMAIL PROTECTED]
   [EMAIL PROTECTED]
 - Original Message -
 From: Brian Reichert [EMAIL PROTECTED]
 To: Richard Unger [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Sent: Tuesday, September 17, 2002 10:16 PM
 Subject: Re: aggregate functions producing bad data


  On Tue, Sep 17, 2002 at 11:59:42AM -0700, Richard Unger wrote:
   My query:
  
   SELECT
   count(id),
   count( IF(call_end - call_start  5, id, NULL) ),
   count( IF(call_end - call_start = 5, id, NULL) )
   FROM
   t_calllog_calls;
  
   My result:
  
   1994
   1956
   35
  
   However, 1956 + 35 != 1994.
  
   Running MySQL 3.23.49-nt
 
 
   Cheers,
   Rich
 
  --
  Brian 'you Bastard' Reichert [EMAIL PROTECTED]
  37 Crystal Ave. #303 Daytime number: (603) 434-6842
  Derry NH 03038-1713 USA Intel architecture: the left-hand path
 
  -
  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




FW: aggregate functions producing bad data

2002-09-17 Thread Richard Unger

MySQL -- to defeat the spam filter

-Original Message-
From: Richard Unger 
Sent: Tuesday, September 17, 2002 1:46 PM
To: 'Dan Nelson'
Cc: [EMAIL PROTECTED]
Subject: RE: aggregate functions producing bad data


Thanks, I figured it out.  It turns out there were some calls for which call_end IS 
NULL.  I had originally eliminated that possiblity because I mistakenly checked if 
call_end = NULL (instead of IS).

Thanks for pointing me in the right direction.

Cheers,
Rich

 -Original Message-
 From: Dan Nelson [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, September 17, 2002 1:13 PM
 To: Richard Unger
 Cc: [EMAIL PROTECTED]
 Subject: Re: aggregate functions producing bad data
 
 
 In the last episode (Sep 17), Richard Unger said:
  From: Dan Nelson [mailto:[EMAIL PROTECTED]]
   In the last episode (Sep 17), Brian Reichert said:
One thing I'd check:  what happens if 
 t_calllog_calls.id is NULL?
   
   Also check if call_end or call_start are NULL; that will 
   cause both IFs
   to fail.  Don't you love NULLs :)
  
  Ooh, good suggestion.  I hadn't thought of that!
  
  ...but no, none of the call_start or call_end fields are NULL.
 
 Next step is to do a REPAIR TABLE t_calllog_calls, in case 
 your index
 got damaged at some point.  The next step after that is to make a copy
 of your table, and remove records one by one until your total works,
 then find out what's special about the last record you removed.
 
 -- 
   Dan Nelson
   [EMAIL PROTECTED]
 

-
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: aggregate functions producing bad data

2002-09-17 Thread Benjamin Pflugmann

Hi.

Could you run the following query:

SELECTIF(call_end - call_start  5, id, NULL) AS long,
  IF(call_end - call_start = 5, id, NULL) AS short,
  COUNT(*)
FROM  t_calllog_calls
GROUP BY  long, short

Given that I have not made any mistake, that should list all rows
which do not behave as expected for whatever reason. From your
description, you expect there to be two rows:

longshort
  0 non-0
non-0 0

But you should get some additional row(s), which account for the
difference you observe. Once you know in which way the condition fails
(e.g. both comparisons resulting in NULL), you can search for these
rows:

SELECTIF(call_end - call_start  5, id, NULL) AS long,
  IF(call_end - call_start = 5, id, NULL) AS short,
  *
FROM  t_calllog_calls
HAVINGISNULL(short) AND ISNULL(long)

(of course you may have to change this accordingly).


One of may best bets would be that call_end and call_start are of some
data type for which your comparison results in NULL due to some
illegal value or because the comparison is not defined or whatever.

Please report any findings you get.

Regards,

Benjamin.


PS: People, please learn to quote. There is no reason to quote 60
lines of mail footers!


On Tue 2002-09-17 at 12:37:59 -0700, [EMAIL PROTECTED] wrote:
My query:
   
SELECT
count(id),
count( IF(call_end - call_start  5, id, NULL) ),
count( IF(call_end - call_start = 5, id, NULL) )
FROM
t_calllog_calls;
   
My result:
   
1994
1956
35
   
However, 1956 + 35 != 1994.
   
Running MySQL 3.23.49-nt
[...]

-- 
[EMAIL PROTECTED]

-
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: Unable to add index

2002-09-17 Thread Gerald Clark

Don't run myisamchk while the server is running.

Mike Lucente wrote:

Isn't that what 'myisamchk -o' does?

On Tue, 17 Sep 2002, Victor Pendleton wrote:

Mike,
  Erro 127 means that the table is marked as crashed. You should run a
check and repair if necessary.
  Error code 127:  Unknown error
  127 = Record-file is crashed

I hope this helps.



-Original Message-
From: Mike Lucente [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, September 17, 2002 9:00 AM
To: [EMAIL PROTECTED]
Subject: Unable to add index


Hello,

I cannot add an index to one of my tables. I get the following message:

mysql alter table devlog add index (dt_status);
ERROR 1030: Got error 127 from table handler

I've run 'myisamchk -o table' on the table in question.

What should I try next?

Version: Server version  3.23.29a-gamma
OS: RedHat Linux 7.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




Marketing materials ??

2002-09-17 Thread Yuri

Hi,

I may get in position to protect
my choice of MySQL being confronted
by completely non-technical
management. Management is likely
to argue in favor of MSSQL (nice GUI,
many people who know it, they are
used to it, you can do any project
on any DB, blah blah blah). All this
crap.

Anyone has web references to different
DB servers comparison (performance/feature-rich
/other...)? Marketing materials/diagrams/tables
that would be able to convince non-tech
guys that MySQL is superior to MSSQL?
Selling points (like ease of administration,
high performance, robustness of SQL language,
cross platform-nnes) ?

Any other considerations.

I mean I know by heart that MySQL is better
but management has totally different mindset.

So any such convincing information will
be GREATLY appreciated ))

Yuri.

-
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: Marketing materials ??

2002-09-17 Thread Heikki Tuuri



- Original Message - 
From: Yuri [EMAIL PROTECTED]
Newsgroups: mailing.database.mysql
Sent: Wednesday, September 18, 2002 12:37 AM
Subject: Marketing materials ??


 Hi,
 
 I may get in position to protect
 my choice of MySQL being confronted
 by completely non-technical
 management. Management is likely
 to argue in favor of MSSQL (nice GUI,
 many people who know it, they are
 used to it, you can do any project
 on any DB, blah blah blah). All this
 crap.
 
 Anyone has web references to different
 DB servers comparison (performance/feature-rich
 /other...)? Marketing materials/diagrams/tables
 that would be able to convince non-tech
 guys that MySQL is superior to MSSQL?
 Selling points (like ease of administration,
 high performance, robustness of SQL language,
 cross platform-nnes) ?


MySQL runs on Unix and Windows, MS SQL Server only on Windows.

These are the best references so far:

http://www.eweek.com/article2/0,3959,293,00.asp

http://www.eweek.com/slideshow/0,3018,sid=0s=1590a=23120,00.asp


 Any other considerations.
 
 I mean I know by heart that MySQL is better
 but management has totally different mindset.
 
 So any such convincing information will
 be GREATLY appreciated ))
 
 Yuri.

Best regards,

Heikki

sql 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




Japanese Characters in MySQL Win2k

2002-09-17 Thread Dawn Friedland

This is for anyone out there storing Japanese characters along with
English characters. I've searched everywhere for anything that has to do
with my particular situationwith no progress. I'm stuck. 

SUMMARY: 
The client recently requested that Japanese be stored in an otherwise
standard English (Latin) MySQL database. Whereas all rows in the table
used to be Latin only, now some rows store Latin and some store
Japanese. I do not mix English with Japanese in the same row. Upon
writing Japanese data to the database (web form - ASP - MyODBC), and
then viewing the record on a web page, I discover that random Japanese
characters are being 'morphed' into other, seemingly random, Japanese
characters, and very occasionally, 'morphed' into a Latin character (so
far just the letter t). With the exception of these few, random
characters, all the Japanese data looks fine *when displayed on a web
page*. This is a standard install of MySQL version 3.23.38-nt (on
Windows 2000 SP2) - support for Japanese characters is installed by
default, I assume. I also store Chinese and Korean characters in the
same table, and those character sets are diplayed without error. 

Question 1. If I were to pull the Japanese rows out and put them in a
separate table - what do I do to the table to 'configure' it as storing
sjis characters without setting the default character set to the entire
database?

Question 2. How do I view Japanese records in the command line *in
Japanese* to eliminate the possiblity that the culprit is somewhere
outside of MySQL, for example: Microsoft IIS or ASP or MyODBC?


DETAILS:
Environment: I have one computer running Windows 2000 Service Pack 2,
MySQL 3.23.38-nt, and the MySQL Driver for ODBC. Someone else installed
MySQL on the machine - I confidently assume they took the defaults and
did nothing in particular with configuration at install. The machine is
a dedicated webserver, serving up ASP pages which retreive data from the
MySQL database via MyODBC. 

Background: I've been successfully storing Latin characters in two
fields, title varchar(255) and body mediumtext. The recently added
Japanese content is stored in the same table as the English content. The
content is entered to the database using a web-based content publishing
tool: ASP pages with forms that submit to the MySQL database. The
database content is displayed to the web site using ASP which retrieves
from the database. As long as the client browser has proper language
pack installed, the Japanese characters 'seem' to display nicely. The
web pages for Japanese content uses Shift-JIS. I do not speak or read
Japanese. I do not need to search or order by Japanese character fields
(only date_modified or id, for example). 

Process for publishing Japanese content: I receive a MS Word document
with Japanese content. I copy and paste content into web form in
publishing tool. Web form submits data to database, creating a new
record. User browses to Japanese page on my web site and sees
database-driven Japanese content. 

Problem: Random Japanese characters are being 'morphed' into other,
seemingly random Japanese characters, and very occasionally, a Japanese
character will be 'morphed' into a Latin character. Once the content is
published, at first glance, everything looks ok (its all just Japanese
to me). However, if I do a character-by-character comparison between the
MS Word doc and the data driven web page, I will discover that, for
example, 5th, 12th, 134th, and 291st characters displayed on the web
page are *different* from what I pasted in the the publishing tool. Most
of these broken characters have been morphed to other Japanese
characters, and a few morph into Latin characters (so far only the
letter t). A Japanese speaking colleague confirmed that the web page
read exactly as the Word doc, with the exception of these random
'morphed' characters. 

Thank you so much for taking the time to read this. I appreciate any
input whatsoever. 

Sincerely, 
Dawn Friedland 
[EMAIL PROTECTED]

-
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




Japanese Charset

2002-09-17 Thread Dawn Friedland

This is for anyone out there storing Japanese characters along with
English characters. 

SUMMARY: 
The client recently requested that Japanese be stored in an otherwise
standard English (Latin) MySQL database. Whereas all rows in the table
used to be Latin only, now some rows store Latin and some store
Japanese. I do not mix English with Japanese in the same row. Upon
writing Japanese data to the database (web form - ASP - MyODBC), and
then viewing the record on a web page (Shift-Jis), I discover that
random Japanese characters are being 'morphed' into other, seemingly
random, Japanese characters, and very occasionally, 'morphed' into a
Latin character (so far just the letter t). With the exception of
these few, random characters, all the Japanese data looks fine *when
displayed on a web page*. This is a standard install of MySQL version
3.23.38-nt (on Windows 2000 SP2) - support for Japanese characters is
installed by default, I assume. I also store Chinese and Korean
characters in the same table, and those character sets are diplayed
without error. 

Question 1. If I were to pull the Japanese rows out and put them in a
separate table - what do I do to the table to 'configure' it as storing
sjis characters without setting the default character set to the entire
database?

Question 2. How do I view Japanese records in the command line *in
Japanese* to eliminate the possiblity that the culprit is somewhere
outside of MySQL, for example: Microsoft IIS or ASP or MyODBC?

Question 3. How do I tell which charset MySQL is using, euc-jis or
s-jis? 

Sincerely, 
Dawn Friedland 
[EMAIL PROTECTED]

-
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: Japanese Characters in MySQL Win2k

2002-09-17 Thread Shashank Tripathi

Storing JP and EN data in the same table has worked for me ever since I
started using MySQL. Unlike Oracle, you don't need any specific charset
configs (I may stand corrected). The idea is to use the correct
character encodings when you *display* the data after pulling it out. In
your case, I'd think Shift_JIS. 

You mention displaying on the command line...u mean DOS prompt? If not,
and if you meant some software, it shd be easy. If you meant DOS prompt,
I guess it depends on what the default language in your windows box is.
Do you have Japan set as your default locale and as the default language
(Regional Options in Control Panel)?  If so, the data shd display
correctly without any additional effort. 

You can store EUC, Shift, ISO2022, and for that matter, Chinese in the
same table in diff rows as well. During presentation time (display),
just display using the appropriate encoding and it shd be ok. 

Holler if you need more help.  

Cheers,
Shashank





-
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: Japanese Characters in MySQL Win2k

2002-09-17 Thread Dawn Friedland

Thank you Thank you. 

Are you running MySQL on Windows and using ASP on the web server?  

When I display the data after pulling it out, I use Shift_Jis. 

Yes, I mean the DOS prompt. My default language is English. I fear
changing my locale because I wouldn't be able to change it back without
a deepfry (I can't read Japanese!)  

-Original Message-
From: Shashank Tripathi [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, September 17, 2002 3:36 PM
To: Dawn Friedland; [EMAIL PROTECTED]
Subject: RE: Japanese Characters in MySQL  Win2k


Storing JP and EN data in the same table has worked for me ever since I
started using MySQL. Unlike Oracle, you don't need any specific charset
configs (I may stand corrected). The idea is to use the correct
character encodings when you *display* the data after pulling it out. In
your case, I'd think Shift_JIS. 

You mention displaying on the command line...u mean DOS prompt? If not,
and if you meant some software, it shd be easy. If you meant DOS prompt,
I guess it depends on what the default language in your windows box is.
Do you have Japan set as your default locale and as the default language
(Regional Options in Control Panel)?  If so, the data shd display
correctly without any additional effort. 

You can store EUC, Shift, ISO2022, and for that matter, Chinese in the
same table in diff rows as well. During presentation time (display),
just display using the appropriate encoding and it shd be ok. 

Holler if you need more help.  

Cheers,
Shashank





-
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: Forcing a sort order in a join

2002-09-17 Thread Philip Smolen

Right.  The simple example listed at the bottom of this message works great
under version 4.  Version 3 gave the right answer, but it was very slow.
That made me upgrade to version 4.

However, even with version 4, I run into the same problem as soon as I add a
join.  MySQL always wants to find an index to match the join conditions.  If
there isn't an appropriate index, it actually sorts the data to match join
conditions!  This is probably right in the general case, but it makes my
query run very slowly.  How can I make this run faster?

SELECT *
FROM huge_table,small_table
WHERE huge_table.field2 = small_table.field2
ORDER BY huge_table.field1 DESC
LIMIT 5;

I want MySQL to use the index on huge_table.field1, just like it does when
there is no join.

- Original Message -
From: Gerald Clark [EMAIL PROTECTED]
To: Philip Smolen [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Tuesday, September 17, 2002 12:55 PM
Subject: Re: Forcing a sort order in a join


 Using DESC on an index only works with V 4.

 Philip Smolen wrote:

 I'm trying to make a query faster.  It seems simple, but I can't make it
 work.
 
 This is a common case for me:
 SELECT *
 FROM very_large_table
 WHERE (simple_condition)
 ORDER BY an_indexed_field DESC
 LIMIT 5;
 For simple queries this works as expected.  MySQL starts at the end of
the
 




-
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




I know it's not supposed to be this difficult to install

2002-09-17 Thread Chip Wiegand

I am trying to get mysql-server installed from the FreeBSD port but keep
getting this dog-gone error -

mysqld started
Can't start server: Bind on unix socket: Permission denied
Do you already have another mysqld server running on socket:
/tmp/mysql.sock?
Aborting

Okay, so, I do a ps -aux | grep mysql and get nothing, as well as for
mysqld. So it's not running. I change permissions on /tmp/mysql.sock to
777 and it still fails, I change ownership to mysql and it still fails -
always with the same errror. I rebooted, mysqld is trying to start at
bootup, but the log just shows the same error.

I copied my-medium.cnf to /etc/my.cnf and verified it is pointing to
/tmp/mysql.sock. I even went to far as to delete mysql.sock and create a
new one, owned by mysql with wide open permissions, and it still fails,
same message.

What the heck am I doing wrong? besides installing from the port?

--
Chip


-
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 know it's not supposed to be this difficult to install

2002-09-17 Thread Chip Wiegand

On Tue, 2002-09-17 at 16:30, Robert Citek wrote:
 
 Hello Chip,
 
 Try 'rm /tmp/mysql.sock'  MySQL creates a new one at startup.
 
 - Robert

Tried that, it didn't create a new one. It still gives the same error
also, as if it is there.
I've installed previous versions of mysql a dozen times and have never
had this trouble.
--
Chip

 
 
 At 04:19 PM 9/17/2002 -0700, Chip Wiegand wrote:
 I am trying to get mysql-server installed from the FreeBSD port but keep
 getting this dog-gone error -
 
 mysqld started
 Can't start server: Bind on unix socket: Permission denied
 Do you already have another mysqld server running on socket:
 /tmp/mysql.sock?
 Aborting
 
 Okay, so, I do a ps -aux | grep mysql and get nothing, as well as for
 mysqld. So it's not running. I change permissions on /tmp/mysql.sock to
 777 and it still fails, I change ownership to mysql and it still fails -
 always with the same errror. I rebooted, mysqld is trying to start at
 bootup, but the log just shows the same error.
 
 I copied my-medium.cnf to /etc/my.cnf and verified it is pointing to
 /tmp/mysql.sock. I even went to far as to delete mysql.sock and create a
 new one, owned by mysql with wide open permissions, and it still fails,
 same message.
 
 What the heck am I doing wrong? besides installing from the port?
 
 



-
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 AUOT_INCREMENT

2002-09-17 Thread vinita vigine Murugiah


vinita vigine Murugiah wrote:

 HI

 I'm having problem with the AUTO_INCREMENT, we are using ver 3.23.33

 This is the definition of table software_machineOSs
 ++--+--++-++
 | Field  | Type  | Null | Key | Default | 
 Extra  |
 ++--+---+---+-++
 | softwareID | char(20)| YES   | MUL| NULL|   
  |
 | id   | int(2) || | 
 NULL| auto_increment |
 | osName | char(20)| YES| | NULL
 ||
 | osRevision  | char(20)| YES| | NULL
 ||
 ++--+---+---+---+--+

 Adding an entry
 mysql insert into software_machineOSs (softwareID, id, osName, 
 osRevision)
 - values (readline-4.3, NULL, test, test3);

 Selecting entries
 mysql select * from software_machineOSs where softwareid=readline-4.3;
 +--++---++
 | softwareID   | id | osName| osRevision |
 +--++---++
 | readline-4.3 |  1 | Tru64 | 5.1|
 | readline-4.3 |  1 | Solaris/Sparc | 8  |
 | readline-4.3 |  1 | Solaris/x86   | 8  |
 | readline-4.3 |  1 | test  | test   |
 | readline-4.3 |  1 | test  | test1  |
 | readline-4.3 |  1 | test | test1  |
 | readline-4.3 |  1 | test  | test3  |
 +--++---++
 7 rows in set (0.00 sec)


 As you can see the ID did NOT increment, I'm not sure what I'm doing 
 wrong. I tried with out giving any value for ID, 0 value for ID  NULL 
 for ID. Non of them seems working. Is this a bug in the version 3.23.33??

 Appreciate your fast response  Thank you for your time

 warm regards
 Vinita




-
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




Multi-table updates in MySQL

2002-09-17 Thread Phil Kernick

I'm using MySQL v3.23.52.

I want to update a column in one table to be based on a calculated expression 
from a column in another table.

Specifically I want something like this:

mysql update a set a.f1=b.f1 where a.f2=b.f2;
mysql update a, b set a.f1=b.f1 where a.f2=b.f2;

The first says table b is unknown, the second doesn't let there be multiple 
tables in an update.

While I could do this programatically using PHP or Perl, it feels like this is 
something sensible to do in a single line.

If there is a way to do this, please let me know directly as I'm not 
subscribed to the list.


Thanks,
Phil.

-- 
_-_|\   Phil Kernick  E-Mail: [EMAIL PROTECTED]
   / \  ROTFL Enterprises Mobile:  041 61 ROTFL
   \_.-*_/
v   Humourist, satirist, and probably a few more 'ists to boot!


-
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




4.0.3 InnoDB surprise

2002-09-17 Thread MySQL


I recently installed version 4 and converted my large tables to InnDB
format, after looking over the benchmarks.  I ran my hour long read
only dB 'exerciser', only to discover it now took 132 minutes, or
about four times longer than I expected.  I'm befuddled, I used the
same configure as previously (other than the innodb):

CFLAGS=-O3 CXX=gcc CXXFLAGS=-O3 -felide-constructors
-fno-exceptions -fno-rtti ./configure --with-mysqld-user=mysql
--prefix=/usr/local/mysql --without-bench
--with-unix-socket-path=/usr/local/mysql/tmp/mysql.sock
--with-client-ldflags=-all-static --with-raid
--with-mysqld-ldflags=-all-static --enable-assembler
--with-extra-charsets=none --without-debug --with-innodb

Suggestions??

r

-
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