RE: MyODBC BDE invalid configuration error (BDE Error 12550)

2002-02-08 Thread Venu

Hi, 

> -Original Message-
> From: Guido Sohne [mailto:[EMAIL PROTECTED]]
> Sent: Friday, February 08, 2002 6:54 AM
> To: [EMAIL PROTECTED]
> Subject: MyODBC BDE invalid configuration error (BDE Error 12550)
> 
> 
> We're running a MySQL 3.23.47 server on Windows 98, and when trying to
> connect to BDE version 3.0 (bundled with Borland C++ Builder 1) using
> MyODBC version 3.51 we get something like
> 
> 
> Invalid configuration parameter:
> Alias: database_alias
> 
> BDE Error 12550 [0x31][0x6]
> 
> 
> I've searched the list archives and realize that some people have
> occasionally come across this problem but haven't found a solution or an
> indication of what the problem is ...

Is it possible for you to trace MS ODBC DM calls and send that log ? 
That enables the clear picture of what is happening.

I tried to download the eval copy of Borland C++ Builder to give a try, 
but it is ~140 MB, so waiting for your log. If it doesn't help, then I 
will go ahead and give a try by downloading.

> 
> Borland,s web site says of BDE Error 12550
> 
> 
> 12550 Invalid configuration parameter.
> 
> One possible cause for the error:
> ODBC ALIASES.
> When creating and/or using a BDE alias that is using 
> an ODBC DSN make sure that the ALIAS parameter "ODBC DSN" is
> set to the DSN that you wish to use and that has been created 
> using ODBC Manager.  Available ODBC DSN's can be chosen from 
> the parameter's drop-down edit using the BDE Administrator.

> 
> Another possible cause:
> Using ISAPI app and ODBC against NT web server.  
> ODBC DSN on NT machine should be set to "system" 
> instead of "user".

Did you tried with the 'system dsn' or 'file dsn' ? And whats the 
outcome ? 

For more information on different types of DSNs, refer to 
http://www.mysql.com/products/myodbc/faq.html#DSN_Types

Regards, Venu
--
For technical support contracts, go to https://order.mysql.com
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /   Mr. Venu <[EMAIL PROTECTED]>
 / /|_/ / // /\ \/ /_/ / /__  MySQL AB, Developer
/_/  /_/\_, /___/\___\_\___/  California, 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: I must ask.

2002-02-08 Thread Bob Hall

On Fri, Feb 08, 2002 at 06:10:34PM -, DL Neil wrote:
> There are some RDBMS-es that implement SQL to the point of apparently setting up a 
>construct that links tables -
> foreign key based data integrity being the first example that springs to (my) mind. 
>However relational logic
> suggests that the way to set up a linkage between tables is to show this in dynamic 
>logic - your SQL statement,
> eg
> 
> SELECT *
> FROM tbl1, tbl2
> WHERE tbl1.PrimaryKey = tbl2.ForeignKey;
> 
> will produce a result-row for every intersection 'match' between the two tables.
> 
> One of the MAJOR advances of relational databases over their predecessors was this 
>move 'away' from structural
> 'connections'. However these have been maintained as 'features' by some, usually to 
>promote speed/efficiency.

Speed/efficiency is a minor issue. Integrity constraints are used to 
prevent people from writing queries that violate relational integrity 
rules; e.g. create orphan records. And integrity constraints are 
unrelated to joins, except in the most incidental way. It is possible 
to use them to create joins, but that's not why they're built into 
databases.  

Bob Hall
--
Database

-
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: Retrieving a numeric series from a SELECT

2002-02-08 Thread José Angel Blanco Linares

Hi, Fellows!

Sorry for my poor english. Thats why I can explain myself properly.
:- )

What I really want is a calculate column with consecutive numbers from  to 
, where  can be any number, and  depending on the result of the WHERE 
clause. I need to print pay orders for students, this pay orders use a 
consecutive control number, the criteria to select students use to be variable.
Example:
SELECT , id, name FROM students WHERE status='OK'
(4 rows selected)
or
SELECT , id, name FROM students WHERE grade=1
(230 rows selected)


 must be the same number that is printed in the pay order. The next pay 
order on the printer is 15000, then  of the first row of the SELECT 
must be 15100, the next row 15001, and so on. 

you get it?

I remember that the sample i saw in this SQL list only used a SELECT statement 
without a table, or whitout a memory variable. it was only a SELECT 
, and it returns a consecutive serie from 1 to 100.

Thanks again.
__
José Angel Blanco Linares
Depto Servicios de Apoyo Académico
Centro de Enseñanza Técnica Industrial
3641-3250, ext: 266

-
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




Table appears in multiple joins returns null column

2002-02-08 Thread Keith A. Calaman

I have the below query that returns the correct records but the
POINTFUND.description field is all NULL while it has values in the table.
Any idea why?  Thanks.

SELECT

RACES.RACE_ID,
RACES.sequence,
TYPES.typelong,
SCHEDULE.event,
SCHEDULE.date,
PARTY.lname,
POINTFUND.description

FROM

TYPES LEFT JOIN RACES ON RACES.TYPE_ID = TYPES.TYPE_ID
LEFT JOIN POINTFUND ON POINTFUND.TYPE_ID = TYPES.TYPE_ID,
SCHEDULE,
PARTY

WHERE

RACES.SCHEDULE_ID = SCHEDULE.SCHEDULE_ID AND
PARTY.PARTY_ID = SCHEDULE.TRACK_ID

ORDER BY

SCHEDULE.date, PARTY.lname


-
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: Retrieving a numeric series from a SELECT

2002-02-08 Thread Anvar Hussain K.M.

Hi,

If you have a table with at least the number of rows that you want in your 
series
you can do this.

Set @Colnum := 0;
Select @Colnum := @colnum+1 as colnum from tablename limit (number of rows 
required);
set @column := 0;

If you want a series starting from a value other than 1, initialize colnum 
value to one less than
required starting value.

Anvar.

At 03:08 PM 08/02/2002 -0600, you wrote:
Hi, everybody

How can I get a numeric column from a SQL SELECT statement?
I mean, with a SELECT get something like this

ColNum   or   ColNum
   1 10
   2 11
   3 12
   4 13
   5 14
   6 15
   ...   ...

Some time ago, somebody wrote a sample that do exactly what I need. In fact, I
took that sample and saved it to my HD, but i can't find it, hehehe.

TIA



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

2002-02-08 Thread Kyle Hayes

On Friday 08 February 2002 16:32, Gurupartap Davis wrote:
> Yes, I saw that before...My filesize was limited to 2GB before, but now
> with a 2.4 kernel and reiserfs I _should_ be allowed to create a 20GB
> data file now, right?
>
> So something's wrong... as I said before, I have successfully created a
> 9GB file on this machine before, so the filesystem isn't to blame for a
> 4GB limitation...

If you are using one of the default installations of ReiserFS from SuSE,
it will be in the old (3.5) format.  This will limit the size of files
to 2GB even if you are using a new kernel and Glibc.  If you remounted with
-o conv, you will be able to create _new_ files that exceed 2GB, but I
think that any existing file will be limited to 2GB.

One way to test this would be to copy (not rename!) the table files to a new
name, remove the old ones and rename the new ones back to the old names.
Of course, this will work better if you have MySQL down at the time :-)

It is also possible that the table size has been set when you created the
tables.  Look up MAX_ROWS (MAXROWS?) in the online manual.

Best,
Kyle

-- 
Quicknet's MicroTelco fax and voice service has just added
another carrier giving MicroTelco users more low rates to
choose from. This new carrier is Altair Telecom - a low cost,
worldwide voice telephony carrier that is available by up-grading
at no additional cost to Internet SwitchBoard v6.0 or MicroTelco
Gateway v2.5. http://www.quicknet.net/download/

Cut costs, Fax smart. Use iPrint2Fax worldwide and save!
==
FREE software download available at www.iPrint2Fax.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




mysql bug in TEXT type

2002-02-08 Thread Rusty Wright

Our backup software can run a shell script before it starts the
backups (and another script when they're finished); I use a script
that shuts mysql down and runs myisamchk.  Originally it was using

  myisamchk --safe-recover */*.MYI

Then I was eyeballing the online documentation for myisamchk and
decided to change it to

  myisamchk --safe-recover --extend-check --sort-index */*.MYI

On one of the machines this generated lots and lots of errors; lots of

  Found block with too small length at #; Skipped

And several

  Found link that points at ## (outside data
  file) at ##

And several

  Found block that points outside data file at ##

One annoying thing is that myisamchk never fixed these problems; each
time we ran it the same errors were there.  We tried copying the db
files to a different machine with the latest version of mysql; no
cigar.

Then we tried dumping the database using mysqldump and then importing
that into a fresh database, ran the above myisamchk and even that
generated the *SAME ERRORS*!  No complaints whatsoever from mysql
during the import.

Then I started searching the mailing list archives and I noticed one
response by Widenius suggesting using a binary version from mysql.com
so I downloaded the mysql-3.23.47-sun-solaris2.8-sparc and installed
it, input the output from mysqldump, ran the above myisamchk; that
generated the *SAME ERRORS*!

Then I decided to eyeball the output of mysqldump and see if there was
anything suspicious looking.  It was mainly one of the tables that got
a lot of these errors.  Here's its definition from mysqldump:

CREATE TABLE time_edit (
  teid int(10) unsigned NOT NULL auto_increment,
  classid int(10) unsigned default NULL,
  empid int(11) default NULL,
  starttime int(10) unsigned default NULL,
  duration smallint(5) default NULL,
  facid tinyint(4) default NULL,
  comment text,
  PRIMARY KEY  (teid),
  KEY index_te_st (starttime,empid)
) TYPE=MyISAM;

The only thing that made me suspicious was the COMMENT field that's of
type TEXT.  On a hunch I decided to change it to VARCHAR(255) and
Voila! when I ran the above myisamchk the messages were gone.

-
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 
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




Re: InnoDB File Size

2002-02-08 Thread Gurupartap Davis

Yes, I saw that before...My filesize was limited to 2GB before, but now with
a 2.4 kernel and reiserfs I _should_ be allowed to create a 20GB data file
now, right?

So something's wrong... as I said before, I have successfully created a 9GB
file on this machine before, so the filesystem isn't to blame for a 4GB
limitation...

> >From http://www.innodb.com/ibman.html :
>
> 
> MySQL/InnoDB-3.23.44, November 2, 2001
>
> You can define foreign key constraints on InnoDB tables. An example:
FOREIGN
> KEY (col1) REFERENCES table2(col2).
> You can create > 4 GB data files in those file systems that allow it.
> 
>
> Thus > 4 G  files should be available also on 4.0.1.
>
> Best regards,
>
> Heikki Tuuri
> Innobase Oy

> "Gurupartap Davis" wrote in message ...
> >I'm using MySQL 4.0, trying to set up some innodb tables with several
20GB
> >data files,
> >but mysql is telling me that the files must be <= 4096MB
> >
> >This is on a RedHat 7.2 box with redhat's 2.4.9-13 enterprise kernel on a
> >reiserfs filesystem...
> >
> >I don't think there should be such a low limit...I accidentally made a
9GB
> >log file the other day.
> >
> >Is this a limit of innodb?  Is there somewhere I can adjust this limit?
> >
> >Thanks
> >-Partap Davis
> >Syncrasy, LLC



-
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




MAX_ROWS limits

2002-02-08 Thread Charlie Thunderberg

Hi,

I am using MySql 3.23.47 for nt (W2000).

The number of rows of my table on an NTFS file system is estimated to become
around 6,000,000,000. I am trying to increase my default MAX_ROWS=4294967295
with ALTER TABLE test AVG_ROW_LENGTH=9 MAX_ROWS=60;

Following this, SHOW TABLE STATUS still gives the original number for
MAX_ROWS!
Could someone help me to understand, if MAX_ROWS is limited to the maximum
value of the integer, or do I need to change some other settings in order to
go beyond this number?

Thanks for any ideas!

Charlie





_
Chat with friends online, try MSN Messenger: http://messenger.msn.com


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

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




Error Msg on Connect

2002-02-08 Thread Paul Campbell

Can't connect to local MySQl server through port 111


-
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




libncurses not found; have bad workaround

2002-02-08 Thread root

>Description:
When loading initial data from a text file, mysql looks for 
libncurses.so.4, doesn't find it and quits the command with
an error. This happens under Red Hat Linux 7.2, because it
has libncurses.so.5.x.
>How-To-Repeat:
This must be done on a system without an accessible libncurses.so.5.
Follow the tutorial in the manual to create a text file to
load into the pet database. Then, execute the following command:
load data local infile "pet.txt" into table pet;
>Fix:
This desperate hack worked for me:
cd /usr/lib
ln -s libncurses.so libncurses.so.4

After this, the load data command worked fine, however, I do not know 
further ramifications of masquerading the 5.x libncurses as 4.

>Submitter-Id:  [EMAIL PROTECTED]
>Originator:[EMAIL PROTECTED]
>Organization:
 R-Mode Corp.
>MySQL support: none
>Synopsis:  libncurses not found on load data
>Severity:  non-critical
>Priority:  medium
>Category:  mysql
>Class: sw-bug
>Release:   mysql-3.23.47 (Official MySQL RPM)
>Server: /usr/bin/mysqladmin  Ver 8.23 Distrib 3.23.47, for pc-linux-gnu on i686
Copyright (C) 2000 MySQL AB & MySQL Finland AB & TCX DataKonsult AB
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL license

