MySQL v3.23.52-MAX on Win32

2002-11-24 Thread Pae Choi
I have created a test table for different data types as follows:

CREATE TABLE AllDataTypes (
 id  INTEGER,

 col_bit  BIT,
 col_boolean BOOL,

 col_tinyint TINYINT,
 col_smallint SMALLINT,
 col_int  INT,
 col_integer INTEGER,
 col_bigint  BIGINT,
 col_float  FLOAT,
 col_double DOUBLE,

 col_char  CHAR,
 col_char1 CHAR(1),
 col_char255 CHAR(255),
 col_varchar1 VARCHAR(1),
 col_varchar255 VARCHAR(255),

 col_decimal DECIMAL,
 col_decimal2 DECIMAL(10,2),
 col_numeric NUMERIC,
 col_numeric2 NUMERIC(10,2),

 col_date  DATE,
 col_time  TIME,
 col_timestamp TIMESTAMP,
 col_datetime DATETIME,

 col_binary MEDIUMBLOB,
 col_varbinary MEDIUMBLOB,
 col_longvarbinary MEDIUMBLOB,
 col_blob  MEDIUMBLOB,

 col_clob  TEXT,
 col_longvarchar MEDIUMTEXT

);


When I execute a query as follows:

INSERT INTO AllDataTypes (id, col_date) VALUES (1, '2002-11-23');

The table contains the right values for 'id' and 'col_date' as well as
all other columns with 'NULL', except a column, 'col_timestamp'. The
column, 'col_timestamp' contains a value, '2002112412'.

So I tested with more queries such as:

INSERT INTO AllDataTypes (id) VALUES (2);
INSERT INTO AllDataTypes (id, col_date, col_time) VALUES (1, '2002-11-23',
'23:50:12');

But the results was same that the column, 'col_timestamp' is containing the
values for above two entries. Isn't it suppose to be 'NULL'? Thanks


Pae






-
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 v3.23.52-MAX on Win32

2002-11-24 Thread Chase Urich
The first column of type timestamp will always be initialized with the
current timestamp. See the fourth and fifth paragraphs of the following
link.

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

 Isn't it suppose to be 'NULL'? Thanks

-- 
Linux: Because rebooting is for adding hardware.
Fingerprint = CE24 057D 1E88 A253 3196 89DB 9FF0 9EF0 2F70 8BE8 BE8


-
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 query crashing mysql ..... :S

2002-11-24 Thread toby z


hay guyz

im havin  a weired problem

i ve this search query

$srch_qry =  select ctnt_inf.* from ctnt_inf .
	 where (match (firstName ) against (\.$srch.\) .
		 or match (lastName ) against (\.$srch.\) .
		 or match (summary ) against (\.$srch.\) .
		 or match (body) against (\.$srch.\) .
		 or match (title ) against (\.$srch.\) );


$srch_qry_hndl = mysql_query ($srch_qry)
or die ('qry failed !  DA tbl must xixt in DA db specifyd bov  :s');


n im gettin bizzar results .


i)sometimes it works perfect showin all the results


ii)n some times it missbehavez . shows a sorry note for the strings i 
KNOW exist in the full text fields im serchin on .



iii)but most of the times  it crashes mysql . :S
i get thid msg box declaring mysql is gonna shut down



now
1. i ve got win 2K pro, php 4.2.2, mysql  3.23.39 , apache 1.3.24

2. im workin with unicode text n most of the fulltext fields im searching on 
are unicode


guyz im all stuck with this query
plz hlp


thnx a mill

toby ..




_
Add photos to your messages with MSN 8. Get 2 months FREE*. 
http://join.msn.com/?page=features/featuredemail


-
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 v3.23.52-MAX on Win32

2002-11-24 Thread Pae Choi
Thanks. That explains it.

Pae



 The first column of type timestamp will always be initialized with the
 current timestamp. See the fourth and fifth paragraphs of the following
 link.

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

  Isn't it suppose to be 'NULL'? Thanks

 --
 Linux: Because rebooting is for adding hardware.
 Fingerprint = CE24 057D 1E88 A253 3196 89DB 9FF0 9EF0 2F70 8BE8 BE8


 -
 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