Server version  3.23.47
Protocol version10
Connection  Localhost via UNIX socket
UNIX socket /var/lib/mysql/mysql.sock
Uptime: 22 hours 44 min 26 sec

Threads: 2  Questions: 30  Slow queries: 0  Opens: 8  Flush tables: 1  Open tables: 1 
Queries per second avg: 0.000
>Environment:
Dual P3-450, RH7.2, unknown, unknown
System: Linux titus 2.4.7-10smp #1 SMP Thu Sep 6 17:09:31 EDT 2001 i686 unknown
Architecture: i686

Some paths:  /usr/bin/perl /usr/bin/make /usr/bin/gmake /usr/bin/gcc /usr/bin/cc
GCC: Reading specs from /usr/lib/gcc-lib/i386-redhat-linux/2.96/specs
gcc version 2.96 2731 (Red Hat Linux 7.1 2.96-98)
Compilation info: CC='gcc'  CFLAGS='-O6 -fno-omit-frame-pointer -mpentium'  CXX='gcc'  
CXXFLAGS='-O6 -fno-omit-frame-pointer  -felide-constructors 
-fno-exceptions -fno-rtti -mpentium'  LDFLAGS=''
LIBC: 
lrwxrwxrwx1 root root   13 Nov 29 18:07 /lib/libc.so.6 -> libc-2.2.4.so
-rwxr-xr-x2 root root  1282588 Sep  4 12:49 /lib/libc-2.2.4.so
-rw-r--r--1 root root 27304836 Sep  4 12:34 /usr/lib/libc.a
-rw-r--r--1 root root  178 Sep  4 12:34 /usr/lib/libc.so
Configure command: ./configure  --disable-shared --with-mysqld-ldflags=-all-static 
--with-client-ldflags=-all-static --without-berkeley-db --without-innodb 
--enable-assembler --with-mysqld-user=mysql 
--with-unix-socket-path=/var/lib/mysql/mysql.sock --prefix=/ 
--with-extra-charsets=complex --exec-prefix=/usr --libexecdir=/usr/sbin 
--sysconfdir=/etc --datadir=/usr/share --localstatedir=/var/lib/mysql 
--infodir=/usr/info --includedir=/usr/include --mandir=/usr/man 
'--with-comment=Official MySQL RPM'


-
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: Retrieving a numeric series from a SELECT

2002-02-08 Thread Paul DuBois

At 15:08 -0600 2/8/02, José Angel Blanco Linares wrote:
>Hi, everybody
>
>How can I get a numeric column from a SQL SELECT statement?
>I mean, with a SELECT get something like this
>
>ColNum   or   ColNum
>   1 10
>   2 11
>   3 12
>   4 13
>   5 14
>   6 15
>   ...   ...
>
>Some time ago, somebody wrote a sample that do exactly what I need. In fact, I
>took that sample and saved it to my HD, but i can't find it, hehehe.

Do you mean you want to number the output rows from a query?

Do you mean you want to specify a beginning and ending number and
generate a series containing all the numbers from the beginning to the
end?

Or something else?

>
>TIA
>
>__
>José Angel Blanco Linares
>Depto Servicios de Apoyo Académico
>Centro de Enseñanza Técnica Industrial
>3641-3250, ext: 266

-
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: Configure-options for compiled MySQL?

2002-02-08 Thread Trond Eivind Glomsrød

John Ericson <[EMAIL PROTECTED]> writes:

> I've a compiled MySQL and I need to know if it support unixODBC (Is
> configured with --with-unixODBC=...). Is there anyway I can see which
> configure options that was used to produce the binary?


Look for MyODBC - there is a link at the MySQL web page (it's also
included in RHL 7.2)
 
-- 
Trond Eivind Glomsrød
Red Hat, Inc.

-
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: Checking the Table Size

2002-02-08 Thread Eric Mayers

Satish:

You can see how much space is used (among other things) with a query
like:

show table status from  like 'Syslog';

Increasing the maximum table size is a little more complicated and
depends on what OS and table type you're using.

Eric

> -Original Message-
> From: Satish Santhakumar [mailto:[EMAIL PROTECTED]]
> Sent: Friday, February 08, 2002 2:21 PM
> To: [EMAIL PROTECTED]
> Subject: Checking the Table Size
> 
> 
> Hi guys,
> 
>   I am not able to insert into the MySQL database
> anymore. I think it has reached the table size. How do
> i check the size to see if it has reached the table
> size? Also let me know how to increase the table size
> in case it is reached the limit.
> Thanks,
> Satish
> 
> =
> The only person in the world who is enviable is one who does 
> not envy others
> __
> Satish Santhakumar
> Graduate Student IIT, Chicago and
> Computer Programmer University of Chicago.
> 
> __
> Do You Yahoo!?
> Send FREE Valentine eCards with Yahoo! Greetings!
> http://greetings.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
> 
> 

-
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: Configure-options for compiled MySQL?

2002-02-08 Thread John Ericson

On Feb 08 23:40, John Ericson wrote:
> Hi,
> 
> I've a compiled MySQL and I need to know if it support unixODBC (Is
> configured with --with-unixODBC=...). Is there anyway I can see which
> configure options that was used to produce the binary?
> 
> 
> -- 
> * John Ericson [EMAIL PROTECTED]
> * ICQ: 7325429 JID: [EMAIL PROTECTED]
> * web: http://john.pp.se


(Please CC me since Im not a member of the maillinglist)

-- 
* John Ericson [EMAIL PROTECTED]
* ICQ: 7325429 JID: [EMAIL PROTECTED]
* web: http://john.pp.se

-
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




Configure-options for compiled MySQL?

2002-02-08 Thread John Ericson

Hi,

I've a compiled MySQL and I need to know if it support unixODBC (Is
configured with --with-unixODBC=...). Is there anyway I can see which
configure options that was used to produce the binary?


-- 
* John Ericson [EMAIL PROTECTED]
* ICQ: 7325429 JID: [EMAIL PROTECTED]
* web: http://john.pp.se

-
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




Outgoing Data ?

2002-02-08 Thread Steve Whitacre

I'm brand new to the list so forgive me if this has been covered (didn't 
see it in the archives).  Have recently installed V 3.21 onto a Windows 2k 
Pro system with no web services running and Outpost Firewall v1.0.1220.2238 
.. Last night I notices that MySQL-nt.exe was sending data out over port 
3306 while WinMySqlAdmin was listening on 1029.. Since I had loopback 
enabled, that wasn't a big concern... However, during the 5ish hours that I 
watched, almost 5MB of data went out, with less than .5MB returning.  Where 
is this data going to and why?

Steve Whitacre
Packetderm, LLC
Information Security and Privacy
www.packetderm.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




Foreign keys in InnoDB tables

2002-02-08 Thread Martin Bratbo

According to the manual it should in fact be possible to enforce foreign key 
constraint in MySql if both the referreing and referred tables are of type InnoDB. But 
I haven't been able to, make the foreign keys work, they did'nt blok any insertions.

Are foreign keys still only for compability, or is there a way to actually make the 
constraints work if the tables are InnoDB ?
 
I am running  4.0.1-alpha-max on win98
 
 
Regards
 
 
Martin Bratbo



-
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




Checking the Table Size

2002-02-08 Thread Satish Santhakumar

Hi guys,

  I am not able to insert into the MySQL database
anymore. I think it has reached the table size. How do
i check the size to see if it has reached the table
size? Also let me know how to increase the table size
in case it is reached the limit.
Thanks,
Satish

=
The only person in the world who is enviable is one who does not envy others
__
Satish Santhakumar
Graduate Student IIT, Chicago and
Computer Programmer University of Chicago.

__
Do You Yahoo!?
Send FREE Valentine eCards with Yahoo! Greetings!
http://greetings.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




update to mysql 4.01 under mandrake

2002-02-08 Thread David yahoo

hi all,

This question is a little like the suse update.
But perhaps I could find answer.

I have a mandrake distrib with rpm support, u know that mandrake is derive
from redhat.

Can I install a mysql 4.0.1 package on it ?


thanks.

a+.


_
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.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




Retrieving a numeric series from a SELECT

2002-02-08 Thread José Angel Blanco Linares

Hi, everybody

How can I get a numeric column from a SQL SELECT statement?
I mean, with a SELECT get something like this

ColNum   or   ColNum
  1 10
  2 11
  3 12
  4 13
  5 14
  6 15
  ...   ...

Some time ago, somebody wrote a sample that do exactly what I need. In fact, I 
took that sample and saved it to my HD, but i can't find it, hehehe.

TIA

__
José Angel Blanco Linares
Depto Servicios de Apoyo Académico
Centro de Enseñanza Técnica Industrial
3641-3250, ext: 266

-
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




is possible 1 query with 2 selects?

2002-02-08 Thread Nuno Teixeira


  Hello to all,
  
  I'm trying to make a query with only one command but I can't see how to do 
  it.
  
  Supose that are 2 tables like:
  
  table QA  table QB
  ref text  ref text
  ---   --- 
  a1 texta1 b1 textb1
  a2 texta2 b2 textb2
  a3 texta3 b3 textb3
  
  and there is a table that indicates the relation between QB and QA data:
  
  table relAB
  A   B
  --  --
  a1  b2  
  a1  b3
  a1  b4
  a2  b1
  a2  b2
  
  This example says that b2,b3,b4 are related to a1 and b1,b2 are 
  related to a2.
  
  What I want to do is get a list from table QB related to an item from 
  table QA:
  
For example, get a list from QB related to item 'a1':
  
1. select B from relAB where A='a1';
  
(result: b2, b3, b4)
  
2. select * from QB where ref in ('b2','b3','b4');
  
(result: only 'a1' related items)
  
  There is a way of make this query with only one command?
  
  Something like:
  
1. select * from QB where ref in (select B from relAB where A='a1');
  
  
  
  Please help me in this matter.
  
  Thanks very much,
  
  
-- 
Nuno Teixeira
pt-quorum.com

/* 
PGP Public Key:
http://www.pt-quorum.com/pgp/nunoteixeira.asc
Key fingerprint:
8C2C B364 D4DC 0C92 56F5  CE6F 8F07 720A 63A0 4FC7
*/

-
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: Default install directory

2002-02-08 Thread Luc Foisy

Depends on the install. The rpm from mysql will install to /var/lib/mysql

The worst of it, most linux default installs, /var is the smallest

Unknowing to myself, I had a database running away, default installs the
both of them (well default then some modifications )
about 2 months later, CRASH!!! Wasted the whole system (as far as I am
concerned) , mysql wasnt nice enough to stop writing when /var was full
lucky for me the database was the only thing important on that server, and a
backup was just done that morning (successfully to boot)

-Original Message-
From: Jonas Fornander [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 08, 2002 1:42 PM
To: [EMAIL PROTECTED]
Subject: Default install directory



I have a crashed computer and need the mysql databases recovered. 

What is the default installation directory and default database
directory for mysql on Mandrake 7.2?

Jonas Fornander - System Administrator
Netwood Communications, LLC - www.netwood.net
Find out why we're better - 310-442-1530


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

2002-02-08 Thread Mike McLagan

Hello,

   I hope this isn't too far afield of the list discussions but here goes.

   I'm trying to fashion a query against a MySQL database.  There are three 
tables that are relevant.  They are:

   listing (ID, OfficeID, CatID, SubID, Visible, Deleted)
   category (ID, Name)
   subcategory (ID, CatID, Name)

the ID fields are all AUTO_INCREMENT (1, 2, 3, ...). Basically what I want is:

   listing.ID, category.Name, subcategory.Name, listing.Visible

I've been messing with it for over two hours and still have not gotten the 
thing right.  The wrinkle is that listing.SubID may = 0, which has no matching 
row in table subcategory.  In that case, I'm looking for a NULL in 
subcategory.Name.  All I've managed to eek out of it is rows where SubID has a 
matching subcategory.ID.

   SELECT listing.ID, category.Name, subcategory.Name, listing.Visible
 FROM listing, category, subcategory
 WHERE Deleted="N" 
   AND OfficeID=1
   AND subcategory.ID = listing.SubID
   AND category.ID = listing.CatID
  
I have tried all manner of LEFT, RIGHT, INNER, OUTER, STRAIGHT and NATURAL 
joins.  1/2 of them spit out syntax errors or 100s of rows.  I have not managed 
to get it to handle SubID = 0 which means "None".

I'd be most grateful if someone could weave me a path thru the JOIN syntax 
(which I really don't get and the manual is not exactly clear about) and 
suggest how I might convince MySQL to spit out what I want.  

   Michael



-
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: How to duplicate a table complete with indexes? #

2002-02-08 Thread Brian Reichert

On Fri, Feb 08, 2002 at 09:09:39PM +0100, [EMAIL PROTECTED] wrote:
> Your message cannot be posted because it appears to be either spam or
> simply off topic to our filter. To bypass the filter you must include
> one of the following words in your message:
> 
> sql,query

This 'anti-spam' measure, is kinda lame, I must say.  (Picture that
said in an Ed Grimley voice.  If you understand _that_, shame on
you! :)

> If you just reply to this message, and include the entire text of it in the
> reply, your reply will go through. However, you should
> first review the text of the message to make sure it has something to do
> with MySQL. Just typing the word MySQL once will be sufficient, for example.
> 
> You have written the following:
> 
> On Fri, Feb 08, 2002 at 01:22:08PM -0600, BD wrote:
> > This works fine except it doesn't create any indexes that OldTable had. Is
> > there a generic way to duplicate a table that includes the indexes? I don't 
> > want to have to manually create indexes for it.
> 
> What's wrong with outright copying the files associated with the
> table?  (Assuming the table's not in use).  I would _assume_ that
> this would work; i havent' tested it, of course...
> 
> > TIA
> > 
> > Brent
> 
> -- 
> 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
> 

-- 
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: Exclusion Query help

2002-02-08 Thread Rick Emery

I'm trying to figure out the bloody hell you're looking for.

What is date3?  Where does it come from?
I think I speak for most folks here when I say...

What is date4?  Where does it come from?
What is date4?  Where does it come from?
Why is record 2 good, but not record 3?
How does Phase enter into the selection of record 2?

-Original Message-
From: John Rosendahl [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 08, 2002 12:53 PM
To: [EMAIL PROTECTED]
Subject: Exclusion Query help


I am trying to run a query I have a table Records

|Record_ID|
|Phase_ID  |
|Record_Date|


I need to find the records that have a record date between date1 and 
date 2 but exclude the records with a matching Phase_ID that opccured 
between date3 and date 4

so if I had the following table
Record_IDPhase_IDRecord_Date
1   11/01/01
2314/01/01
3114/01/01


I would want want the query to return only Record number 2
(Given that 1/01/01 is between date 3 & 4 and 14/01/01 is between date 1 
& 2)

Does anyone know how to do this?

mySQL, SQL



-
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




Exclusion Query help

2002-02-08 Thread John Rosendahl

I am trying to run a query I have a table Records

|Record_ID|
|Phase_ID  |
|Record_Date|


I need to find the records that have a record date between date1 and 
date 2 but exclude the records with a matching Phase_ID that opccured 
between date3 and date 4

so if I had the following table
Record_IDPhase_IDRecord_Date
1   11/01/01
2314/01/01
3114/01/01


I would want want the query to return only Record number 2
(Given that 1/01/01 is between date 3 & 4 and 14/01/01 is between date 1 
& 2)

Does anyone know how to do this?

mySQL, SQL



-
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




Updating to MySQL MAX 4.0.1 on SuSE 7.0

2002-02-08 Thread rck

Hello!

I've been trying to install the binary distribution of MySQL MAX
4.0.1 but have spotted a problem: The directory structure is completely
different to my existing SuSE 7.0 MySQL 3 installation!

Is there any script that would upgrade my old installation to
MySQL MAX 4.0.1 in the same structure as MySQL 3?

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: How to duplicate a table complete with indexes? #

2002-02-08 Thread Paul DuBois

At 13:22 -0600 2/8/02, BD wrote:
>At 10:34 AM 2/8/2002 , you wrote:
>
>Quite often I'd like to duplicate an existing table using SQL. 
>Normally I'd do a
>
>create table NewTable select * from OldTable;
>
>and if I don't want any data transferred I'll slap on a Limit 0 on the end
>of the statement.
>
>This works fine except it doesn't create any indexes that OldTable had. Is
>there a generic way to duplicate a table that includes the indexes? 
>I don't want to have to manually create indexes for it.

Not using just SQL, no.  In a program, you can get the output from a
SHOW CREATE TABLE statement, perform a substitution to change the
table name, then execute the statement.  That will create a copy (empty) that
includes the indexes.

>
>TIA
>
>Brent


-
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 duplicate a table complete with indexes? #

2002-02-08 Thread BD

At 10:34 AM 2/8/2002 , you wrote:

Quite often I'd like to duplicate an existing table using SQL. Normally I'd 
do a

create table NewTable select * from OldTable;

and if I don't want any data transferred I'll slap on a Limit 0 on the end
of the statement.

This works fine except it doesn't create any indexes that OldTable had. Is
there a generic way to duplicate a table that includes the indexes? I don't 
want to have to manually create indexes for it.

TIA

Brent


-
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 must ask. also ...

2002-02-08 Thread DL Neil

Ferreira,
[I have posted this back to the list. There are many others who will be able to help - 
some from Portugal. Also
I have noticed questions and comments from many people working on 
collections/libraries of CDs, videos, books,
etc]

> Thack for all that knowleg... ( wisdonw )
> pardon my englihs

=please do not feel it necessary to apologise - your ability to write in English is 
much better than mine in
Portugese!

> in this case, and before the big databank, i am tring to build a DB to
> organise my cds.
> I have 6 tables.
> Table Principal has:
> a "id" and for exmple "tipo" ( type).
>
> Table Tipo (Type ) has:
> a "idT" and Descrição ( description).
>
> my question:
> in table Principal e call the column tipo has "idT" and i have a relation?
> or i just call it "Tipo" and manualy work on it so it can get the values i
> have on the other table ?
>
> ( I am a self-teacher all i know i read it somewere sorry if the questions
> are dull )

=it's trying to keep the answers from sounding dull, that is challenging!

=yes I think you have the correct answer. When you define the two tables (using a 
CREATE statement) there is no
need to specify/hard-code, some linkage between them. When you populate the tables 
with data, the data-values
will make apparent/show the linkages (field(s) to field(s) and thus row(s) to row(s))

=the two tables Principal and Tipo are logically related - logic demands that there be 
no entry in
Principal.tipo that does not have a corresponding entry in the Tipo table. (this is 
called "data integrity"). So
we can write a SELECT (or other) command to only work with data within this 
correspondence/relationship, eg

... WHERE Principal.tipo = Tipo.idT

=from there (for two examples), we can ask to see only CDs of a certain type, or we 
can ask for a list of all
the CDs purchased during 1999 (assuming relevant data columns are available) organised 
into groups by
type/tipo - simply by adding more conditions/constraints into the WHERE clause (etc).

=thus it is not when you CREATE the tables that the linkage is specified, but each 
query that you run against
the tables can/must specify the linkage (and therefore you can relate different tables 
at different times, even
in different ways at different times). Relationships are/can be 'dynamic', rather than 
constant/'fixed' at table
creation time.

=if you want to demand a data integrity feature, whilst it is not available in 
native-MySQL, it is available in
one of the add-on components.

> Thancks in advance.

=my pleasure - and don't hesitate to request clarification if my choice of English 
words is not readily
understandable.
=dn



> > I am playing hard with mysql, cause my ultimate objective is to make a big
> > databank for a game.
> >
> > I notice that i cant find a way to make relations beteen tables.
> > Must i do it also with PHP ?
>
>
> Just to confuse you, the mathematical jargon for table is "relation"...
>
> May I suggest that you search the web for some tutorials on the use of SQL
> in general/MySQL in particular - it
> will help your playing, and ultimately your game.
>
> There are some RDBMS-es that implement SQL to the point of apparently
> setting up a construct that links tables -
> foreign key based data integrity being the first example that springs to
> (my) mind. However relational logic
> suggests that the way to set up a linkage between tables is to show this in
> dynamic logic - your SQL statement,
> eg
>
> SELECT *
> FROM tbl1, tbl2
> WHERE tbl1.PrimaryKey = tbl2.ForeignKey;
>
> will produce a result-row for every intersection 'match' between the two
> tables.
>
> One of the MAJOR advances of relational databases over their predecessors
> was this move 'away' from structural
> 'connections'. However these have been maintained as 'features' by some,
> usually to promote speed/efficiency.
> Perhaps this is a major interest for you/gaming - but in which case, you
> will find that indexed-file systems
> will likely be a better/faster/smaller option. (?)
>
> An original objective, and one well worth bearing in mind today, is that
> relational technology allows one to
> establish a 'relationship' between items of data today, that was not
> anticipated/designed into the system when
> it was first built n-years ago. Flexibility!
>
> Regards,
> =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: MySQL won't start...

2002-02-08 Thread Eric Mayers

Joe, 

When you start mysql (presumably with safe_mysqld), you must tell it
where your datafiles are.

Try bin/safe_mysqld --datadir=/var/lib/mysql/mysql

Eric


> -Original Message-
> From: FISHER,JOE (Non-HP-Roseville,ex1)
> [mailto:[EMAIL PROTECTED]]
> Sent: Friday, February 08, 2002 11:01 AM
> To: '[EMAIL PROTECTED]'
> Subject: MySQL won't start...
> 
> 
> I have 2 SuSE Linux 7.2 machines at home...  These boxes have 
> completely
> different hardware in each... But the O/S on each, contains 
> virtually all of
> the same applications...
> 
> On the first machine, MySQL started right up, and has been 
> working correctly
> ever since...
> 
> On the second machine, MySQL will NOT start...
> 
> It tries to start, but keeps aborting...
> 
> Here are the only messages that I can seem to find:
> 
>   020126 18:01:29  mysqld started
>   020126 18:01:29  /usr/sbin/mysqld: Table 'mysql.host' 
> doesn't exist
>   020126 18:01:29  mysqld ended
>   020126 18:04:56  mysqld started
>   020126 18:04:57  /usr/sbin/mysqld: Can't find file:
> './mysql/host.frm' (errno: 13)
>   020126 18:04:57  mysqld ended
>   020126 18:07:31  mysqld started
>   020126 18:07:31  /usr/sbin/mysqld: Can't find file:
> './mysql/host.frm' (errno: 13)
> 
> Each time I try to restart, I get the above messages...
> 
> If anyone can point me to some specific log files, that would 
> help to debug
> this problem further, I would much appreciate it...
> 
> my.cnf is locate in /etc, as it's supposed to be...
> 
> host.frm exists, but it exists in the following location: 
> (I'm thinking that
> something in /usr/sbin/mysqld isn't pointing to the file...)
> 
>   /var/lib/mysql/mysql/host.frm 
> 
> Is there a configuration file someplace, that I can modify to 
> point to this
> host.frm file?
> 
> If so, what is the correct command, including syntax?
> 
> TIA
> 
> Joe F.
> 
> -
> 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: Distributed Fulltext?

2002-02-08 Thread James Montebello


For the slice servers, you simply assume that if one is lost, you lose X%
of the data until it is revived, which is usually not even noticable by
the end user.  For the aggregators, we had four behind a load-balancer.
In practice, we had nearly zero downtime over a roughly 18 month period.

james montebello

On 7 Feb 2002, Amir Aliabadi wrote:

> How do you make something like this fault tolerant?
> The answer is probably what I suspect, 2 of every thing.
> How does the aggregator handle this or are these machines in a cluster?
> 
> We are thinking of how to rebuild our fulltext search.  Currently it is
> in MS SQL 7.0 -  MySQL 4.0 seems to blow the doors off the cataloging
> time as compaired to MS SQL 7.0 Or even 8.0.
> 
> 
> On Thu, 2002-02-07 at 15:19, James Montebello wrote:
> > 
> > I did this at a previous job, and we split the data up more or less
> > this way (we used a pre-existing item number for the split which was
> > essentially random in relation to the text data), with a aggregator that
> > did the query X ways, each to a separate box holding 1/X of the data.
> > The results from each unit were paged and sorted, so all the aggregator
> > did was do a simple merge sort on a "page" of the set, which was fast.
> > On a 6M record dataset, it produced millisecond-range search results.
> > Not exactly Google-class, but pretty good for 12 Linux boxes, two
> > programmers, and about six weeks of effort.
> > 
> > james montebello
> > 
> > On Thu, 7 Feb 2002, Brian Bray wrote:
> > 
> > > 
> > > It seems to me like the best solution that could be implemented as-is 
> > > would be to keep a random int column in your table (with a range of say 
> > > 1-100) and then have fulltext server 1 psudo-replicate records with a 
> > > the random number in the range of 1-10, server 2 11-20 and server 3 
> > > 21-30 and so on.
> > > 
> > > Then run your query on all 10 servers and merge the result sets and 
> > > possibly re-sort them if you use the score column.
> > > 
> > > The problem with splitting the index up by word is that is messes up all 
> > > your scoring and ranking.  For example what if you search using 5 
> > > keywords, all starting with letters from different groups?  Your going 
> > > to get pretty bad score for each match, and it could totally break 
> > > boolean searches.
> > > 
> > > --
> > > Brian Bray
> > > 
> > > 
> > > 
> > > 
> > > Brian DeFeyter wrote:
> > > > On Thu, 2002-02-07 at 15:40, Tod Harter wrote:
> > > > [snip]
> > > > 
> > > >>Wouldn't be too tough to write a little query routing system if you are using 
> > > >>perl. Use DBD::Proxy on the web server side, and just hack the perl proxy 
> > > >>server so it routes the query to several places and returns a single result 
> > > >>set. Ordering could be achieved as well. I'm sure there are commercial 
> > > >>packages out there as well. I don't see why the individual database servers 
> > > >>would need to do anything special.
> > > >>
> > > > [snip]
> > > > 
> > > > If I'm understanding you correctly, I think you're refering to routing
> > > > based on the first character of the word. That would work for cases
> > > > where the query is searching for a word that begins with a certain
> > > > character.. however fulltext searches also return results with the term
> > > > in the middle.
> > > > 
> > > > ie: a search for 'foo' could return:
> > > > foo.txt
> > > > foobar
> > > > 
> > > > but also could return:
> > > > thisisfoo
> > > > that_is_foolish
> > > > 
> > > > I could be wrong, but it's my understanding that MySQL stores it's
> > > > fulltext index based on all the 'unique words' found. For such a system
> > > > as you mentioned above, you'd probably have to create your own fulltext
> > > > indexing system to determine: a) where to store the data 'segments' and
> > > > b) how to route queries.  It seems like this could probably be done much
> > > > more efficiently inside of the server.
> > > > 
> > > >  - Brian
> > > > 
> > > > 
> > > > 
> > > > -
> > > > 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 posti

Re: Default install directory

2002-02-08 Thread Nathan Bank

It is not platform-specific so much as installation-specific. Typically, it would be in
/usr/local/mysql/data/ but that's again entirely dependant on what install you have. A 
quick "locate
mysql | grep data | more" should reveal the locations of all your database files 
quickly. If you
didn't already know, database files end with *.MYI, *.MYD, and *.frm "extensions".

# Nathan

- Original Message -
From: "Jonas Fornander" <[EMAIL PROTECTED]>
To: <>
Sent: Friday, February 08, 2002 11:42 AM
Subject: Default install directory



I have a crashed computer and need the mysql databases recovered.

What is the default installation directory and default database
directory for mysql on Mandrake 7.2?

Jonas Fornander - System Administrator
Netwood Communications, LLC - www.netwood.net
Find out why we're better - 310-442-1530


-
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




Default install directory

2002-02-08 Thread Jonas Fornander


I have a crashed computer and need the mysql databases recovered. 

What is the default installation directory and default database
directory for mysql on Mandrake 7.2?

Jonas Fornander - System Administrator
Netwood Communications, LLC - www.netwood.net
Find out why we're better - 310-442-1530


-
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: Hello! Date question....

2002-02-08 Thread DL Neil

Hi Jim,
Welcome to our relatively?relationally happy band.

> This is my first post to the list. I've been working on MySQL now for about a
> week and really like it. I have a question that I can't find in any of the
> books or how-tos.

A whole week and no post...

> When I add a line to my customer's table I need it to put today's date in the
> "indate" column. Is there anyway to do this like the auto for numbers?

You didn't mention which date format you are using. At this reference (6.2.2.2  The 
DATETIME, DATE, and
TIMESTAMP Types) you will find coverage of the automatic inserting/updating of 
TIMESTAMP values, and the
equivalent for DATE/DATETIME values.

Remember that the auto-input feature is a two-edged sword!

Regards,
=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: Hello! Date question....

2002-02-08 Thread Eric Mayers

Jim, 

What you're asking about is the "timestamp" data type.  

Look at : http://www.mysql.com/doc/D/A/DATETIME.html

In a nutshell, if you assign 'null' to a timestamp column it will put in
value of 'NOW()'.

Eric Mayers
Software Engineer

> -Original Message-
> From: Jim Hatridge [mailto:[EMAIL PROTECTED]]
> Sent: Friday, February 08, 2002 9:50 AM
> To: [EMAIL PROTECTED]
> Subject: Hello! Date question
> 
> Hi all...
> 
> This is my first post to the list. I've been working on MySQL 
> now for about a 
> week and really like it. I have a question that I can't find 
> in any of the 
> books or how-tos.
> 
> When I add a line to my customer's table I need it to put 
> today's date in the 
> "indate" column. Is there anyway to do this like the auto for numbers?

-
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 must ask.

2002-02-08 Thread Paul DuBois

At 17:40 + 2/8/02, André Ferreira wrote:
>Hello ppl.
>I am playing hard with mysql, cause my ultimate objective is to make a big
>databank for a game.
>
>I notice that i cant find a way to make relations beteen tables.

It's called a "join".  You'll find information about joins in any
number of MySQL sources, including the MySQL manual.  Check the tutorial
chapter, for example (section 3.3.4.9).

>Must i do it also with PHP ?
>
>Thanck for the tips.
>And if i am rigth, my dont gays put so relation ?

That's a very difficult sentence to understand. :-)


-
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: Hello! Date question....

2002-02-08 Thread Paul DuBois

At 18:49 +0100 2/8/02, Jim Hatridge wrote:
>Hi all...
>
>This is my first post to the list. I've been working on MySQL now for about a
>week and really like it. I have a question that I can't find in any of the
>books or how-tos.
>
>When I add a line to my customer's table I need it to put today's date in the
>"indate" column. Is there anyway to do this like the auto for numbers?
>
>Thanks!
>--
>Jim Hatridge
>Linux User #88484

I know of at least one book the answer's in:

MySQL, page 110

-
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 must ask.

2002-02-08 Thread DL Neil

Hello André


> I am playing hard with mysql, cause my ultimate objective is to make a big
> databank for a game.
>
> I notice that i cant find a way to make relations beteen tables.
> Must i do it also with PHP ?


Just to confuse you, the mathematical jargon for table is "relation"...

May I suggest that you search the web for some tutorials on the use of SQL in 
general/MySQL in particular - it
will help your playing, and ultimately your game.

There are some RDBMS-es that implement SQL to the point of apparently setting up a 
construct that links tables -
foreign key based data integrity being the first example that springs to (my) mind. 
However relational logic
suggests that the way to set up a linkage between tables is to show this in dynamic 
logic - your SQL statement,
eg

SELECT *
FROM tbl1, tbl2
WHERE tbl1.PrimaryKey = tbl2.ForeignKey;

will produce a result-row for every intersection 'match' between the two tables.

One of the MAJOR advances of relational databases over their predecessors was this 
move 'away' from structural
'connections'. However these have been maintained as 'features' by some, usually to 
promote speed/efficiency.
Perhaps this is a major interest for you/gaming - but in which case, you will find 
that indexed-file systems
will likely be a better/faster/smaller option. (?)

An original objective, and one well worth bearing in mind today, is that relational 
technology allows one to
establish a 'relationship' between items of data today, that was not 
anticipated/designed into the system when
it was first built n-years ago. Flexibility!

Regards,
=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: Problems with select

2002-02-08 Thread DL Neil

MySQL manual A.5.7  Problems with floating point comparison

=dn



- Original Message - 
From: "Gerald Clark" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: 08 February 2002 15:24
Subject: Re: Problems with select


> 15.8 has no exact binary representation, so a test for  equality will fail.
> Do not use floating point if you want to test for equality. Try DECIMAL
> 
> Miguel Figueiredo wrote:
> 
> >Hello all,
> >
> >I have a (probably dumb) question. 
> >My table "temperatura" has two fields described bellow.
> >
> >mysql> describe temperatura;
> >+-+--+--+-+-+---+
> >| Field| Type | Null | Key | Default | Extra |
> >+-+--+--+-+-+---+
> >| datetime  | datetime | YES  | | NULL|   |
> >| temperatura | float| YES  | | NULL|   |
> >+-+--+--+-+-+---+
> >2 rows in set (0.00 sec)
> >
> >
> >When I try to select rows with floats, the result is an empty set.
> >For example:
> >
> >mysql> select datetime,temperatura from temperatura where 
> >datetime="2002-02-08 09:30:00";
> >+-+-+
> >| datetime| temperatura |
> >+-+-+
> >| 2002-02-08 09:30:00 |15.8 |
> >+-+-+
> >1 row in set (0.00 sec)
> >
> >> got one row :)
> >
> >mysql>select datetime,temperatura from temperatura where datetime="2002-02-08 
> >09:30:00" and temperatura=15.8;
> >
> >Empty set (0.00 sec)
> >
> >--> same thing but with the temperatura value, gives me an empy set :(
> >
> >When I try to select another row but the temperatura field has an integer 
> >this is what happens:
> >
> >mysql> select datetime,temperatura from temperatura where 
> >datetime="2002-01-25 09:40:00";
> >+-+-+
> >| datetime| temperatura |
> >+-+-+
> >| 2002-01-25 09:40:00 |  16 |
> >+-+-+
> >1 row in set (0.00 sec)
> >
> >---> got one row :)
> >
> >mysql> select datetime,temperatura from temperatura where 
> >datetime="2002-01-25 09:40:00" and temperatura=16;
> >+-+-+
> >| datetime| temperatura |
> >+-+-+
> >| 2002-01-25 09:40:00 |  16 |
> >+-+-+
> >1 row in set (0.00 sec)
> >
> >--> It works now :/
> >
> >Does anyone have an idea why this happens? How can I select float numbers?
> >
> >Best wishes,
> >
> >Miguel
> >
> 
> 
> 
> -
> 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




Hello! Date question....

2002-02-08 Thread Jim Hatridge


Hi all...

This is my first post to the list. I've been working on MySQL now for about a 
week and really like it. I have a question that I can't find in any of the 
books or how-tos.

When I add a line to my customer's table I need it to put today's date in the 
"indate" column. Is there anyway to do this like the auto for numbers?

Thanks!
-- 
Jim Hatridge
Linux User #88484
--
 BayerWulf
   Linux System # 129656
 The Recycled Beowulf Project
  Looking for throw-away or obsolete computers and parts
   to recycle into a Linux super computer

-
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




Selecting Floating point numbers: Summary

2002-02-08 Thread Miguel Figueiredo

Hello again,

In reply to all the suggestions made, here it goes one more mail. I hope it 
will be helpful.

(André, isto vai em ingles que é para o pessoal perceber ;)

Suggestion 1:

>Float aren't really searchable in Mysql. You may need to do some casting,
>not sure how to do it on top but i remember reading from the Mysql help.

Couldn't find out how :((( 

Suggestion 2: 

>You forgot "" around temp example:
>mysql>select datetime,temperatura from temperatura where
>datetime="2002-02-08 09:30:00" and temperatura="15.8";

This does not work (I had tried this before of course). The output is an 
empty set :(

Suggestion 3:

>Replace the dot for a comma.

Wrongo... it does not work:

mysql> select datetime,temperatura from temperatura where 
datetime="2002-02-08 09:30:00" and temperatura=15,8;
ERROR 1064: You have an error in your SQL syntax near '8' at line 1

or (to clear everything up)

mysql> select datetime,temperatura from temperatura where 
datetime="2002-02-08 09:30:00" and temperatura="15,8";
Empty set (0.00 sec)

Suggestion 4:

>15.8 has no exact binary representation, so a test for  equality will fail.
>Do not use floating point if you want to test for equality. Try DECIMAL

Miguel, RTFM ;)
"DECIMAL and NUMERIC values are stored as string rather than a binary 
floating-point numbers, in order to preserve the decimal precision of those 
values." - MySQL Reference Manual 3.23.39 page 177.

mysql> create table temp_test (datetime datetime, temperatura DECIMAL(2,1));
mysql> insert into temp_test(datetime,temperatura) values ("2002-02-08 
09:30:00",15.8);
mysql> select datetime,temperatura from temp_test where datetime="2002-02-08 
09:30:00" and temperatura=15.8;
+-+-+
| datetime| temperatura |
+-+-+
| 2002-02-08 09:30:00 |15.8 |
+-+-+
1 row in set (0.00 sec)

weee :)

Suggestion 5:

>This is not a MySQL problem, nor a database one, but a general computer
>science one. It is
>almost never save to compare two floating point numbers for equality. The
>decimal representation
>you see in ASCII is not an exact representation but an approximation.
>Because of the
>way computers store floating point numbers in bunry and humans read them in
>decimal,
>the decimal value is alway rounded and there are invisible bits which can
>be different
>in apparently identical values. For floating point comparisons you should
>*always* use
>unequalities e.g. "WHERE temp BETWEEN 15.75 AND 15.85".

mysql> select datetime,temperatura from temperatura where 
datetime="2002-02-08 09:30:00" and temperatura between 15.75 and 15.85;
+-+-+
| datetime| temperatura |
+-+-+
| 2002-02-08 09:30:00 |15.8 |
+-+-+
1 row in set (0.00 sec)

Works :


Conclusion:

I think I will follow suggestion 4, and alter my table.
Thank for all the help guys :)