problem with replication

2002-11-24 Thread Sönke Ruempler
hello,

i wanna setup replication, everything works so far, but the slave
can'tconenct to the master, access denied. but if i connect with the 'mysql'
program from slave machine to master machine, it works!

going crazy .. both mysqld's are 3.23.53 !

what is going wrong here ahh?

regards, soenke.


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

2002-11-24 Thread Listen Hinz
Dear Soenke,

 i wanna setup replication, everything works so far, but the slave
 can'tconenct to the master, access denied. but if i connect with the
'mysql'
 program from slave machine to master machine, it works!

Before you go crazy, check if the slave (user) has sufficient privileges.
Let's say the slave user is called repluser which connects from
replmachine. In this case you do

SHOW GRANTS FOR 'repluser'@'replmachine';

(on the master server, of course).

Check for the FILE privilege. The slave user won't need anything else. It
doesn't need SELECT or whatever, only FILE. On the master server, you can do
the following:

DELETE FROM mysql.user WHERE User = 'repluser';
DELETE FROM mysql.db WHERE User = 'repluser';
FLUSH PRIVILEGES;
GRANT FILE ON *.* [or only on the database you want to replicate] TO
'repluser'@'replmachine' IDENTIFIED BY 'some-password';

Now, your slave should be able to replicate from the master.

Hope it helps.

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


- Original Message -
From: Sönke Ruempler [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, November 24, 2002 11:53 AM
Subject: problem with replication


 hello,

 i wanna setup replication, everything works so far, but the slave
 can'tconenct to the master, access denied. but if i connect with the
'mysql'
 program from slave machine to master machine, it works!

 going crazy .. both mysqld's are 3.23.53 !

 what is going wrong here ahh?

 regards, soenke.


 -
 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




Berkeley DB and two phase commit

2002-11-24 Thread Gil Shai
Hi

I would like to know whether MySQL with the Berkeley DB tables supports
two phase commit?

Thanks
Gil

-
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: Turbine vs Connector/J

2002-11-24 Thread Mark Matthews
Ares Liu wrote:

  As both of them type IV JDBC, which one is the better?

If you're talking about the Apache Group's Turbine, it's not a JDBC
driver, it's a servlet framework that sits on top of JDBC.

-Mark


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

__  ___ ___   __
   /  |/  /_ __/ __/ __ \/ /  Mark Matthews [EMAIL PROTECTED]
  / /|_/ / // /\ \/ /_/ / /__ MySQL AB, Full-Time Developer - JDBC/Java
 /_/  /_/\_, /___/\___\_\___/ Flossmoor (Chicago), IL USA
___/ 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: Applet can not find com.mysql.jdbc.Driver

2002-11-24 Thread Mark Matthews
Matthew Scarrow wrote:


I have an applet and I'm trying to use Connector/ J 3 to connect to my
database.

I have uploaded the applet to my web server.
I have uploaded the mysql-connector-java-3.0.2-beta-bin.jar file to 
the same
dir as the applet
I have made a reference to the mysql.jar file in the html file like so

But when I run my applet I get the error: 
java.lang.ClassNotFoundException:
com.mysql.jdbc.Driver
I've tried everything I can think of. I had this working back with version
2.0.4 of mysql-connector but it doesn't work with this one.

Can you download the .jar file that you've uploaded using a web browser? 
If not, the permissions on the file are not correct.

	-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



Antigen found =*.scr file

2002-11-24 Thread ANTIGEN_BRVMAIL
Notice: Bravo Technical Resources does not allow EXE files into its email
system, they are deleted automatically. Please refrain from sending them in
the future. If there is a legitimate need to send an executable email,
please contact [EMAIL PROTECTED] Thank you.

Antigen for Exchange found fear.scr matching =*.scr file filter.
The file is currently Removed.  The message, Prince Pol and Maarken, his
most valued, was
sent from mysql  and was discovered in IMC Queues\Inbound
located at BRAVO/Dallas/BRVMAIL.

-
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 on virtual hosting

2002-11-24 Thread Sweethome.co.il Webmaster
Dear list,

Does any of you guys operate a mysql server in virtual hosting environment?
I need some advice on tuning and restriction based on system resources.

My system is running RH7.2 , on an Intel based server, 2x1Ghz CPU's and 1 
giga of RAM.
I have 2 hd's in raid 1 mode (hardware). I currenly run MySQL 3.23.53

Here are few questions I have in mind, any other advice on keeping this 
system in a
sane state will be appreciated.

1. From the following, what would be the best OS to run MySQL as of today?
FreeBSD, Linux, OpenBSD

2. Is it possible to limit number of connections per user or database?
MySQL can eat pretty much resources, if webmasters write bad code, I need 
to restrict
them or charge extras for the usage as well as to protect the system 
against DOS attacks,
which in this case will need to exploit a bad script which accesses the 
database.
Restricting httpd connections is irrelevant here, so I must be able to 
control MySQL
connections.

3. A lot of ready scripts or novice webmasters know very well how to open a 
connection
but closing it... that's beyond them :) What is a sensible timeout and what 
exactly
is the parameter that can kill these connections?

4. If you run a similar system, what would be the most important parameters 
for load
tuning, and how would you set them?

Thanks for all answers,

		Justin Grindea	
		[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: MySQL on virtual hosting

2002-11-24 Thread Brian Reichert
On Sun, Nov 24, 2002 at 10:39:43PM +0200, Sweethome.co.il Webmaster wrote:
 Dear list,
 
 Does any of you guys operate a mysql server in virtual hosting environment?
 I need some advice on tuning and restriction based on system resources.

One thing you need to nail down is what the abstraction is: _how_
do you want to implement virtual hosting?

For example, under FreeBSD, you can create a jail(8): a complete
virtual machine tied to an IP address, and you can cram one of your
(human) clients in there, with all of their services.

(Before you worry about consuming all of your public IPs for such
tricks, note that you can run them on private IPs, and use the
kernel's ability to NAT connections in/out of the box to these
virtual machines.)

That technically eats more resources than other virtual hosting
methods, but it most completely isolates a user from the rest of
the system, if you need fine-grained control over how your machine's
getting utilized, this gets you down to the nuts and bolts.

The kernel itself will let you play tricks for traffic shaping, so
you can constrain which of your virtual machines get traffic
'appropriately', and you can packet-filter everything to death, so
that you can prevent them from running services that you don't want.

This is somewhat distinct from the excellent question you ask, and
I'm curious what various people's responses will be...

 Thanks for all answers,
 
   Justin Grindea  
   [EMAIL PROTECTED]

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




displaying a letter based on a query value

2002-11-24 Thread Alex Behrens
Hey All,

I'm working on a site that displays all the players on my hockey team and I
want to the page to indicate the captains automatically. Right now im using
the following query to display all the captains, however, captains are
indicated by a 1, is it possible to display a C when a 1 is found? How
would i do this?

select captain from stats where captain  0 and number = '23' group by
number;

this returns a 1 for any player with the number that matches being a
captain, however it display a 1 is it possible to make that 1 displayed as a
C on my page?

mysql


Thanks!

-Alex Big Al Behrens
E-mail: [EMAIL PROTECTED]
Urgent E-mail: [EMAIL PROTECTED] (Please be brief!)
Phone: 651-482-8779
Cell: 651-329-4187
Fax: 651-482-1391
ICQ: 3969599
Owner of the 3D-Unlimited Network:
http://www.3d-unlimited.com
Send News:
[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: displaying a letter based on a query value

2002-11-24 Thread DL Neil
Hey Alex

 select captain from stats where captain  0 and number = '23' group by
 number;

 this returns a 1 for any player with the number that matches being a
 captain, however it display a 1 is it possible to make that 1 displayed as
a
 C on my page?


MySQL allows an IF() within the SELECT clause.
=dn


-
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: displaying a letter based on a query value

2002-11-24 Thread Alex Behrens
Hey,

I'm not sure how to implement this into my query, i looked it on the
mysql.com documentation and it's confusing.

I tried this query:

select captain from stats where captain  0 if (captain(1,'C') and number
 = '$number' group by number;

but i dont think its right cuz its returning a value. How do I make it show
if the captain value is 1 that it returns a C?

Thanks!

-Alex Big Al Behrens
E-mail: [EMAIL PROTECTED]
Urgent E-mail: [EMAIL PROTECTED] (Please be brief!)
Phone: 651-482-8779
Cell: 651-329-4187
Fax: 651-482-1391
ICQ: 3969599
Owner of the 3D-Unlimited Network:
http://www.3d-unlimited.com
Send News:
[EMAIL PROTECTED]
- Original Message -
From: DL Neil [EMAIL PROTECTED]
To: Alex Behrens [EMAIL PROTECTED]; MYSQL [EMAIL PROTECTED]
Sent: Sunday, November 24, 2002 4:38 PM
Subject: Re: displaying a letter based on a query value


 Hey Alex

  select captain from stats where captain  0 and number = '23' group by
  number;
 
  this returns a 1 for any player with the number that matches being a
  captain, however it display a 1 is it possible to make that 1 displayed
as
 a
  C on my page?


 MySQL allows an IF() within the SELECT clause.
 =dn





-
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: displaying a letter based on a query value

2002-11-24 Thread Jeff Kilbride
select if(captain = 1, 'C', '')
from stats
where captain  0
and number = $number
group by number

This returns 'C' whenever the captain field is 1 and '' (empty string)
otherwise.

--jeff

- Original Message -
From: Alex Behrens [EMAIL PROTECTED]
To: DL Neil [EMAIL PROTECTED]; MYSQL
[EMAIL PROTECTED]
Sent: Sunday, November 24, 2002 3:53 PM
Subject: Re: displaying a letter based on a query value


 Hey,

 I'm not sure how to implement this into my query, i looked it on the
 mysql.com documentation and it's confusing.

 I tried this query:

 select captain from stats where captain  0 if (captain(1,'C') and number
  = '$number' group by number;

 but i dont think its right cuz its returning a value. How do I make it
show
 if the captain value is 1 that it returns a C?

 Thanks!
 
 -Alex Big Al Behrens
 E-mail: [EMAIL PROTECTED]
 Urgent E-mail: [EMAIL PROTECTED] (Please be brief!)
 Phone: 651-482-8779
 Cell: 651-329-4187
 Fax: 651-482-1391
 ICQ: 3969599
 Owner of the 3D-Unlimited Network:
 http://www.3d-unlimited.com
 Send News:
 [EMAIL PROTECTED]
 - Original Message -
 From: DL Neil [EMAIL PROTECTED]
 To: Alex Behrens [EMAIL PROTECTED]; MYSQL
[EMAIL PROTECTED]
 Sent: Sunday, November 24, 2002 4:38 PM
 Subject: Re: displaying a letter based on a query value


  Hey Alex
 
   select captain from stats where captain  0 and number = '23' group by
   number;
  
   this returns a 1 for any player with the number that matches being a
   captain, however it display a 1 is it possible to make that 1
displayed
 as
  a
   C on my page?
 
 
  MySQL allows an IF() within the SELECT clause.
  =dn
 
 



 -
 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




MySQL 4 Indexing

2002-11-24 Thread Sean Phillips
Is it possible to tell MySQL 4.0.5 what special characters it can index?  For 
instance, I would like it to index - and + characters so that hyphenated words 
like full-text and words like C++ are indexed and can be searched.  I've been 
trying to find a way to do this, but haven't found a solid answer yet.  I've been told 
it may be hard coded into the mysql source and would involve changing around 
myisam/ft_parser.*?  Is this easy to add or modify to allow these two character in the 
indexes?  Any assistance would be greatly appreciated.

Thanks,
Sean



Re: displaying a letter based on a query value

2002-11-24 Thread Alex Behrens
hey,

I got that query to work but i dont know how to display it on an HTML page,
I'm using this and its not displaying anything:

$captainquery = mysql_query(select if(captain = 1,'C','') from stats AS
cstatus WHERE captain  0 and number = '19' group by number);
while($captain2=mysql_fetch_array($captainquery)){ 
 printf (C indicates captain: %s,$captain2[cstatus]);
}

and I'm certain the number '19' is set to be a captain.


Thanks!

-Alex Big Al Behrens
E-mail: [EMAIL PROTECTED]
Urgent E-mail: [EMAIL PROTECTED] (Please be brief!)
Phone: 651-482-8779
Cell: 651-329-4187
Fax: 651-482-1391
ICQ: 3969599
Owner of the 3D-Unlimited Network:
http://www.3d-unlimited.com
Send News:
[EMAIL PROTECTED]
- Original Message - 
From: Jeff Kilbride [EMAIL PROTECTED]
To: Alex Behrens [EMAIL PROTECTED]; MYSQL [EMAIL PROTECTED]
Sent: Sunday, November 24, 2002 5:08 PM
Subject: Re: displaying a letter based on a query value


 select if(captain = 1, 'C', '')
 from stats
 where captain  0
 and number = $number
 group by number
 
 This returns 'C' whenever the captain field is 1 and '' (empty string)
 otherwise.
 
 --jeff
 
 - Original Message -
 From: Alex Behrens [EMAIL PROTECTED]
 To: DL Neil [EMAIL PROTECTED]; MYSQL
 [EMAIL PROTECTED]
 Sent: Sunday, November 24, 2002 3:53 PM
 Subject: Re: displaying a letter based on a query value
 
 
  Hey,
 
  I'm not sure how to implement this into my query, i looked it on the
  mysql.com documentation and it's confusing.
 
  I tried this query:
 
  select captain from stats where captain  0 if (captain(1,'C') and number
   = '$number' group by number;
 
  but i dont think its right cuz its returning a value. How do I make it
 show
  if the captain value is 1 that it returns a C?
 
  Thanks!
  

  -Alex Big Al Behrens
  E-mail: [EMAIL PROTECTED]
  Urgent E-mail: [EMAIL PROTECTED] (Please be brief!)
  Phone: 651-482-8779
  Cell: 651-329-4187
  Fax: 651-482-1391
  ICQ: 3969599
  Owner of the 3D-Unlimited Network:
  http://www.3d-unlimited.com
  Send News:
  [EMAIL PROTECTED]
  - Original Message -
  From: DL Neil [EMAIL PROTECTED]
  To: Alex Behrens [EMAIL PROTECTED]; MYSQL
 [EMAIL PROTECTED]
  Sent: Sunday, November 24, 2002 4:38 PM
  Subject: Re: displaying a letter based on a query value
 
 
   Hey Alex
  
select captain from stats where captain  0 and number = '23' group
by
number;
   
this returns a 1 for any player with the number that matches being a
captain, however it display a 1 is it possible to make that 1
 displayed
  as
   a
C on my page?
  
  
   MySQL allows an IF() within the SELECT clause.
   =dn
  
  
 
 
 
  -
  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




MySQL subquery that works

2002-11-24 Thread Bruno Batarelo
Greetings!

I am aware that MySQL does not support subqueries. I have a 3 gb large
database of bibliographic records. Database is designed by a model that is
accepted by almost every library system, but there is one problem. When
searching that database, nested queries are needed and there's a difference
between mysql and every other database system. Now, when I linked these
tables to Access database and used JET SQL everything was working very nice
and nested queries worked too because Access Database supports them. Speed
is impressive.

The question is what does Access do in order to perform subqueries on MySQL
via MyODBC driver since it is obvious that they work? What can I do, but I
do not want to use access database as a layer between my application and
mysql server? I use Visual Basic for accessing mysql server.

Thank You very much
Bruno


-
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: displaying a letter based on a query value

2002-11-24 Thread DL Neil
hey Alex,

1 swap from stats and AS cstatus - the AS is to put a column name/give
you an associate array element name for the if(captain = 1,'C','')

2 recommend replacing the '' within the if() with captain - that way
something will be returned regardless of the if() comparison

3 recommend running any query that returns unexpected results from the
command line, or through an admin/mgmt package

Regards,
=dn


 I got that query to work but i dont know how to display it on an HTML
page,
 I'm using this and its not displaying anything:

 $captainquery = mysql_query(select if(captain = 1,'C','') from stats AS
 cstatus WHERE captain  0 and number = '19' group by number);
 while($captain2=mysql_fetch_array($captainquery)){
  printf (C indicates captain: %s,$captain2[cstatus]);
 }

 and I'm certain the number '19' is set to be a captain.


 Thanks!
 
 -Alex Big Al Behrens
 E-mail: [EMAIL PROTECTED]
 Urgent E-mail: [EMAIL PROTECTED] (Please be brief!)
 Phone: 651-482-8779
 Cell: 651-329-4187
 Fax: 651-482-1391
 ICQ: 3969599
 Owner of the 3D-Unlimited Network:
 http://www.3d-unlimited.com
 Send News:
 [EMAIL PROTECTED]
 - Original Message -
 From: Jeff Kilbride [EMAIL PROTECTED]
 To: Alex Behrens [EMAIL PROTECTED]; MYSQL
[EMAIL PROTECTED]
 Sent: Sunday, November 24, 2002 5:08 PM
 Subject: Re: displaying a letter based on a query value


  select if(captain = 1, 'C', '')
  from stats
  where captain  0
  and number = $number
  group by number
 
  This returns 'C' whenever the captain field is 1 and '' (empty string)
  otherwise.
 
  --jeff
 
  - Original Message -
  From: Alex Behrens [EMAIL PROTECTED]
  To: DL Neil [EMAIL PROTECTED]; MYSQL
  [EMAIL PROTECTED]
  Sent: Sunday, November 24, 2002 3:53 PM
  Subject: Re: displaying a letter based on a query value
 
 
   Hey,
  
   I'm not sure how to implement this into my query, i looked it on the
   mysql.com documentation and it's confusing.
  
   I tried this query:
  
   select captain from stats where captain  0 if (captain(1,'C') and
number
= '$number' group by number;
  
   but i dont think its right cuz its returning a value. How do I make it
  show
   if the captain value is 1 that it returns a C?
  
   Thanks!
   

   -Alex Big Al Behrens
   E-mail: [EMAIL PROTECTED]
   Urgent E-mail: [EMAIL PROTECTED] (Please be brief!)
   Phone: 651-482-8779
   Cell: 651-329-4187
   Fax: 651-482-1391
   ICQ: 3969599
   Owner of the 3D-Unlimited Network:
   http://www.3d-unlimited.com
   Send News:
   [EMAIL PROTECTED]
   - Original Message -
   From: DL Neil [EMAIL PROTECTED]
   To: Alex Behrens [EMAIL PROTECTED]; MYSQL
  [EMAIL PROTECTED]
   Sent: Sunday, November 24, 2002 4:38 PM
   Subject: Re: displaying a letter based on a query value
  
  
Hey Alex
   
 select captain from stats where captain  0 and number = '23'
group
 by
 number;

 this returns a 1 for any player with the number that matches being
a
 captain, however it display a 1 is it possible to make that 1
  displayed
   as
a
 C on my page?
   
   
MySQL allows an IF() within the SELECT clause.
=dn
   
   
  
  
  
   -
   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: MySQL subquery that works

2002-11-24 Thread R. Hannes Niedner
On 11/24/02 4:30 PM, Bruno Batarelo [EMAIL PROTECTED] wrote:

 The question is what does Access do in order to perform subqueries on MySQL
 via MyODBC driver since it is obvious that they work? What can I do, but I
 do not want to use access database as a layer between my application and
 mysql server? I use Visual Basic for accessing mysql server.
 
 Thank You very much
 Bruno
 Not that I knew the real answer but I suspect that Access just retrieves
the results in a temporary table and then finishes the job by including the
results table with a join to the rest of the tables as required. Or maybe it
wraps the subquery in VB/VB script and loops through the subselect and does
the select in every loop.

/h


-
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




New charset for MySQL

2002-11-24 Thread Shyamal Banerjee
Dear sir,

I want to create a website in my native language.
I would like MySQL support for my native character set, which is Bengali. I
think MySQL does not support this language. How can I add support for it in
MySQL ?
Thanks in advance for any reply.

Shyamal



-
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




Replication Problems

2002-11-24 Thread Lewis Watson
I am getting this error while trying to Replicate to a second MySQL server.

021124 23:40:25  Slave: reconnected to master
'[EMAIL PROTECTED]:3306',replication resumed in log 'FIRST' at position
4
021124 23:40:25  Error reading packet from server: Binary log is not open
(server_errno=2000)

I have added the following to the master:
[mysqld]
socket=/tmp/mysql.sock
server-id=1
log-bin

And added this to the slave:
[mysqld]
server-id=2
master-host=192.168.0.16
master-user=replicate
master-password=mypasshere

It looks like the bin files are not being created on the master server. I
could find very little regarding this problem. Any ideas?
Thanks.
Lewis




-
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




Minimal install for embedded setup.

2002-11-24 Thread Chris
Greetings,

Im trying to keep the mysql installation to a minimal since space
is limited on a Compact Flash card. The following binaries in the 'bin'
directory total 16megs. Mysql is used very limited, only inserts and reads
from php are done to the database, and replication will be used as well.
My question is, out of the binaries in the 'bin' dir (and also listed
below) which are safe to remove in this situation? Also, if you dont have
time to pick each binary, is the mysql server dependant on any of the
following, or are they all just tools?

comp_errmysql_setpermission  mysqldumpslow
isamchk mysql_zapmysqlhotcopy
libexec mysqlaccess  mysqlimport
msql2mysql  mysqlaccess.conf mysqlshow
my_print_defaults   mysqladmin   mysqltest
myisamchk   mysqlbinlog  pack_isam
myisampack  mysqlbug perror
mysql   mysqlcheck   replace
mysql_configmysqld   resolve_stack_dump
mysql_convert_table_format  mysqld.sym.gzresolveip
mysql_find_rows mysqld_multi safe_mysqld
mysql_fix_privilege_tables  mysqldump


Thanks alot!!
- Chris



-
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 Errors *NEWEST*

2002-11-24 Thread Lewis Watson
NEWEST**
I am now getting this error while trying to Replicate to a second MySQL
server.

021125  0:41:01  Slave: Failed reading log event, reconnecting to retry, log
'bsd1-bin.001' position 73
021125  0:41:01  Slave: reconnected to master
'[EMAIL PROTECTED]:3306',replication resumed in log 'bsd1-bin.001' at
position 73
021125  0:41:17  Error reading packet from server: Could not open log file
(server_errno=2)
021125  0:41:17  Slave: Failed reading log event, reconnecting to retry, log
'bsd1-bin.002' position 86
021125  0:41:17  Slave: reconnected to master
'[EMAIL PROTECTED]:3306',replication resumed in log 'bsd1-bin.002' at
position 86
021125  0:41:17  Error reading packet from server: Could not find first log
(server_errno=65535)
021125  0:41:37  Slave thread killed while waiting to reconnect after a
failed read
021125  0:41:37  Slave thread exiting, replication stopped in log
'bsd1-bin.002' at position 86
021125  0:41:37  Slave: connected to master '[EMAIL PROTECTED]:3306',
replication started in log 'FIRST' at position 4

I have added the following to the master:
[mysqld]
socket=/tmp/mysql.sock
server-id=1
log-bin

[safe_mysqld]
socket=/tmp/mysql.sock
server-id=1
log-bin

And added this to the slave:
[mysqld]
server-id=2
master-host=192.168.0.16
master-user=replicate
master-password=mypasshere

Any ideas on this?
Thanks.
Lewis




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

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




install privilege table failed

2002-11-24 Thread iulian
Description:
MySQL crashed at final step, when executing script mysql_install_db, with msg:
mysqld got signal 11;

Here is all last output line at finish installation:

/usr/bin/ginstall -c .libs/mysqlmanager /usr/local/bin/mysqlmanager
make[2]: Nothing to be done for `install-data-am'.
make[2]: Leaving directory 
`/var/lib/users/install/install_php_all/mysql-4.0.5-beta/tools'
make[1]: Leaving directory 
`/var/lib/users/install/install_php_all/mysql-4.0.5-beta/tools'
make[1]: Entering directory 
`/var/lib/users/install/install_php_all/mysql-4.0.5-beta'
make[2]: Entering directory 
`/var/lib/users/install/install_php_all/mysql-4.0.5-beta'
make[2]: Nothing to be done for `install-exec-am'.
make[2]: Nothing to be done for `install-data-am'.
make[2]: Leaving directory 
`/var/lib/users/install/install_php_all/mysql-4.0.5-beta'
make[1]: Leaving directory 
`/var/lib/users/install/install_php_all/mysql-4.0.5-beta'

Here is output for mysql_install_db:

Preparing db table
Preparing host table
Preparing user table
Preparing func table
Preparing tables_priv table
Preparing columns_priv table
Installing all prepared tables
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 against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
We will try our best to scrape up some info that will hopefully help diagnose
the problem, but since we have already crashed, something is definitely wrong
and this may fail.

key_buffer_size=8388600
read_buffer_size=131072
sort_buffer_size=2097144
max_used_connections=0
max_connections=100
threads_connected=1
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_connections = 
225791 K
bytes of memory
Hope that's ok; if not, decrease some variables in the equation.

thd=0x83d78d0
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...
Cannot determine thread, fp=0xbf5fea68, backtrace may not be correct.
Stack range sanity check OK, backtrace follows:
0x8088580
0x822ad2a
0x8240f27
0x8097ae1
0x809a74e
0x8097900
0x8092198
0x8224e8e
0x82648d4
./mysql_install_db: line 1: 21185 Segmentation fault  
/usr/local/libexec/mysqld --bootstrap --skip-grant-tables --basedir=/usr/local 
--datadir=/var/lib/mysql --skip-innodb --skip-bdb
Installation of grant tables failed!

Examine the logs in /var/lib/mysql for more information.
You can also try to start the mysqld daemon with:
/usr/local/libexec/mysqld --skip-grant 
You can use the command line tool
/usr/local/bin/mysql to connect to the mysql
database and look at the grant tables:

shell /usr/local/bin/mysql -u root mysql
mysql show tables

Try 'mysqld --help' if you have problems with paths. Using --log
gives you a log in /var/lib/mysql that may be helpful.

The latest information about MySQL is available on the web at
http://www.mysql.com
Please consult the MySQL manual section: 'Problems running mysql_install_db',
and the manual section that describes problems on your OS.
Another information source is the MySQL email archive.
Please check all of the above before mailing us!
And if you do mail us, you MUST use the /usr/local/bin/mysqlbug script!

I read in log files: 

021125 01:03:36  mysqld started
021125  1:03:36  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.
InnoDB: The first specified data file ./ibdata1 did not exist:
InnoDB: a new database to be created!
021125  1:03:36  InnoDB: Setting file ./ibdata1 size to 10 MB
InnoDB: Database physically writes the file full: wait...
021125  1:03:37  InnoDB: Log file ./ib_logfile0 did not exist: new to be 
created
InnoDB: Setting log file ./ib_logfile0 size to 5 MB
InnoDB: Database physically writes the file full: wait...
021125  1:03:38  InnoDB: Log file ./ib_logfile1 did not exist: new to be 
created
InnoDB: Setting log file ./ib_logfile1 size to 5 MB
InnoDB: Database physically writes the