Best wishes,

Miguel

-
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 must ask.

2002-02-08 Thread André Ferreira

Hello ppl.
I am playing hard with mysql, cause my ultimate objective is to make a big
databank for a game.

I notice that i cant find a way to make relations beteen tables.
Must i do it also with PHP ?

Thanck for the tips.
And if i am rigth, my dont gays put so relation ?


-
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 setup MySql on my Solaris 8?

2002-02-08 Thread Jack Chao

I got mysql-3.23.47-sun-solaris2.8-sparc.tar from
mysql.com, then I untarred
it into /mysql.

Then I enter /mysql and did ls:

# ls
binincludescriptssql-bench
 tests
data   libshare 
support-files
#

What should I do to set it up now?  I entered
/mysql/bin and tried running
mysql, but get such an error message:

# mysql
ERROR 2002: Can't connect to local MySQL server
through socket '/tmp/mysql.sock' (2)
#

I don't get it.

Jack


__
Do You Yahoo!?
Send FREE Valentine eCards with Yahoo! Greetings!
http://greetings.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




Compile options

2002-02-08 Thread Diana Soares

Hi, 

Is there a way of knowing with wich options mysql was compiled ?
Thanx, 

-- 
Diana Soares

(sql)

-
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: Questions about MYSQL GUI

2002-02-08 Thread BD

At 08:12 AM 2/8/2002 , you wrote:
>Hi, sir/madam:
>
>I'm new to MYSQL. I'm now doing my final year project,
>and intend to use mysql as the database system.
>
>I installed the version mysql-3.23.46a-win and
>myodbc-2.50.39-nt on my computer for testing.
>
>I would like to download a MYSQL GUI for data
>management instead of inputing data through the DOS.
>
>Would you mind giving me some suggestions on which
>version of GUI I should dl, if
>(a) mysql is running on WIN 95?, or
>(b) mysql is running on Win NT?
>
>Thanks for your kind attention & looking forward to ur
>reply.
>
>Regards,
>Polly
>

Polly,
 Try MySQL-Front from http://www.anse.de/mysqlfront/.  I 
have it running on Win2k with no problems. You'll like the price, free! :)
 There is also MySQLMgr from http://ems-hitech.com/mymanager/ which 
comes with a 30 day eval and costs $99.

Brent


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

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




Re: Problems with select

2002-02-08 Thread Gerald Clark

15.8 has no exact binary representation, so a test for  equality will fail.
Do not use floating point if you want to test for equality. Try DECIMAL

Miguel Figueiredo wrote:

>Hello all,
>
>I have a (probably dumb) question. 
>My table "temperatura" has two fields described bellow.
>
>mysql> describe temperatura;
>+-+--+--+-+-+---+
>| Field| Type | Null | Key | Default | Extra |
>+-+--+--+-+-+---+
>| datetime  | datetime | YES  | | NULL|   |
>| temperatura | float| YES  | | NULL|   |
>+-+--+--+-+-+---+
>2 rows in set (0.00 sec)
>
>
>When I try to select rows with floats, the result is an empty set.
>For example:
>
>mysql> select datetime,temperatura from temperatura where 
>datetime="2002-02-08 09:30:00";
>+-+-+
>| datetime| temperatura |
>+-+-+
>| 2002-02-08 09:30:00 |15.8 |
>+-+-+
>1 row in set (0.00 sec)
>
>> got one row :)
>
>mysql>select datetime,temperatura from temperatura where datetime="2002-02-08 
>09:30:00" and temperatura=15.8;
>
>Empty set (0.00 sec)
>
>--> same thing but with the temperatura value, gives me an empy set :(
>
>When I try to select another row but the temperatura field has an integer 
>this is what happens:
>
>mysql> select datetime,temperatura from temperatura where 
>datetime="2002-01-25 09:40:00";
>+-+-+
>| datetime| temperatura |
>+-+-+
>| 2002-01-25 09:40:00 |  16 |
>+-+-+
>1 row in set (0.00 sec)
>
>---> got one row :)
>
>mysql> select datetime,temperatura from temperatura where 
>datetime="2002-01-25 09:40:00" and temperatura=16;
>+-+-+
>| datetime| temperatura |
>+-+-+
>| 2002-01-25 09:40:00 |  16 |
>+-+-+
>1 row in set (0.00 sec)
>
>--> It works now :/
>
>Does anyone have an idea why this happens? How can I select float numbers?
>
>Best wishes,
>
>Miguel
>



-
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: Distributed Fulltext?

2002-02-08 Thread Steve Rapaport

Ooops, factual error:

> > If, say, Google, can search 2 trillion web pages, averaging say 70k
> > bytes each, in 1 second, and Mysql can search 22 million records, with
> > an index on 40 bytes each, in 3 seconds (my experience) on a good day,
> > what's the order of magnitude difference?  Roughly 10^9.


Google has only 2 Billion with a B web pages.

So the order of magnitude difference is only 10^6.  But that still
leaves a mysql Fulltext search a MILLION times slower than Google.

Someone correctly pointed out today that it's not Mysql's job
to be Google, and I agree.  But it seems to me that it would be
fair for mysql to be able to handle searches in under 1 second
for databases 1 millionth the size of Google.  All I want here
is a decent flexible phone book lookup, not a search engine.

-steve

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

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




Re: Problems with select

2002-02-08 Thread alec . cawley



> I have a (probably dumb) question.
> My table "temperatura" has two fields described bellow.
>
> 
>
> When I try to select rows with floats, the result is an empty set.

This is not a MySQL problem, nor a database one, but a general computer
science one. It is
almost never save to compare two floating point numbers for equality. The
decimal representation
you see in ASCII is not an exact representation but an approximation.
Because of the
way computers store floating point numbers in bunry and humans read them in
decimal,
the decimal value is alway rounded and there are invisible bits which can
be different
in apparently identical values. For floating point comparisons you should
*always* use
unequalities e.g. "WHERE temp BETWEEN 15.75 AND 15.85".

 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: Problems with select

2002-02-08 Thread admin

Hi.

You forgot "" around temp example:
mysql>select datetime,temperatura from temperatura where
datetime="2002-02-08 09:30:00" and temperatura="15.8";

Regards
/PM\
Miguel Figueiredo wrote:
> 
> Hello all,
> 
> I have a (probably dumb) question.
> My table "temperatura" has two fields described bellow.
> 
> mysql> describe temperatura;
> +-+--+--+-+-+---+
> | Field| Type | Null | Key | Default | Extra |
> +-+--+--+-+-+---+
> | datetime  | datetime | YES  | | NULL|   |
> | temperatura | float| YES  | | NULL|   |
> +-+--+--+-+-+---+
> 2 rows in set (0.00 sec)
> 
> When I try to select rows with floats, the result is an empty set.
> For example:
> 
> mysql> select datetime,temperatura from temperatura where
> datetime="2002-02-08 09:30:00";
> +-+-+
> | datetime| temperatura |
> +-+-+
> | 2002-02-08 09:30:00 |15.8 |
> +-+-+
> 1 row in set (0.00 sec)
> 
> > got one row :)
> 
> mysql>select datetime,temperatura from temperatura where datetime="2002-02-08
> 09:30:00" and temperatura=15.8;
> 
> Empty set (0.00 sec)
> 
> --> same thing but with the temperatura value, gives me an empy set :(
> 
> When I try to select another row but the temperatura field has an integer
> this is what happens:
> 
> mysql> select datetime,temperatura from temperatura where
> datetime="2002-01-25 09:40:00";
> +-+-+
> | datetime| temperatura |
> +-+-+
> | 2002-01-25 09:40:00 |  16 |
> +-+-+
> 1 row in set (0.00 sec)
> 
> ---> got one row :)
> 
> mysql> select datetime,temperatura from temperatura where
> datetime="2002-01-25 09:40:00" and temperatura=16;
> +-+-+
> | datetime| temperatura |
> +-+-+
> | 2002-01-25 09:40:00 |  16 |
> +-+-+
> 1 row in set (0.00 sec)
> 
> --> It works now :/
> 
> Does anyone have an idea why this happens? How can I select float numbers?
> 
> Best wishes,
> 
> Miguel
> 
> -
> 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: InnoDB foreign keys crash MySQL

2002-02-08 Thread Heikki Tuuri

Harald,

I tested now with the official Linux binary of 4.0.1 (not -max) and it
worked ok on our dual Xeon Linux-2.4.16-SMP-64GB. I did not define any
InnoDB startup options in my.cnf.

When you recreated the InnoDB data files, did you remember to remove the
.frm files of the InnoDB tables t1, t2, t3 in the database directory 'test'?

What is your my.cnf like?

Regards,

Heikki


heikki@donna:~/mysql-4.0.1-alpha-pc-linux-gnu-i686/bin> mysqld
InnoDB: The first specified data file ./ibdata1 did not exist:
InnoDB: a new database to be created!
InnoDB: Setting file ./ibdata1 size to 64 MB
InnoDB: Database physically writes the file full: wait...
InnoDB: Log file ./ib_logfile0 did not exist: new to be created
InnoDB: Setting log file ./ib_logfile0 size to 5 MB
InnoDB: Log file ./ib_logfile1 did not exist: new to be created
InnoDB: Setting log file ./ib_logfile1 size to 5 MB
InnoDB: Doublewrite buffer not found: creating new
InnoDB: Doublewrite buffer created
InnoDB: Creating foreign key constraint system tables
InnoDB: Foreign key constraint system tables created
020208 16:31:36  InnoDB: Started
020208 16:31:36  mysqld: Table 'mysql.func' doesn't exist
020208 16:31:36  Can't open mysql/func table
mysqld: ready for connections



heikki@donna:~/mysql-4.0.1-alpha-pc-linux-gnu-i686/bin> mysql test
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1 to server version: 4.0.1-alpha

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

mysql>
mysql>
mysql> CREATE TABLE t1 (id INT UNSIGNED NOT NULL AUTO_INCREMENT,
-> PRIMARY KEY (id)  ) TYPE=InnoDB;
Query OK, 0 rows affected (0.00 sec)

mysql>
mysql> CREATE TABLE t2 (
-> id INT UNSIGNED NOT NULL AUTO_INCREMENT,t1id INT UNSIGNED NOT
NUL
L,
-> PRIMARY KEY (id),KEY (t1id),FOREIGN KEY (t1id) REFERENCES
t1(
id)
->   ) TYPE=InnoDB;
Query OK, 0 rows affected (0.01 sec)

mysql>
mysql>
mysql> CREATE TABLE t3 (id INT UNSIGNED NOT NULL AUTO_INCREMENT,
-> t2id INT UNSIGNED NOT NULL,PRIMARY KEY (id),KEY (t2id),
-> FOREIGN KEY (t2id) REFERENCES t2(id)  ) TYPE=InnoDB;
Query OK, 0 rows affected (0.01 sec)

mysql>
..

===
020208 16:38:29 INNODB TABLE MONITOR OUTPUT
===
--
TABLE: name SYS_FOREIGN, id 0 11, columns 8, indexes 3, appr.rows 2
  COLUMNS: ID: DATA_VARCHAR DATA_ENGLISH len 0 prec 0; FOR_NAME:
DATA_VARCHAR DA
TA_ENGLISH len 0 prec 0; REF_NAME: DATA_VARCHAR DATA_ENGLISH len 0 prec 0;
N_COL
S: DATA_INT len 4 prec 0; DB_ROW_ID: DATA_SYS DATA_ROW_ID len 6 prec 0;
DB_TRX_I
D: DATA_SYS DATA_TRX_ID len 6 prec 0; DB_ROLL_PTR: DATA_SYS DATA_ROLL_PTR
len 7
prec 0;
  INDEX: name ID_IND, table name SYS_FOREIGN, id 0 11, fields 1/6, type 3
   root page 46, appr.key vals 2, leaf pages 1, size pages 1
   FIELDS:  ID DB_TRX_ID DB_ROLL_PTR FOR_NAME REF_NAME N_COLS
  INDEX: name FOR_IND, table name SYS_FOREIGN, id 0 12, fields 1/2, type 0
   root page 47, appr.key vals 2, leaf pages 1, size pages 1
   FIELDS:  FOR_NAME ID
  INDEX: name REF_IND, table name SYS_FOREIGN, id 0 13, fields 1/2, type 0
   root page 48, appr.key vals 2, leaf pages 1, size pages 1
   FIELDS:  REF_NAME ID
--
TABLE: name SYS_FOREIGN_COLS, id 0 12, columns 8, indexes 1, appr.rows 2
  COLUMNS: ID: DATA_VARCHAR DATA_ENGLISH len 0 prec 0; POS: DATA_INT len 4
prec
0; FOR_COL_NAME: DATA_VARCHAR DATA_ENGLISH len 0 prec 0; REF_COL_NAME:
DATA_VARC
HAR DATA_ENGLISH len 0 prec 0; DB_ROW_ID: DATA_SYS DATA_ROW_ID len 6 prec 0;
DB_
TRX_ID: DATA_SYS DATA_TRX_ID len 6 prec 0; DB_ROLL_PTR: DATA_SYS
DATA_ROLL_PTR l
en 7 prec 0;
  INDEX: name ID_IND, table name SYS_FOREIGN_COLS, id 0 14, fields 2/6, type
3
   root page 49, appr.key vals 2, leaf pages 1, size pages 1
   FIELDS:  ID POS DB_TRX_ID DB_ROLL_PTR FOR_COL_NAME REF_COL_NAME
--
TABLE: name test/innodb_table_monitor, id 0 18, columns 5, indexes 1,
appr.rows
0
  COLUMNS: a: DATA_INT len 4 prec 0; DB_ROW_ID: DATA_SYS DATA_ROW_ID len 6
prec
0; DB_TRX_ID: DATA_SYS DATA_TRX_ID len 6 prec 0; DB_ROLL_PTR: DATA_SYS
DATA_ROLL
_PTR len 7 prec 0;
  INDEX: name GEN_CLUST_INDEX, table name test/innodb_table_monitor, id 0
20, fi
elds 0/4, type 1
   root page 55, appr.key vals 0, leaf pages 1, size pages 1
   FIELDS:  DB_ROW_ID DB_TRX_ID DB_ROLL_PTR a
--
TABLE: name test/t1, id 0 13, columns 5, indexes 1, appr.rows 0
  COLUMNS: id: DATA_INT len 4 prec 0; DB_ROW_ID: DATA_SYS DATA_ROW_ID len 6
prec
 0; DB_TRX_ID: DATA_SYS DATA_TRX_ID len 6 prec 0; DB_ROLL_PTR: DATA_SYS
DATA_ROL
L_PTR len 7 prec 0;
  INDEX: name PRIMARY, table name test/t1, id 0 15, fields 1/3, type 3
   root page 50, appr.key vals 0, leaf pages 1, size pages 1
   FIELDS:  id DB_TRX_ID DB_ROLL_PTR
  FOREIGN KEY CONSTRAINT 0_15: test/t2 ( t1id )
   

Fw: Problem with length of String with 4.0.1

2002-02-08 Thread Jostein Solstad

I might add this bit of information.

What i was trying to do worked with
version 3.23.37
It did NOT work with
version 4.0.1-alpha-nt

Regards
Jostein

- Original Message -
From: "Jostein Solstad" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, February 08, 2002 3:45 PM
Subject: Problem with length of String with 4.0.1

> Hello. I was adviced to write to you about this from an experiensed mySQL
> user, as this might be a bug in 4.0.0
>
> Im trying to do this:
>
> select col1,col2,col3,'text' as name from tabel where blahblah
> now, this would add 'text' to all rows in the result, and that works just
> fine
> but, if i try with 'elektronikksenteret' its cut off after 16 chars in the
> result.
>
> So no matter what i try to insert, if its longer then 16 chars, it will be
> cut of there.
>
> Is this a bug in the new version ? Or are there any new features that i
> might have missed.
>
> Regards
>
> Jostein Solstad
> Norbits AS
> www.norbits.no
>


-
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




MyODBC BDE invalid configuration error (BDE Error 12550)

2002-02-08 Thread Guido Sohne

We're running a MySQL 3.23.47 server on Windows 98, and when trying to
connect to BDE version 3.0 (bundled with Borland C++ Builder 1) using
MyODBC version 3.51 we get something like


Invalid configuration parameter:
Alias: database_alias

BDE Error 12550 [0x31][0x6]


I've searched the list archives and realize that some people have
occasionally come across this problem but haven't found a solution or an
indication of what the problem is ...

Borland,s web site says of BDE Error 12550


12550 Invalid configuration parameter.

One possible cause for the error:
ODBC ALIASES.
When creating and/or using a BDE alias that is using 
an ODBC DSN make sure that the ALIAS parameter "ODBC DSN" is
set to the DSN that you wish to use and that has been created 
using ODBC Manager.  Available ODBC DSN's can be chosen from 
the parameter's drop-down edit using the BDE Administrator.

Another possible cause:
Using ISAPI app and ODBC against NT web server.  
ODBC DSN on NT machine should be set to "system" 
instead of "user".


Has anyone run into this before ?






_
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.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




Problem with length of String aliases with 4.0.0

2002-02-08 Thread Jostein Solstad

Hello. I was adviced to write to you about this from an experiensed mySQL
user, as this might be a bug in 4.0.0

Im trying to do this:

select col1,col2,col3,'text' as name from tabel where blahblah
now, this would add 'text' to all rows in the result, and that works just
fine
but, if i try with 'elektronikksenteret' its cut off after 16 chars in the
result.

So no matter what i try to insert, if its longer then 16 chars, it will be
cut of there.

Is this a bug in the new version ? Or are there any new features that i
might have missed.

Regards

Jostein Solstad
Norbits AS
www.norbits.no


-
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: INSERTing duplicate values to a UNIQUE-indexed table

2002-02-08 Thread Kalok Lo

I want to thank everyone for their contributions on this thread,and
especially Erik for posting the question.
I'm in the middle of the problem, and was about to write excessive code
using Erik's suggestion No.1.
Thank you, thank you to all.


- Original Message -
From: "Erik Price" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, February 04, 2002 1:10 PM
Subject: INSERTing duplicate values to a UNIQUE-indexed table


> Hello, everyone.
>
> I have a slight dilemma, and was wondering what the standard workaround
> is.  I have three tables: owners (auto_increment primary key is
> "owners_id"), objects (auto_increment primary key is "objects_id"), and
> owners_objects (which is a foreign key table that I created, under
> advice from someone on this list a while back whose email address has
> changed -- there are two columns in owners_objects: "owners_id" and
> "objects_id", and there are two unique indexes on the table,
> "owners_id / objects_id" and "objects_id / owners_id" -- this is to keep
> duplicates combinations in this table, since they would only take up
> extra disk space).
>
> I am designing an application in PHP which stores the relationship
> between an Owner and an Object using the owners_objects table in a
> many-to-many relationship.  When someone adds a new owner, they can
> choose from an HTML listbox any number of objects to associate with that
> owner.  The PHP code creates an INSERT statement that inserts the data
> into "owners", and then takes the auto_incremented primary key of the
> last insert (which is the insert into "owners") and uses that as the
> value for the second INSERT statemetn: to insert into
> "owners_objects.owner_id".  In this second INSERT statement, the
> "objects_id" of the Object(s) selected from the listbox go into the
> second column of "owners_objects".
>
> I am sure that many people have done this sort of setup.  But what do
> you do to get around the problem of INSERTing a pair of values that
> already exist?  Because the combinations in "owners_objects" are UNIQUE
> (the UNIQUE indexes), MySQL won't accept a pair that is already
> present.  I see two possible options:
>
> 1) Check to see if the combination is already present, and if so, do not
> run the INSERT query
> 2) run the INSERT query regardless and suppress the error message
>
> The disadvantage of the first one is that it adds an extra SQL query to
> the process.  The disadvantage of the second one is that I think it is
> somewhat tasteless to execute code that will knowingly error -- or
> should I just stop trying to be such a perfectionist?
>
> I would post code but this is all pseudocode right now b/c I haven't
> solved this dilemma yet -- all experimentation with this has been done
> from the mysql client.
>
> Thanks for your advice!
>
>
> Erik
>
>
> -
> 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




Problems with select

2002-02-08 Thread Miguel Figueiredo

Hello all,

I have a (probably dumb) question. 
My table "temperatura" has two fields described bellow.

mysql> describe temperatura;
+-+--+--+-+-+---+
| Field| Type | Null | Key | Default | Extra |
+-+--+--+-+-+---+
| datetime  | datetime | YES  | | NULL|   |
| temperatura | float| YES  | | NULL|   |
+-+--+--+-+-+---+
2 rows in set (0.00 sec)


When I try to select rows with floats, the result is an empty set.
For example:

mysql> select datetime,temperatura from temperatura where 
datetime="2002-02-08 09:30:00";
+-+-+
| datetime| temperatura |
+-+-+
| 2002-02-08 09:30:00 |15.8 |
+-+-+
1 row in set (0.00 sec)

> got one row :)

mysql>select datetime,temperatura from temperatura where datetime="2002-02-08 
09:30:00" and temperatura=15.8;

Empty set (0.00 sec)

--> same thing but with the temperatura value, gives me an empy set :(

When I try to select another row but the temperatura field has an integer 
this is what happens:

mysql> select datetime,temperatura from temperatura where 
datetime="2002-01-25 09:40:00";
+-+-+
| datetime| temperatura |
+-+-+
| 2002-01-25 09:40:00 |  16 |
+-+-+
1 row in set (0.00 sec)

---> got one row :)

mysql> select datetime,temperatura from temperatura where 
datetime="2002-01-25 09:40:00" and temperatura=16;
+-+-+
| datetime| temperatura |
+-+-+
| 2002-01-25 09:40:00 |  16 |
+-+-+
1 row in set (0.00 sec)

--> It works now :/

Does anyone have an idea why this happens? How can I select float numbers?

Best wishes,

Miguel

-
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: What is ROWNUM of oracle in mysql

2002-02-08 Thread Kalok Lo

not the exact equivalent but if you are looking at a query like:
select * from mytable where rownum=8;

you can do :
select * from mytable limit 7,1

select query ..
[LIMIT [offset,] rows]

http://www.mysql.com/doc/S/E/SELECT.html

- Original Message -
From: "Ramaraju.R.V" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, February 05, 2002 5:17 AM
Subject: What is ROWNUM of oracle in mysql


> Hi,
>
> What is the alternative in mysql for ROWNUM of Oracle?
>
> Thanks,
> Rama Raju
>
> -
> 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




storage usage

2002-02-08 Thread Victoria Reznichenko

Sommai,

Friday, February 08, 2002, 8:28:50 AM, you wrote:

SF> Hi,
SF> I have some text file (10MB per day) might be keep for a year.  I have 
SF> been keep it in compress format (using WinZip).  When I need to see detail 
SF> I have been open it and find something I want to see.  If I decide to store 
SF> these text file in to BLOB field of MySQL.  How do you thing about this idea?

It depends on your needs, possibilities and expected traffic of
queries. Storing of link to the file is more easier, but MySQL is fast
and using BLOB field might be suitable for you.

SF> Sommai




-- 
For technical support contracts, goto https://order.mysql.com/
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: InnoDB foreign keys crash MySQL

2002-02-08 Thread Heikki Tuuri

Harald,

I tested the below with 3.23.48, and it worked ok.

Could it be that you have not used DROP TABLE or DROP DATABASE to remove
InnoDB tables? Then the internal data dictionary may be out-of-sync from the
.frm files of your tables.

Please use innodb_table_monitor (section 9.1 in
http://www.innodb.com/ibman.html ) to print the contents of the internal
data dictionary, and compare it to the .frm files you have for the tables.
Please send the output to the mailing list.

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


Harald Fuchs wrote in message ...
>(MySQL 4.0.1-alpha-Max-log, your Linux binary)
>
>The following works fine (just a slight variation of what is in the
manual):
>
>  CREATE TABLE t1 (
>id INT UNSIGNED NOT NULL AUTO_INCREMENT,
>PRIMARY KEY (id)
>  ) TYPE=InnoDB;
>
>  CREATE TABLE t2 (
>id INT UNSIGNED NOT NULL AUTO_INCREMENT,
>t1id INT UNSIGNED NOT NULL,
>PRIMARY KEY (id),
>KEY (t1id),
>FOREIGN KEY (t1id) REFERENCES t1(id)
>  ) TYPE=InnoDB;
>
>The following, however, crashes MySQL:
>
>  CREATE TABLE t1 (
>id INT UNSIGNED NOT NULL AUTO_INCREMENT,
>PRIMARY KEY (id)
>  ) TYPE=InnoDB;
>
>  CREATE TABLE t2 (
>id INT UNSIGNED NOT NULL AUTO_INCREMENT,
>t1id INT UNSIGNED NOT NULL,
>PRIMARY KEY (id),
>KEY (t1id),
>FOREIGN KEY (t1id) REFERENCES t1(id)
>  ) TYPE=InnoDB;
>
>  CREATE TABLE t3 (
>id INT UNSIGNED NOT NULL AUTO_INCREMENT,
>t2id INT UNSIGNED NOT NULL,
>PRIMARY KEY (id),
>KEY (t2id),
>FOREIGN KEY (t2id) REFERENCES t2(id)
>  ) TYPE=InnoDB;
>
>The log file says:
>
>  InnoDB: foreign constraint creation failed;
>  InnoDB: internal error number 17
>  InnoDB: Assertion failure in thread 45067 in file dict0crea.c line 1241
>  InnoDB: We intentionally generate a memory trap.
>  InnoDB: Send a detailed bug report to [EMAIL PROTECTED]
>  mysqld got signal 11;
>
>I can send you the stack trace if necessary.





-
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: OT: *nix text editor?

2002-02-08 Thread Thomas Spahni

On Mon, 4 Feb 2002, Matthew Walker wrote:

> I need to find a text editor for Linux that doesn’t load the whole file
> into memory. I need to edit a 1.5 gig text flatfile to add two lines.
> But I don’t have enough ram to open it in most programs. Can anyone
> recommend something?

  man sed

Rather obscure at the beginning but does the job.
(Filter: MySQL database table query)

Thomas Spahni


-
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: printing camera-ready mysql report

2002-02-08 Thread Thomas Spahni

On Mon, 28 Jan 2002, David S. Jackson wrote:

> I'm just starting my first MySQL db, and I'm going to want to
> print out reports from it and produce a camera-ready document.
> Has anyone done this before, using, say, Star Office or AbiWord
> or something?

David,

I go this way for high quality output:

echo "$QUERY" | mysql db | filter.sh > tempfile.tex
tex   tempfile.tex   -->  tempfile.dvi
dvips tempfile.dvi   -->  tempfile.ps

filter.sh may be quite complex. It is a shell script
(or you can use perl) launching sed or awk to produce 
the TeX source. The appendix is an example of a filter
to produce verbatim output from plain ASCII text
with fixed spacing.

Thomas Spahni

(pass the spam filter: MySQL table database query)

#!/bin/sh
# print ASCII texts "AS IS"
# this acts like a filter: taking input from stdin
# and sending output to the printer

# these are user-definable
TMPDIR="/tmp"
TMPFILE="printfile"
PRINTER="lpr -Php"

# --- no user configuration beyond this line ---

TMPDEST="${TMPDIR}/${TMPFILE}"

# just to avoid any conflicts:
# tmpfile is our lockfile at the same time
if test -e "${TMPDEST}.tex" ; then
   echo "$TMPDEST exists; aborting" >&2
   exit 1
fi

# create the necessary header first
cat > ${TMPDEST}.tex <<-'XXX'
\message{A4 paper size}%
\hsize 159.2mm %210mm - 1in * 2 for margins
\vsize 246.2mm %297mm - 1in * 2 for margins
% Define special characters for direct use
\catcode`Ç=\active  \defÇ{\c{C}}   \catcode`ü=\active  \defü{\"u}
\catcode`é=\active  \defé{\'e} \catcode`â=\active  \defâ{\^a}
\catcode`ä=\active  \defä{\"a} \catcode`à=\active  \defà{\`a}
\catcode`å=\active  \defå{{\aa}}   \catcode`ç=\active  \defç{\c{c}}
\catcode`ê=\active  \defê{\^e} \catcode`ë=\active  \defë{\"e}
\catcode`è=\active  \defè{\`e} \catcode`ï=\active  \defï{{\"\i}}
\catcode`î=\active  \defî{{\^\i}}  \catcode`ì=\active  \defì{{\`\i}}
\catcode`Ä=\active  \defÄ{\"A} \catcode`Å=\active  \defÅ{{\AA}}
\catcode`É=\active  \defÉ{\'E} \catcode`æ=\active  \defæ{{\ae}}
\catcode`Æ=\active  \defÆ{{\AE}}   \catcode`ô=\active  \defô{\^o}
\catcode`ö=\active  \defö{\"o} \catcode`ò=\active  \defò{\`o}
\catcode`û=\active  \defû{\^u} \catcode`ù=\active  \defù{\`u}
\catcode`Ö=\active  \defÖ{\"O} \catcode`Ü=\active  \defÜ{\"U}
\catcode`á=\active  \defá{\'a} \catcode`í=\active  \defí{{\'\i}}
\catcode`ó=\active  \defó{\'o} \catcode`ú=\active  \defú{\'u}
\catcode`ñ=\active  \defñ{\~n} \catcode`Ñ=\active  \defÑ{\~N}
\catcode`ß=\active  \defß{{\ss}}   \def\quest{?}
%
% strange fontsize to ensure that 80 characters make up one line
\font\vtt=cmtt10 at 10.77pt
\footline={\vtt\hfil - \the\pageno\ -\hfil}
%
\def\uncatcodespecials{\def\do##1{\catcode`##1=12 } \dospecials}
\def\setupverbatim{%
\par \vtt \spaceskip=0pt % Make sure we get fixed vtt spacing
\obeylines\uncatcodespecials\obeyspaces\verbatimdefs}
% This macro turns on verbatim mode until ?endverbatim is seen.
\def\verbatim{\begingroup \setupverbatim
  \parskip=0pt plus .05\baselineskip \parindent=0pt
   \catcode`\ =13 \catcode`\^^M=13 \catcode`\?=0
   \verbatimgobble}
{\catcode`\^^M=13{\catcode`\ =13\gdef\verbatimdefs{\def^^M{\ \par}\let =\ }}
  \gdef\verbatimgobble#1^^M{}}
% This defines ?endverbatim to end the group which begins with \verbatim
\let\endverbatim=\endgroup
\let\|=\relax
\verbatim
XXX
#echo -e "\n" >> ${TMPDEST}.tex

# now add what we get from stdin
cat - | sed -e "s/?/?quest?|/g" >> ${TMPDEST}.tex

# add the tail
cat >> ${TMPDEST}.tex <<-'XXX'
?endverbatim
\vfill\eject
\end
XXX

sync

(cd $TMPDIR && tex ${TMPFILE}.tex)

if test -r "${TMPDIR}/${TMPFILE}.dvi" ; then
   (cd $TMPDIR && dvips $DVIARGS ${TMPFILE}.dvi)
   $PRINTER "${TMPDIR}/${TMPFILE}.ps"
fi

# clean up

(cd $TMPDIR && rm -f \
  ${TMPFILE}.tex ${TMPFILE}.log ${TMPFILE}.dvi ${TMPFILE}.ps)


-
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 
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php




RE: long query on php

2002-02-08 Thread savaidis

Surprisingly it is mote than 64 KB! (I count strlen=74KB)
Bravo!!

Makis


> -Original Message-
> From: savaidis [mailto:[EMAIL PROTECTED]]
> Sent: Friday, February 08, 2002 9:08 AM
> To: [EMAIL PROTECTED]; 'Nathan'
> Cc: 'MySQL'
> Subject: RE: long query on php
> 
> 
> 
> Just a comment:
> Doing so it's possible to insert a line between $query.. 
> statements.
> (comments ecc) Its very simple to write it with copy+paste 
> and I prefer
> this.
> Thanks.
> 
> PS. I'll check the string limit and I let you know. I think 
> it has to be the
> 64KB.
> I think only Visual Basic has this high limit, no?
> 
> Makis
> 
> 
> > -Original Message-
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, February 08, 2002 3:03 AM
> > To: Nathan
> > Cc: MySQL
> > Subject: Re: long query on php
> >
> >
> > Hi.
> >
> > I prefer doing like this
> > $query = "CREATE TABLE query ";
> > $query .= "tabledef for col a,";
> > $query .= "tabledef for col b,";
> > $query .= "lots more table defs,";
> > $query .= "welcome to line 400";
> >
> > You get the point i guess
> > you can do same things many different ways in php:)
> >
> > /PM\
> >
> > Alex Aulbach wrote:
> > >
> > > Yesterday, from Nathan:
> > >
> > > > Since PHP ignores whitespace, I think this is also acceptable:
> > >
> > > PHP doesn't ignore whitespace in a quote. But your code 
> is of course
> > > correct.
> > >
> > > > $query = "CREATE TABLE query
> > > >   tabledef for col a,
> > > >   tabledef for col b,
> > > >   lots more table defs,
> > > >   .
> > > >   welcome to line 400";
> > >
> > > Another way: (without test)
> > >
> > > $bladefault=24;
> > > $query = << > > CREATE TABLE query (
> > >   idchar(2) default "24" # doublequotes work
> > >   hugo  char(2) default '24' # singlequotes work either
> > >   bla   char(2) default '$bladefault' # inline vars work
> > > ...
> > > )
> > > eoq
> > >
> > > --
> > > > How is possible to pass a long query to MySQL server with php?
> > > > I mean i.e a "create table" statement with more than 400 chars.
> > > > Have I to use shorter "create" and then "alter"?
> > >
> > > Strings in PHP can be really, really long and are binary
> > safe. Perhaps the
> > > problem is the editor?
> > >
> > > --
> > >
> > > SSilk - Alexander Aulbach - Herbipolis/Frankonia Minoris
> > >
> > >
> > 
> -
> > > Before posting, please check:
> > >http://www.mysql.com/manual.php   (the manual)
> > >http://lists.mysql.com/   (the list archive)
> > >
> > > To request this thread, e-mail <[EMAIL PROTECTED]>
> > > To unsubscribe, e-mail
> > <[EMAIL PROTECTED]>
> > > Trouble unsubscribing? Try:
> > http://lists.mysql.com/php/unsubscribe.php
> >
> > 
> -
> > Before posting, please check:
> >http://www.mysql.com/manual.php   (the manual)
> >http://lists.mysql.com/   (the list archive)
> >
> > To request this thread, e-mail <[EMAIL PROTECTED]>
> > To unsubscribe, e-mail
> > <[EMAIL PROTECTED]>
> > Trouble unsubscribing? Try: 
> http://lists.mysql.com/php/unsubscribe.php
> >
> 
> 
> -
> Before posting, please check:
>http://www.mysql.com/manual.php   (the manual)
>http://lists.mysql.com/   (the list archive)
> 
> To request this thread, e-mail <[EMAIL PROTECTED]>
> To unsubscribe, e-mail 
> <[EMAIL PROTECTED]>
> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
> 

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

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




Re: mySQL 4 - FullText searching syntax?

2002-02-08 Thread Sergei Golubchik

Hi!

On Feb 07, Alain Fontaine - Consultant and developer wrote:
> 
> <-- snip -->
> select
>   BienID
> from
>   biens
> where
>   MATCH(Notes) AGAINST('+appartemen* -lux* -prop*' IN BOOLEAN MODE)
> <-- snip -->
> 
>   This does not produce the correct result, whereas this does:
> 
> <-- snip -->
> select
>   BienID
> from
>   biens
> where
>   MATCH(Notes) AGAINST('appartemen*' IN BOOLEAN MODE)
> AND
>   NOT MATCH(Notes) AGAINST('lux*' IN BOOLEAN MODE)
> AND
>   NOT MATCH(Notes) AGAINST('prop*' IN BOOLEAN MODE)
> <-- snip -->

That looks like a bug, can you create a test case for it ?

Regards,
Sergei

-- 
MySQL Development Team
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /   Sergei Golubchik <[EMAIL PROTECTED]>
 / /|_/ / // /\ \/ /_/ / /__  MySQL AB, http://www.mysql.com/
/_/  /_/\_, /___/\___\_\___/  Osnabrueck, Germany
   <___/

-
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




my.cnf

2002-02-08 Thread Victoria Reznichenko

Demirchyan,

Thursday, February 07, 2002, 8:39:05 PM, you wrote:


DOA> There used to be a section in mysql documentation, which explained about all the 
DOA> entries in my.ini file.  Do you know what happened to it?
DOA> There is a part about my.cnf but that's not what I want.  There was more.

Look at:
 http://www.mysql.com/doc/O/p/Option_files.html
You can refer to:
 http://www.mysql.com/doc/C/o/Command-line_options.html
and
 http://www.mysql.com/doc/S/e/Server_parameters.html




-- 
For technical support contracts, goto https://order.mysql.com/
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




SELECT query with TRIM and LIKE

2002-02-08 Thread Victoria Reznichenko

Tshering,

Wednesday, February 06, 2002, 7:29:11 AM, you wrote:

TN> Dear list,
TN> I have a telephone database which has "Name" as one of the fields/columns.
TN> This field contains single name  e.g Robert,  double names e.g Robert
TN> Downing and more than double names.  I want to make a SELECT query using a
TN> form whose input name is "Name" i.e '$Name' against the "Name" field in the
TN> database. One can type a part/full of one part of the name, or part/full of
TN> two parts of a name and goes on likewise for more than double names in the
TN> input form.

TN> I believe this SELECT query is accomplished using TRIM and LIKE, something
TN> like:

TN> $query = ("SELECT * from table_name where Name like '%" & Trim($Name) & "%'
TN> ");

TN> This $query is not working.
TN> Could sombody please provide me a query statement that I could use for my
TN> above requirement.

Regular expressions will be useful for you, look at:
http://www.mysql.com/doc/S/t/String_comparison_functions.html
http://www.mysql.com/doc/R/e/Regexp.html

TN> Thank you so much.
TN> NOBBY




-- 
For technical support contracts, goto https://order.mysql.com/
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




GRANT command (ERROR 1047)

2002-02-08 Thread Egor Egorov

Joachim,

Thursday, February 07, 2002, 11:18:43 AM, you wrote:

JH> I am using the following versions of mysql on suse linux 7.2:
JH> frontend:   mysql  Ver 11.15 Distrib 3.23.47, for pc-linux-gnu (i686)  
JH> server: version  3.23.47 

JH> If I try to use the GRANT command I get 
JH> #mysql -u root mysql
JH> mysql> GRANT ALL ON *.* TO root@localhost
JH> -> IDENTIFIED BY 'password' WITH GRANT OPTION;
JH> ERROR 1047: Unknown command

JH> Any idea? Thanks!

If you started mysqld with --skip-grant-tables, you can do FLUSH
PRIVILEGES or run "mysqladmin reload". Look at: 
http://www.mysql.com/doc/R/e/Resetting_permissions.html





-- 
For technical support contracts, goto https://order.mysql.com/
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




RES: Backup Database MySQL to a Tape Backup

2002-02-08 Thread Egor Egorov

Andre,

Thursday, February 07, 2002, 8:57:51 PM, you wrote:

AS> Ok.
AS> My hardware hangup and i installing a new server.
AS> Howto i restore from tape to a new instalation.

If you did backup using mysqldump, you should use mysql client. 
If you did direct backup of data files, you should go with:

mysqladmin shutdown

Then copy files that contains tables to mysql data dir,
refresh permissions and run mysql: 

safe_mysqld &.

AS> André Sartori
AS> [EMAIL PROTECTED]





-- 
For technical support contracts, goto https://order.mysql.com/
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




corrupt table

2002-02-08 Thread ashley pestkowski

Hi,
 I seem to be having a problem with a corrupt table.

# myisamchk --fast --silent /var/lib/mysql/HNCandidate/Candidate.MYI

myisamchk: MyISAM file /var/lib/mysql/HNCandidate/Candidate.MYI
myisamchk: warning: 1 clients is using or hasn't closed the table properly
myisamchk: error: Recordlink that points outside datafile at 759250856
MyISAM-table '/var/lib/mysql/HNCandidate/Candidate.MYI' is corrupted
Fix it using switch "-r" or "-o"

After getting this message I ran...
myisamchk -r --safe-recover --silent --sort-index  -O sort_buffer_size=16M 
/var/lib/mysql/HNCandidate/Candidate.MYI

it cleared the message but 5mins later I had the error again.

should i try the "Difficult repair"?

shell> mysql db_name
mysql> SET AUTOCOMMIT=1;
mysql> TRUNCATE TABLE table_name;
mysql> quit

thanks
ashley

Redhat 7.0 / Mysql 3.23.32


Ashley Pestkowski - Head of IT
dn1.net - Chelsea Chambers - 262a Fulham Road, London, SW10 9EL

[EMAIL PROTECTED]
http://www.dn1.net

Tel: 0207 849 3668
Fax:0207 849 3670



-
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: Distributed Fulltext?

2002-02-08 Thread Alex Aulbach

Yesterday, from Brian DeFeyter:

> Has anyone made a suggestion or thought about ways to distribute
> databases which focus on fulltext indexes?
>
> fulltext indexes do a good job of indexing a moderate amount of data,
> but when you get a lot of data to be indexed, the queries slow down
> significantly.

Yea, this is cause the method to search the index is a geometric
algorithm.

> I have an example table, with about 90 million rows.. and has a fulltext
> index on a varchar(100) field. A single-word query which would return
> approx 300k results takes an average of 15 seconds. A query with smaller
> results (~ 10k) can be as quick as 1 sec.. which I would consider
> acceptable.

The only interesting thing is, how many words have to be indexed (how many
rows is not very important), how big grows your index (does it go in the
memory) and how many rows can be found for one word.

These are the most depending things.

> Has any thought about splitting the data into distributed files or even
> machines? ie: something as simple as 'words' starting with 'X' are split
> into a-h, i-p, q-z... or something more advanced? (maybe mysqld could
> automatically split results based on (#results per unique 'word' /
> desired # of 'split files/machines') Would such a system give any
> advantages to searching speed and concurrenct query scalability? I
> haven't looked at the fulltext internals.. so I don't know if such
> "query routing" could take place or not.

Hum, I think it's *much* cheaper is to come together and pay the mySQL
people to introduce a new feature into mySQL called "inverted files". This
method is in short, that you only store the word and in which records it
can be found. This can redurce the size of indexes and so the speed
dramatically.

> If nothing else, does anyone else have experience with a table of this
> size or even larger? What kind of tuning have you done?

We have made for example an extra table for indexing on an extra server.
This is good, cause

- mySQL can "concentrate" only for this table, so the
machine dosn't need to swap

- big searches or reindex dosn't bother the rest of the system

- indexing can be done via a cron-job

- we optimized the write routines, for example we stripped all tags out
and wrote special stop-lists, before we write it.



BTW: My wishlist for fulltext indexing:
---

- inverted files

- rules to define words

- stop-word-lists and stop-word-regex

- a function which returns a table, which can tell me, what can be
searched.
E.g SHOW MATCH(table.index) AGAINST('hugobla hugo bla');

 word  count rows stopword   autostopword   score wscore
 hugobla  22no no 10  1
 hugo106no no  8  1
 bla  00no yes 0  1

Words can be searched, depending on rules, stop-words and what has been
indexed.

- configurable scoring, e.g. very fast (and simple) scoring for speed

- special scores for special words

- a cache, which stores often used words and the rows


-- 

SSilk - Alexander Aulbach - Herbipolis/Frankonia Minoris


-
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: FULL-TEXT Index / Searching Question (fwd)

2002-02-08 Thread Alex Aulbach


Tuesday, from Matt Rudderham:

> Hello, I have two tables in my database as such:
>
> CREATE TABLE `skill_names` (
>   `id` bigint(20) NOT NULL auto_increment,
>   `name` varchar(30) NOT NULL default '',
>   PRIMARY KEY  (`id`)
> );
>
> CREATE TABLE `skills` (
>   `skills_id` int(11) NOT NULL auto_increment,
>   `member_id` int(11) NOT NULL default '0',
>   `schooling` varchar(100) default NULL,
>   `certifications` varchar(20) NOT NULL default '',
>   `description` blob NOT NULL,
>   `skill_name_id` bigint(20) NOT NULL default '0',
>   PRIMARY KEY  (`skills_id`)
> );
>
> I would like to make full text indexes of the skills table as well as
> the other tables in the database.  My question is that I would like to
> be able to search for the Member_ID's that have a certain skill name.
> How would I accomplish this? Also, right now the database has about 300
> records, the database runs on a Pentium 200  with 96Mb. Can it handle
> this not much traffic? Thanks.

I must read this a while to understand... sql sql sql

This is, what you mean:

CREATE FULLTEXT INDEX name (name)... hhhm forgot the correct syntax be
free to look into docs

SELECT * FROM skills,skillnames WHERE skill_name_id=id and
  MATCH(name) AGAINST('YOUR SEARCHED SKILLS');


BTW: These tables are suboptimal. You can reduce them to one table. This
kind of parting the tables makes only sense, if you have 3 Billion not 300
records.



-- 

SSilk - Alexander Aulbach - Herbipolis/Frankonia Minoris



-
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: Distributed Fulltext?

2002-02-08 Thread Steve Rapaport

I said:
> > Why is it that Altavista can index terabytes overnight and return
> > a fulltext boolean for the WHOLE WEB
> > within a second, and Mysql takes so long?

On Friday 08 February 2002 08:56, Vincent Stoessel wrote:

> Apples and oranges.

Yeah, I know.  But let's see if we can make some distinctions.
If, say, Google, can search 2 trillion web pages, averaging say 70k bytes 
each, in 1 second, and Mysql can search 22 million records, with an index
on 40 bytes each, in 3 seconds (my experience) on a good day,
what's the order of magnitude difference?  Roughly 10^9.

> Have you seen the /hardware/ run that enterprise with?
Irrelevant, you're unlikely to get 9 orders of magnitude difference with
faster hardware or even with clustering.

> Also, their software is optimized for full text searches and that
> is /all/ they do. Mysql is an SQL database and is optimized as such.

Absolutely granted. You are completely right. 
And I don't expect the data format to change.

 BUT:  thought experiment:

When Mysql decides to generate a FULLTEXT index, it
is using an index file, the .MYI file, which can have ANY FORMAT
it wants to.  If the .MYI format is poorly optimized for fulltext
searches, they can improve the format.  They can even introduce
a new index file type .MYF solely for optimizing fulltext searches.

None of this need have any impact on the data file format or the 
SQL search optimizations, and yet it could still improve the search
speed for fulltext.  It might not help as much for the slow indexing,
but it could certainly improve the performance of the search.

Thinking out loud...
Steve


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

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




Re: SELECT query with TRIM and LIKE

2002-02-08 Thread Tshering Norbu

Thanks Nathan,
I think I will go with
"SELECT * FROM table_name WHERE Name LIKE
> '%$name%'";

NOBBY

- Original Message -
From: Nathan Bank <[EMAIL PROTECTED]>
To: Tshering Norbu <[EMAIL PROTECTED]>
Sent: Friday, February 08, 2002 12:25 PM
Subject: Re: SELECT query with TRIM and LIKE


> What is the point of the trim? Why can't you simply "SELECT * FROM
table_name WHERE Name LIKE
> '%$name%'";
>
> Then, if the user types "Rob", they'll get Robert, Robert Downing, etc. If
they type in "Robert D",
> they'll get Robert Downing. If you trimmed "Robert D" into "RobertD" with
the trim() function, you
> would not match Robert Downing any longer. Is that different from what you
want?
>
> By the way, if your &'s are meant to join that info together, as it
appears, you need to change them
> to .'s. A dot joins things. & is a bit-wise comparison... Also, $query is
a variable, not a
> function. Either lose the parens (), or add a function to the beginning,
like so:
>
> $query = mysql_query("SELECT * FROM table");
>
> Hope that helps,
>
> # Nathan
>
> - Original Message -
> From: "Tshering Norbu" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Tuesday, February 05, 2002 10:29 PM
> Subject: SELECT query with TRIM and LIKE
>
>
>
> Dear list,
> I have a telephone database which has "Name" as one of the fields/columns.
> This field contains single name  e.g Robert,  double names e.g Robert
> Downing and more than double names.  I want to make a SELECT query using a
> form whose input name is "Name" i.e '$Name' against the "Name" field in
the
> database. One can type a part/full of one part of the name, or part/full
of
> two parts of a name and goes on likewise for more than double names in the
> input form.
>
> I believe this SELECT query is accomplished using TRIM and LIKE, something
> like:
>
> $query = ("SELECT * from table_name where Name like '%" & Trim($Name) &
"%'
> ");
>
> This $query is not working.
> Could sombody please provide me a query statement that I could use for my
> above requirement.
>
> Thank you so much.
>
> NOBBY
>
>
>
>
> -
> 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: Distributed Fulltext?

2002-02-08 Thread alec . cawley



> Why is it that Altavista can index terabytes overnight and return
> a fulltext boolean for the WHOLE WEB
> within a second, and Mysql takes so long?

I don't know about Altavista, but if you read up on Google, they do indeed
do some sort of
spreading of keywords across multiple machines - last I saw they had over
10,000
machines.

But you have to ask the question as to whether this would be an appropriate
development for MySQL. This would seeem to me to be a very complex
development
of interest to a very small subset of MySQL customers. MySQL, it seems to
me,
specialises in doing the mainstream database manipulations used by many
people simply,
quicly, and (my most important criterion) reliably. Such a development
would, IMO,
be away from the whole trend of MySQL, and shouldn't happen before
triggers,
stored procedures and the like - if ever. A multe-machine distributed
database is
a wholly different animal - IMO again. If I was going there I wouldn't
start from here -
it would need a "clean brain" look at the whole problem. If you really need
such searches,
Google survives by licencint that technology - speak to them.

 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: Fetching records from 2 tables

2002-02-08 Thread Terje Kristensen

2 queries with left outer join will do the trick.

select a.id,b.id from a left outer join b on a.id = b.id where b.id is NULL;
this will give a list over all fields that exist in table a but not in table
b

select a.id,b.id from b left outer join a on a.id = b.id where a.id is NULL;
this will give a list over all fields that exist in table b but not in table
a

Hope this is useful for you.

Terje K

> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Friday, February 08, 2002 9:32 AM
> To: [EMAIL PROTECTED]
> Subject: Fetching records from 2 tables
>
>
> hi List
>
> The problem is like this
>
> There are two Tables A and B.
>
> what i want to do is find out all the records where a.id != b.id
>
> Both tables have close to 1 records. so for every a.id it has to
> check table b 1 times and that is what is creating problems.
>
> bcos this query takes hell lot of time to execute and mysql stops
> responding after some time.
>
> So is there some other way to find out records present in one table but
> not in other.
>
> Thanks you can mail me at [EMAIL PROTECTED] also
>
> Pradeep
>
>
> __
> http://dating.zeenext.com  Log on to nextDATE.  It's the next
> best thing to doing it.
>
> -
> 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




Fetching records from 2 tables

2002-02-08 Thread mailkittu

hi List

The problem is like this

There are two Tables A and B.

what i want to do is find out all the records where a.id != b.id

Both tables have close to 1 records. so for every a.id it has to 
check table b 1 times and that is what is creating problems.

bcos this query takes hell lot of time to execute and mysql stops 
responding after some time.

So is there some other way to find out records present in one table but
not in other.

Thanks you can mail me at [EMAIL PROTECTED] also 

Pradeep 


__
http://dating.zeenext.com  Log on to nextDATE.  It's the next best thing to doing it.

-
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: long query on php

2002-02-08 Thread savaidis


Just a comment:
Doing so it's possible to insert a line between $query.. statements.
(comments ecc) Its very simple to write it with copy+paste and I prefer
this.
Thanks.

PS. I'll check the string limit and I let you know. I think it has to be the
64KB.
I think only Visual Basic has this high limit, no?

Makis


> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Friday, February 08, 2002 3:03 AM
> To: Nathan
> Cc: MySQL
> Subject: Re: long query on php
>
>
> Hi.
>
> I prefer doing like this
> $query = "CREATE TABLE query ";
> $query .= "tabledef for col a,";
> $query .= "tabledef for col b,";
> $query .= "lots more table defs,";
> $query .= "welcome to line 400";
>
> You get the point i guess
> you can do same things many different ways in php:)
>
> /PM\
>
> Alex Aulbach wrote:
> >
> > Yesterday, from Nathan:
> >
> > > Since PHP ignores whitespace, I think this is also acceptable:
> >
> > PHP doesn't ignore whitespace in a quote. But your code is of course
> > correct.
> >
> > > $query = "CREATE TABLE query
> > >   tabledef for col a,
> > >   tabledef for col b,
> > >   lots more table defs,
> > >   .
> > >   welcome to line 400";
> >
> > Another way: (without test)
> >
> > $bladefault=24;
> > $query = << > CREATE TABLE query (
> >   idchar(2) default "24" # doublequotes work
> >   hugo  char(2) default '24' # singlequotes work either
> >   bla   char(2) default '$bladefault' # inline vars work
> > ...
> > )
> > eoq
> >
> > --
> > > How is possible to pass a long query to MySQL server with php?
> > > I mean i.e a "create table" statement with more than 400 chars.
> > > Have I to use shorter "create" and then "alter"?
> >
> > Strings in PHP can be really, really long and are binary
> safe. Perhaps the
> > problem is the editor?
> >
> > --
> >
> > SSilk - Alexander Aulbach - Herbipolis/Frankonia Minoris
> >
> >
> -
> > 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