RE: Getting mysql up and running on Mac OSX

2002-10-16 Thread mysql

Well the @INC is the enviroment array of perl
so the perl script you're running needs DBI.pm perl module that 
appears not to be instaled on your box you can find more info about 
on http://dbi.perl.org/index.html and you can get it on 
http://search.cpan.org/author/TIMB/DBI-1.30/

-jose
 
I've gotten mysql server running but am getting lots of errors 
when I 
try to run any of the scripts that come with it.
for example when issuing the following command.

[HDSK-Laptop:/library/mysql/sql-bench] haridass# ./run-all-tests

The result I get is:
Can't locate DBI.pm in @INC (@INC 
contains: /System/Library/Perl/darwin 
/System/Library/Perl /Library/Perl/darwin /Library/Perl /Library/Pe
rl 
/Network/Library/Perl/darwin /Network/Library/Perl 
/Network/Library/Perl .) at ./run-all-tests line 36.

it looks to me like @INC is not pointing to the correct directory. 
I'm 
a pretty decent C++ programmer but haven't done much with using 
the 
command line.  Any tips on what is wrong or where to go from 
here.  i 
have the SAMS teach yourself mySQL but of course it is not at all 
Mac 
specific.  Any help would be appreciated.

===
Hari Dass S. Khalsa
[EMAIL PROTECTED]


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

To request this thread, e-mail [EMAIL PROTECTED]
To unsubscribe, e-mail mysql-unsubscribe-
[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




Image display Blob

2002-10-16 Thread anonazyet

Hi!

I have a html-php form which connects to a my-sql DB
and retrieves and displays the name and image(Stored
in Blob) I'm using Header(Content-type: image/gif)
to display the mesage queried from my sql. This
displays the image, but I want it displayed in a img
tag along with other text and not exclusively in the
browser. Has anyone tried a similar query? I guess I'm
kinda off-topic(?)any help is appreciated.

Thanx in advance,
Abhi

__
Do you Yahoo!?
Faith Hill - Exclusive Performances, Videos  More
http://faith.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




remote connections have stopped working

2002-10-16 Thread Jon Keller

I'm running mysql-3.23.49 on a redhat machine, mysql has stopped responding 
to remote connections ever since i rebooted it today.
/var/log/mysqld.log says

Number of processes running now: 1
mysqld process hanging, pid 3062 - killed
021015 20:37:05 mysqld restarted
/usr/libexec/mysqld: ready for connections

when a connection is made.
I ran safe_mysqld from the command line and tried to connect i got this error.

/usr/bin/safe_mysqld: line 273: 16126 Segmentation fault $NOHUP_NICENESS 
$ledir/$MYSQLD $defaults --basedir=$MY_BASEDIR_VERSION --datadir=$DATADIR 
$USER_OPTION --pid-file=$pid_file --skip-locking $err_log 21

Number of processes running now: 1
mysqld process hanging, pid 16129 - killed
021015 23:51:15 mysqld restarted



Any help with this issue would be much appreciated.

-Jon Keller 


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

2002-10-16 Thread Andrew Wilson

Hi guys,
I was wondering if anyone knew of a paramter that can be put on the end of a
select statement when querying a table which only pulled out one unique
record based on a field.
 
I.e
If i had a drink database and in it were 10 cokes 10 fantas 10 pepsi's what
select statement would i need to pull out 1 coke,1 fanta,1 pepsi .
 
Thanks for your help, a virtual beer to whoever answers my question :) 
 

Andrew Wilson 
Technical Support 
Netway Networks 
8920-8877 


Netway Networks Pty Ltd 
(T) 8920 8877 
(F) 8920 8866 



-
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




SV: remote connections have stopped working

2002-10-16 Thread nicklas

 I'm running mysql-3.23.49 on a redhat machine, mysql has stopped responding 
 to remote connections ever since i rebooted it today.
 /var/log/mysqld.log says
 
 Number of processes running now: 1
 mysqld process hanging, pid 3062 - killed
 021015 20:37:05 mysqld restarted
 /usr/libexec/mysqld: ready for connections


I have the same problem. I found out that there is a problem with red hat 8.0, but I 
compiled the mysql myself and now it works.

There is also a problem with /etc/hosts. You really have to make sure it is correct. A 
working file that I have looks as:

127.0.0.1   localhost localhost.localdomain
10.10.0.8   nicklas nicklas.mlm.tactel.se

The installation program for red hat makes some mistakes in that file.


/Nicklas


-
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




Server crash upon remote access

2002-10-16 Thread x-gylee+mysql

Description:
MySQL server crashes when a remote client connects.
A local client connecting thru unix socket file does not have the problem.
How-To-Repeat:
Connect via a remote host.
Fix:
No solution yet.

Submitter-Id:  submitter ID
Originator:Aldrian Gintingsuka
Organization:
 
MySQL support: [none | licence | email support | extended email support ]
Synopsis:  Server crash upon remote access
Severity:  critical
Priority:  high
Category:  mysql
Class: sw-bug
Release:   mysql-3.23.52 (Source distribution)

Environment:

System: Linux www.indo.com 2.4.9-34 #1 Sat Jun 1 06:10:23 EDT 2002 i686 unknown
Architecture: i686

Some paths:  /usr/local/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.2 2.96-108.7.2)
Compilation info: CC='gcc'  CFLAGS=''  CXX='g++'  CXXFLAGS=''  LDFLAGS=''
LIBC: 
lrwxrwxrwx1 root root   13 Oct  7 07:43 /lib/libc.so.6 - libc-2.2.4.so
-rwxr-xr-x1 root root  1285884 Sep  9 12:10 /lib/libc-2.2.4.so
-rw-r--r--1 root root 27336078 Sep  9 11:48 /usr/lib/libc.a
-rw-r--r--1 root root  178 Sep  9 11:48 /usr/lib/libc.so
Configure command: ./configure --prefix=/usr/local/depot/mysql-new/mysql 
--localstatedir=/var/lib/mysql-new --enable-thread-safe-client --enable-assembler 
--with-unix-socket-path=/var/lib/mysql-new/mysql.sock --with-mysqld-user=mysql 
--without-debug --with-low-memory --without-docs --without-bench --with-berkeley-db


-
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: need help mysql-server lost the tcp/ip-connection

2002-10-16 Thread Egor Egorov

Hello jantos,

Tuesday, October 15, 2002, 2:03:50 PM, you wrote:

jamdd when I'm connecting to mysql-server via tcp/ip then the mysql-server
jamdd cuts the connection and it restarts the mysql-server. 
jamdd when I don't make connections from other hosts than it's running well 
jamdd until i make connections via tcp/ip from other hosts.

jamdd on the client site:
jamdd mysql -h Mymysql-server
jamdd and I allways get:
jamdd ERROR 2013: Lost connection to MySQL server during query

jamdd on the server-host I get the message:
jamdd  bin/safe_mysqld: line 273: 11987 Segmentation fault  
$NOHUP_NICENESS $ledir/$MYSQLD $defaults --basedir=$MY_BASEDIR_VERSION 
--datadir=$DATADIR $USER_OPTION
jamdd --pid-file=$pid_file --skip-locking $err_log 21

jamdd Number of processes running now: 1
jamdd mysqld process hanging, pid 11990 - killed
jamdd 021015 12:37:53  mysqld restarted

Release:   mysql-3.23.53-max (Official MySQL-max binary)


As this is the official MySQL binary statically linked, I would first
try to upgrade the kernel, but just to be sure that the kernel is not
the source of a problem.

Then I'd go with the hardware as often such things happens because of
broken memory, kernel panics and such. Try to see what dmesg
outputs - maybe there are a clue on hardware failures?..



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




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

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




re: Re: Lost connection to MySQL server during query

2002-10-16 Thread Egor Egorov

Hello Graham,

Tuesday, October 15, 2002, 12:03:34 PM, you wrote:

 1. replace Red Hat's rpms with MySQL binary release, download it from
 http://www.mysql.com/
 2. run myisamchk on all files.
 3. run MySQL and enjoy the reliability since then :-)

GM Why do Linux distributions ship broken MySQL packages? The newly
GM released SuSE 8.1 shows similar problems, connecting from the local
GM system works fine but the server crashes (and is restarted by
GM safe_mysqld) as soon as a remote user attempts to connect. As has
GM already been noted, after installing the official MySQL RPMs
GM everything works.

This is a common problem with non-MySQL builds. Why?

First, because compiling MySQL is a very careful job to do, you don't
have to miss a single point in instructions. Say, compiling with wrong
options will give you a binary that will not be able to resolve
hostnames, load data more than 2gb, work with more than a couple of
hundreds of connections and so on.

Second, because the only stable GNU C compiler today is gcc 2.95. It's
true that MySQL cannot be compiled correctly with gcc 2.96 and 3.xx.

Third, because making a correct glibc binary is very, very hard goal
to accomplish. Not to speak about other binaries, but, say, MySQL
works with threads, and the thread stack in glibc should be around 256k
for MySQL can handle hundreds of connections. In other case, MySQL will
just crash after Nth connection. By default, the stack is 2mb in
glibc. This is causing crashes, too.

There are a lot of many other reasons.

That's (in short) why MySQL official binaries are compiled statically
and works well.



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




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

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




re: re: High load with cleaning up status

2002-10-16 Thread Egor Egorov

Hello Mike,

Monday, October 14, 2002, 6:48:36 PM, you wrote:

MZ Recently our DB, which is running MySQL 3.23.52, started experiencing
MZ intermittant load spikes, of the magnitude of 200+ load averages. 
Normally,
MZ our high spike is about 0.90 load. When this starts happening, we 
notice a
MZ lot of processes cleaning up within the database. Can someone clue 
me in
MZ as to what cleaning up means, and what the possible cause of this is?

Sure, we can.

Please tell us:

- what is the exact mysql version running (build)

MZ Version string: mysqld  Ver 3.23.52 for pc-linux-gnu on i686
MZ Straight off the RPMs from the MySQL download mirrors.

Is it a mysql official binary or just a recompiled src.rpm?
You should only use official binaries.

MZ memlock

- how does the table looks like (structure/type/properties)

- what is the hardware

MZ Dual AthlonMP 1600+, 1GB RAM, RAID-5 configuration on the DB filesystem.

- what are the OS details

MZ The session table would be a HEAP, but for the text field. As a compromise,
MZ the MYD and MYI files are in /dev/shm.

Ok. First, I would move the table to a disk. It's just my guess. I
believe, memlock and MyISAM-in-memory may be a cause of a conflict.
Another try is to remove memlock option but leave data in ram.

Second, let's go thru variables:

  key_buffer_size Index blocks are buffered and are shared by all
  threads. key_buffer_size is the size of the buffer used for index
  blocks. Increase this to get better index handling (for all reads and
  multiple writes) to as much as you can afford; 64M on a 256M machine
  that mainly runs MySQL is quite common. If you, however, make this too
  big (for instance more than 50% of your total memory) your system may
  start to page and become extremely slow. Remember that because MySQL
  does not cache data reads, you will have to leave some room for the OS
  filesystem cache. You can check the performance of the key buffer by
  doing show status and examine the variables Key_read_requests,
  Key_reads, Key_write_requests, and Key_writes.

So you should definitely lower the value of key_buffer_size (note the
spelling change - for other variables, too).

I would be suprised if that won't help.



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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




(OT) Re: Bill, your computer has got a worm (virus-like thingie) Re: Sub-select look-alike?

2002-10-16 Thread DL Neil

Michael,
Thank you for your alert.

In the same way that you did not ask the original question, I did not write
the part attributed to 'me'!
There is no such address [EMAIL PROTECTED]
The only address in this sub-domain subscribed to [EMAIL PROTECTED] is
[EMAIL PROTECTED]
I have reduced myself to list-lurker status for a number of weeks now.

One of the features of the BugBear worm is that it combines components of
different messages/msg-hdrs from mailing lists, and constructs its 'own'
likely-looking msg/disguise to carry the viral payload for onward infection.
eg yourself, my domain, and someone else, somewhere, called Bill.
Vicious! Difficult to trace!
The virus can be stopped at the border by most AV s/w.
Its cost (apart from an actual infection) may be felt in the number of
automated-response msgs that are sent out by defense mechanisms, to those
they 'identify' as apparent perpetrators, who like yourself (and myself) are
in fact innocent parties, and who may in turn may respond - such phenomenon
will ultimately clog up the email/Internet with pointless
msgs/disclaimers/refusals.

You are correct, it is a Windows-only problem.
You can read more details (amongst the many choices) at
http:[EMAIL PROTECTED]

I'm sorry you have been inconvenienced.
Regards,
=dn

List fodder: SQL



- Original Message -
From: Michael Mauch [EMAIL PROTECTED]
To: Bill Easton [EMAIL PROTECTED]
Sent: Tuesday, October 15, 2002 6:41 PM
Subject: Bill, your computer has got a worm (virus-like thingie) Re:
Sub-select look-alike?


 Hi Bill,

 you wrote to me and probably several other people:

  If I understand your question, you just need to join with the languages
  table twice, using aliases:
 
  select LF.language, LT.language
  from language_pairs P, languages LF, languages LT
  where LF.id = P.from and LT.id = P.to;
 
   From: =?iso-8859-1?Q?Andreas_Fr=F8sting?= [EMAIL PROTECTED]
   To: [EMAIL PROTECTED]
   Subject: Sub-select look-alike?
   Date: Wed, 13 Mar 2002

 I did not ask that question.

 Your mail had an attachment of type application/x-msdownload with the
 name Becks.doc.exe. This is almost certainly a worm for MS-DOS/Windows.

 I've got Linux, so I have no problem with this sort of things, but other
 recipients of your mail might be a bit upset.

 You should get a virus scanner with up-to-date virus signatures, and use
 it from a know-clean, write-protected diskette or CD.

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




Mysql crashing

2002-10-16 Thread nickc

Description:
Seems everytime I do a queary on the mysql server it just crashes out and 
restarts
displays this /usr/local/mysql/bin/safe_mysqld: line 273:  3078 Segmentation 
fault 
and also the below in the log file
[root@dev mysql-test]# ./mysql-test-run 
Installing Test Databases
Removing Stale Files
Installing Master Databases
mysqld got signal 11;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked agaist is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
We will try our best to scrape up some info that will hopefully help diagnose
the problem, but since we have already crashed, something is definitely wrong
and this may fail

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

Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
Stack range sanity check OK, backtrace follows:
0x808478e
0x8131730
0x8142ac6
0x808bc59
0x808e166
0x8086edb
Stack trace seems successful - bottom reached
Please read http://www.mysql.com/doc/U/s/Using_stack_trace.html and follow 
instructions on how to resolve the stack trace. 
Resolved
stack trace is much more helpful in diagnosing the problem, so please do 
resolve it
Trying to get some variables.
Some pointers may be invalid and cause the dump to abort...
thd-query at 0x82528f0 =  CREATE TABLE db (   Host char(60) DEFAULT '' NOT NULL,   Db 
char(64) DEFAULT '' NOT NULL,   User 
char(16) DEFAULT '' NOT NULL,   Select_priv enum('N','Y') DEFAULT 'N' NOT NULL,   
Insert_priv enum('N','Y') DEFAULT 'N' NOT 
NULL,   Update_priv enum('N','Y') DEFAULT 'N' NOT NULL,   Delete_priv enum('N','Y') 
DEFAULT 'N' NOT NULL,   Create_priv 
enum('N','Y') DEFAULT 'N' NOT NULL,   Drop_priv enum('N','Y') DEFAULT 'N' NOT NULL,   
Grant_priv enum('N','Y') DEFAULT 'N' 
NOT NULL,   References_priv enum('N','Y') DEFAULT 'N' NOT NULL,   Index_priv 
enum('N','Y') DEFAULT 'N' NOT NULL,   Alter_priv 
enum('N','Y') DEFAULT 'N' NOT NULL, PRIMARY KEY Host (Host,Db,User), KEY User (User) ) 
comment='Database privileges'
thd-thread_id=1

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

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


I did a stack follow up on it to reveal this
[root@dev tmp]# /usr/local/mysql/bin/resolve_stack_dump -s /tmp/mysqld.sym -n 
mysqld.stack
0x808478e _Z15handle_segfaulti + 398
0x8131730 __pthread_sighandler + 116
0x8142ac6 __strtol_internal + 1390
0x808bc59 _Z17add_field_to_listPc16enum_field_typesS_S_jP4ItemS_P10st_typelib + 313
0x808e166 _Z7yyparsev + 3358
0x8086edb _Z16handle_bootstrapPv + 687
 

How-To-Repeat:
Well any query really, even the ones in scripts that came with the mysql 
source distro
Fix:


Submitter-Id:  submitter ID
Originator:Nick Clewer
Organization:
 
MySQL support: [none | licence | email support | extended email support ]
Synopsis:  Mysql crashing
Severity:  
Priority:  
Category:  mysql
Class: 
Release:   mysql-3.23.53 (Source distribution)

Environment:

System: Linux dev.webinteractive.com.au 2.4.18-14 #1 Wed Sep 4 13:35:50 EDT 2002 i686 
i686 i386 GNU/Linux
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/3.2/specs
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man 
--infodir=/usr/share/info --enable-shared --enable-threads=posix --disable-checking 
--host=i386-redhat-linux --with-system-zlib --enable-__cxa_atexit
Thread model: posix
gcc version 3.2 20020903 (Red Hat Linux 8.0 3.2-7)
Compilation info: CC='gcc'  CFLAGS='-O3'  CXX='gcc'  CXXFLAGS='-O3 
-felide-constructors -fno-exceptions -fno-rtti'  LDFLAGS=''
LIBC: 
lrwxrwxrwx1 root root   14 Oct 16  2002 /lib/libc.so.6 - 
libc-2.2.93.so
-rwxr-xr-x1 root root  1235468 Sep  6 09:12 /lib/libc-2.2.93.so
-rw-r--r--1 root root  2233342 Sep  6 08:59 /usr/lib/libc.a
-rw-r--r--1 root root  178 Sep  6 08:50 /usr/lib/libc.so
Configure command: ./configure --prefix=/usr/local/mysql --enable-assembler 
--with-mysqld-ldflags=-all-static --localstatedir=/var/lib/mysql CFLAGS=-O3 
'CXXFLAGS=-O3 -felide-constructors -fno-exceptions -fno-rtti' CXX=gcc


-
Before 

re: MySql SETUP Problem

2002-10-16 Thread Victoria Reznichenko

Balazs,
Wednesday, October 16, 2002, 8:27:56 AM, you wrote:

BL I installed the full version of Mandrake 8.2. 
BL The problem is that i can't setup the mysql server. 
BL When i tried: mysql -u root mysql; the server
BL responded: acces denied for root@localhost !! 

Have you installed MySQL server before? If so MySQL server could
use privilege tables from previous installation.

BL Then tried the command mysql_install_db. But when i
BL wanted to sign in: still acces denied.

If you have privilege tables installed, mysql_install_db does nothing.

BL Then i used mysqld --skip-granted-tables. BUT after
BL that even for the 'mysql' command the server returned
BL 'Acces denied'.

It's weird. What version of MySQL server you are using? How did
you installed MySQL server?


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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: Replication and LOAD DATA INFILE

2002-10-16 Thread Lothar Jenisch

 Lothar Jenisch wrote:
 
 Hello,
 
 I have a problem with replication and LOAD DATA INFILE.
 I use version 3.23.37 on Liunx distribution.
 
 1. I check the replication with a manual i.e. insert and 
delete of one record. This works fine without problems.
 2. I do a 
LOAD DATA INFILE 'file.txt' REPLACE INTO TABLE table 
FIELDS TERMINATED BY '' ENCLOSED BY '' LINES TERMINATED BY '\n' 
On the master it works but on the slave nothing happens.
No error, no log, nothing!
 
 
 How could it?
 The slave would not have the file.
 Write an import program in perl etc.
What do you mean with an import program? I copied the file
manually to the slave and do the LOAD DATA INFILE again on
the server. And still nothing happens.
If I do a LOAD TABLE 'table' FROM MASTER it's okay.

 It would be nice to have the masterl log the actual  data changes 
 resulting from
 a load data [ local ] infile.
In the master log everything is correct. But there is nothing in
the slave log.

 3. I check the replication again with 1. and this commands 
are still okay.
 
 What's wrong? It seems the LOAD DATA INFILE will not be executed
 on the slave. I check it with log-slave-updates and mysqlbinlog
 and I can't find the command.
 
 Thanks for your help
 Lothar
 
 
 
 
   
 
 
 

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

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




Re: HELP Can't build mysql-3.23.53

2002-10-16 Thread mysql

Thanks very much for all yours replays

The trick to have it build on solaris came on the email
From: Jesse Sheidlower [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Tuesday, October 15, 2002 5:07 PM
Subject: Re: Problems installing on Solaris/Intel

They where dealing with Intel platform but it took me out of the 
water it builds fine on SPARC Solaris 9 too.

Ending Tests
Shutting-down MySQL daemon

Master shutdown finished
Slave shutdown finished
All 137 tests were successful.

Thanks again
--jose

Thanks very much for your replay
Is very interesting but how to change that declaration on mysql or 
on the headers if there is any to modify. I have others Linux 
boxes 
running mysql fine but each time I have to deal with the others 
sparcs Solaris is really a real nightmare .

Regards

Jose Albert


[EMAIL PROTECTED] wrote:

 Hi everyone!
 I'm trying to build /mysql-3.23.53 on a sparc Solaris 9 box but
 without any luck
 Please guys can anyone give me an idea about?

 Any help will be highly appreciated

 -Jose

 Specs: solaris 9, gcc-3.2, mysql-3.23.53
 configured as:

 CC=gcc CFLAGS=-O3 \
 CXX=gcc CXXFLAGS=-O3 -felide-constructors -fno-exceptions -fno-
 rtti \
 ./configure --prefix=/usr/local/mysql --localstatedir=/data --
 enable-assembler \
 --with-innodb --with-mysqld-ldflags=-all-static

 Here is the output
 /...

 ONFIG_H -I./../include  -
 I./../regex-I. -I../include -I.. -I.-
O3 -
 DDBUG_OFF -O3 -felide-constructors -fno-exceptions -fno-rtti  -
fno-
 implicit-templates -fno-exceptions -fno-rtti -DUSE_MYSYS_NEW -
 DDEFINE_CXA_PURE_VIRTUAL -DHAVE_RWLOCK_T -c mysqld.cc
 mysqld.cc: In function `void* handle_connections_sockets
(void*)':
 mysqld.cc:2410: invalid conversion from `size_socket*' to
 `socklen_t*'
 mysqld.cc:2476: invalid conversion from `size_socket*' to
 `socklen_t*'
 make[3]: *** [mysqld.o] Error 1
 make[3]: Leaving directory `/web/compile/mysql-3.23.53/sql'
 make[2]: *** [all-recursive] Error 1
 make[2]: Leaving directory `/web/compile/mysql-3.23.53/sql'
 make[1]: *** [all-recursive] Error 1
 make[1]: Leaving directory `/web/compile/mysql-3.23.53'
 make: *** [all-recursive-am] Error 2

 Thanks again

 
-

 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 mysql-
[EMAIL PROTECTED]
 To unsubscribe, e-mail mysql-unsubscribe-kernel=nea-
[EMAIL PROTECTED]
 Trouble unsubscribing? Try: 
http://lists.mysql.com/php/unsubscribe.php

I've seen a similar problem converting some of our programs from 
Solaris gcc
2.8.1
to Linux gcc 2.96.X.

We had to change from this on Solaris

int newCxn = accept (listenSock, (struct sockaddr *) addr, 
addrlen);

to this for Linux

int newCxn = accept (listenSock, (struct sockaddr *) addr, 
(socklen_t *)
addrlen);

I haven't looked at mysql source so I dont know for sure.



---
--
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 mysql-unsubscribe-
[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: Select statement paramter

2002-10-16 Thread Victoria Reznichenko

Andrew,
Wednesday, October 16, 2002, 11:01:05 AM, you wrote:

AW I was wondering if anyone knew of a paramter that can be put on the end of a
AW select statement when querying a table which only pulled out one unique
AW record based on a field.
 
AW I.e
AW If i had a drink database and in it were 10 cokes 10 fantas 10 pepsi's what
AW select statement would i need to pull out 1 coke,1 fanta,1 pepsi .
 
AW Thanks for your help, a virtual beer to whoever answers my question :) 
 
DISTINCT may help you:
 http://www.mysql.com/doc/en/Selecting_columns.html
 http://www.mysql.com/doc/en/SELECT.html


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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: Server crash upon remote access

2002-10-16 Thread Victoria Reznichenko

x-gylee+mysql,
Wednesday, October 16, 2002, 11:11:44 AM, you wrote:

Description:
xgmaidc MySQL server crashes when a remote client connects.
xgmaidc A local client connecting thru unix socket file does not have the problem.
How-To-Repeat:
xgmaidc Connect via a remote host.
Fix:
xgmaidc No solution yet.

Please, check it on binary distribution of MySQL.


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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




Can you use MySQL functionality without MySQL installed?

2002-10-16 Thread Tim Collins

Hi everyone,

Basically my problem is that I want to distribute a program that uses
the MySQL C API. The functions mysql_* are available in the dll which
can be packaged along with the programs exe. The database that the
program uses can also be rebuilt using an sql script so it does not need
to be distributed. The manual mentions how to go about connecting to the
database but doesn't mention about what to do for a machine that doesn't
have MySQL installed.
I assume the answer to my question is probably that you have to have
MySQL installed but I am just posting this here to be sure.
Any information at all on this topic would be appreciated!

-Tim


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

2002-10-16 Thread Roger Baklund

* Andrew Wilson 
 Hi guys,
 I was wondering if anyone knew of a paramter that can be put on 
 the end of a
 select statement when querying a table which only pulled out one unique
 record based on a field.

... LIMIT 1

 I.e
 If i had a drink database and in it were 10 cokes 10 fantas 10 
 pepsi's what
 select statement would i need to pull out 1 coke,1 fanta,1 pepsi .

That would be three records, not one... DISTINCT is probably what you need:

SELECT DISTINCT drinkname FROM drinktable

URL: http://www.mysql.com/doc/en/SELECT.html 

 Thanks for your help, a virtual beer to whoever answers my question :) 

Cheers!

-- 
Roger
*burp*

-
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.sock does't exist

2002-10-16 Thread perumal

Dear sir,

   I have installed mysql-max-3.23.51.tar file on linux machine.
I gave all options which they have given in the  INSTALL BINARY file.
such as

shell groupadd mysql
 shell useradd -g mysql mysql
 shell cd /usr/local
 shell gunzip  /path/to/mysql-VERSION-OS.tar.gz | tar xvf -
 shell ln -s mysql-VERSION-OS mysql
 shell cd mysql
 shell scripts/mysql_install_db
 shell chown -R root  /usr/local/mysql
 shell chown -R mysql /usr/local/mysql/data
 shell chgrp -R mysql /usr/local/mysql
 shell chown -R root /usr/local/mysql/bin
 shell bin/safe_mysqld --user=mysql 

When enter the last statement like : ./bin/mysqladmin -u root -p
password 'solutions'
Enter password:solutionsI getting error like..

./bin/mysqladmin -u root -p password 'solutions'
Enter password:
./bin/mysqladmin: connect to server at 'localhost' failed
error: 'Can't connect to local MySQL server through socket
'/tmp/mysql.sock' (2)'
Check that mysqld is running and that the socket: '/tmp/mysql.sock'
exists!

Please give me an idea to recover this problem.

Perumal.


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

2002-10-16 Thread Simon Green

ESCAPE
Mite help...?
Simon
MySQL 

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

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




re: Mysql.sock does't exist

2002-10-16 Thread Victoria Reznichenko

perumal,
Wednesday, October 16, 2002, 1:07:14 PM, you wrote:

pI have installed mysql-max-3.23.51.tar file on linux machine.
p I gave all options which they have given in the  INSTALL BINARY file.
p such as

p  shell groupadd mysql
p  shell useradd -g mysql mysql
p  shell cd /usr/local
p  shell gunzip  /path/to/mysql-VERSION-OS.tar.gz | tar xvf -
p  shell ln -s mysql-VERSION-OS mysql
p  shell cd mysql
p  shell scripts/mysql_install_db
p  shell chown -R root  /usr/local/mysql
p  shell chown -R mysql /usr/local/mysql/data
p  shell chgrp -R mysql /usr/local/mysql
p  shell chown -R root /usr/local/mysql/bin
p  shell bin/safe_mysqld --user=mysql 

p When enter the last statement like : ./bin/mysqladmin -u root -p
p password 'solutions'
p Enter password:solutionsI getting error like..

p ./bin/mysqladmin -u root -p password 'solutions'
p Enter password:
p ./bin/mysqladmin: connect to server at 'localhost' failed
p error: 'Can't connect to local MySQL server through socket
p '/tmp/mysql.sock' (2)'
p Check that mysqld is running and that the socket: '/tmp/mysql.sock'
p exists!

If MySQL server is running (check it with: ps ax | grep mysqld), find
where mysql.sock is located.
  mysqladmin ...  --socket=/path/to/the/socket/file ...


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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: Help downgrading

2002-10-16 Thread Egor Egorov

Karl,
Wednesday, October 16, 2002, 1:41:24 AM, you wrote:

KS Any help downgrading my MySQL Server from 4.0.0.0ALPHA to 3.23 would be a
KS huge help.  I'm not sure where to start.  Do I need to save records to a
KS flat file and then reimport them?

Just uninstall 4.0.0 and then install 3.23. But I suggest you make a
dump of databases.



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




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

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




re: remote connections have stopped working

2002-10-16 Thread Victoria Reznichenko

Jon,
Wednesday, October 16, 2002, 8:04:12 AM, you wrote:

JK I'm running mysql-3.23.49 on a redhat machine, mysql has stopped responding
JK to remote connections ever since i rebooted it today.
JK /var/log/mysqld.log says

JK Number of processes running now: 1
JK mysqld process hanging, pid 3062 - killed
JK 021015 20:37:05 mysqld restarted
JK /usr/libexec/mysqld: ready for connections

JK when a connection is made.
JK I ran safe_mysqld from the command line and tried to connect i got this error.

JK /usr/bin/safe_mysqld: line 273: 16126 Segmentation fault $NOHUP_NICENESS 
JK $ledir/$MYSQLD $defaults --basedir=$MY_BASEDIR_VERSION --datadir=$DATADIR 
JK $USER_OPTION --pid-file=$pid_file --skip-locking $err_log 21

JK Number of processes running now: 1
JK mysqld process hanging, pid 16129 - killed
JK 021015 23:51:15 mysqld restarted

Did you installed MySQL server from binary or from source?
What is the version of RedHat? What is the kernel version?


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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: Segmentation Fault when connecting via TCP/IP

2002-10-16 Thread Egor Egorov

clint,
Wednesday, October 16, 2002, 1:14:08 AM, you wrote:

caddn Recently the server had to be hard-booted... a safe shutdown was not 
possible. After the server came back up, mysql
caddn has been acting very funny. When the server first boots, mysql wont respond to 
anything. I restart mysql and all works fine 
caddn when connecting to Localhost, however when you try to connect to the server via 
TCP/IP you get the following error on the 
caddn client :

caddn [root@monitor bin]# ./mysqlshow -h www.dis.net -u root -p
caddn Enter password: 
caddn ./mysqlshow: Lost connection to MySQL server during query
caddn [root@monitor bin]#

caddn At the same you do this on the client machine.. you get this on the host 
machine :

caddn /usr/local/bin/safe_mysqld: line 269: 26209 Segmentation fault  
$NOHUP_NICENESS $ledir/$MYSQLD $defaults 
caddn --basedir=$MY_BASEDIR_VERSION --datadir=$DATADIR $USER_OPTION 
--pid-file=$pid_file --skip-locking $err_log 21

caddn Number of processes running now: 1
caddn mysqld process hanging, pid 26212 - killed
caddn 021015 14:54:14  mysqld restarted

caddn I originally thought it may have something to do with the client.. but even a 
simple 'telnet www.host.com 3306' will produce 
caddn the same error on the server.

caddn I tried starting mysql directly (without using safe_mysqld) by using 
/usr/local/libexec/mysqld --user=root. When I did this, 
caddn it 
caddn didnt spit out an error on the client side, but it does cause a segmentation 
fault on the server with no additional warnings 
caddn or logs. After that the server fails to respond to anything.

caddn I have re-installed mysql from a secured distribution, so I know it doesnt have 
anything to do with any tampering. I have run 
caddn checks on all of the databases and they all seem fine. Also, everything works 
fine when connecting with a UNIX socket 
caddn (Localhost), the problem only appears when connecting with TCP/IP.

What do you mean secured distribution?
Re-intsall MySQL from binary distribution and let us know if it appears
again.



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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




Result using after statement and connection close

2002-10-16 Thread Daya Krishan Dubey

Hi,

I am using MySQL with the mm.mysql-2.0.14 dirver. I got connection with the
databse after that i created an object of statement and after that i got the
object of ResultSet, then i closed the statement and then conection. But
when i use this resultset it works fine. Can anybody tell me how it works.
If it cache the data as soon as object of result set is created then in case
of updatable result how it will update the data in the resultset as well as
in the database since connection is no more with database.

Thanks in advance.
Regards
Daya Krishan Dubey
Core Solucomm Ltd
423 B, Hamilton court
DLF phase IV
Gurgaon, India




-
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 from multiple tables

2002-10-16 Thread Veysel Harun Sahin

Hello,

I have a problem with select statetement. I need to query and select 
records from multiple tables which have the same column types. I have 
done this with left join but my query became so complex. Because i have 
written left join between all of my tables and also if i need to query 
something i have to write tablename.columnname syntax for each table. 
Now i am looking for a more basic query to be able to do this. For 
example i have 3 tables with the names of table1, table2 and 
table3. All of my tables have 2 columns cola and colb. I have to 
select records whose cola = something from all of my tables with one 
query.

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




highly recomended MySQL version

2002-10-16 Thread usha

Hi all,
 
Can anyone suggest me the highly  recomended (non vulnerable)MySQL version.
 
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: select from multiple tables

2002-10-16 Thread Joseph Bueno

Hello,

You can define a merge table and run your select on it.
Check the manual for details: http://www.mysql.com/doc/en/MERGE.html

Regards

Joseph Bueno

Veysel Harun Sahin wrote:
 Hello,
 
 I have a problem with select statetement. I need to query and select
 records from multiple tables which have the same column types. I have
 done this with left join but my query became so complex. Because i have
 written left join between all of my tables and also if i need to query
 something i have to write tablename.columnname syntax for each table.
 Now i am looking for a more basic query to be able to do this. For
 example i have 3 tables with the names of table1, table2 and
 table3. All of my tables have 2 columns cola and colb. I have to
 select records whose cola = something from all of my tables with one
 query.
 
 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




Dead server

2002-10-16 Thread Arne K. Haaje


Hello,

After upgrading to 4.0.4 from 4.0.2 on three server we have got some 
mysterious problems with one of the server.

Several times it appears to be dead. Connecting takes a very long time, 
and the CPU load goes throug the roof and beyond.

The two other servers runs without problems. The only difference between 
the servers is that the one with problems is a master for the two others 
(replicating one DB), and the machine is dual CPU. All serveres run Linux.

When the problem occurs I have tailed the slow-log. This crops up every 
time when there is a problem. I have no idea what it is!

# administrator command: Statistics;
# User@Host: xxx
# Query_time: 31  Lock_time: 0  Rows_sent: 0  Rows_examined: 0
# administrator command: Statistics;
# User@Host: xxx
# Query_time: 32  Lock_time: 0  Rows_sent: 1  Rows_examined: 70
# administrator command: Statistics;
# User@Host: xxx
# Query_time: 33  Lock_time: 0  Rows_sent: 0  Rows_examined: 0

I think this statistics command may be what is causing the problems, so 
can anybody tell me what is happening?

Regards,

Arne

-- 

Arne K. Haaje   | T: 69 92 04 90
Bregneveien 9   | F: 69 92 04 91
1825 Tomter | M: 92 88 44 66

 http://www.drlinux.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: select from multiple tables

2002-10-16 Thread Kelly Firkins

Assuming that you're joining data based on colB, you
would use:

select t1.colA,t2.colA,t3.colA
from tblA t1
inner join tblB t2 on t1.colB = t2.colB
inner join tblC t3 on t1.colB = t2.colB
where...

You can alias the table names, but there's really no
way to get around specifying the table identifiers in
the select portion. If you try selecting colA, it will
  throw an error because it has 3 colA available to
it.

Kelly

--- Veysel Harun Sahin [EMAIL PROTECTED] wrote:
 Hello,
 
 I have a problem with select statetement. I need to
 query and select 
 records from multiple tables which have the same
 column types. I have 
 done this with left join but my query became so
 complex. Because i have 
 written left join between all of my tables and
 also if i need to query 
 something i have to write tablename.columnname
 syntax for each table. 
 Now i am looking for a more basic query to be able
 to do this. For 
 example i have 3 tables with the names of table1,
 table2 and 
 table3. All of my tables have 2 columns cola and
 colb. I have to 
 select records whose cola = something from all of
 my tables with one 
 query.
 
 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
 


=
--
Kelly Firkins
Computer Junkie
Information Systems guy
email: [EMAIL PROTECTED]

__
Do you Yahoo!?
Faith Hill - Exclusive Performances, Videos  More
http://faith.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




permissions mysql.user

2002-10-16 Thread Gavin Lilley

I have a mysql database (version 3.23.47) running on a virtual server.

I have taken the running over from someone else and have been having trouble
with database permissions. To combat this I bypassed passwords by creating a
my.cnf file. I then have deleted all records in the mysql.user table and am
starting afresh.

How is the best way to reconstruct this table? Can I add admin@localhost and
say a webmaster with access from anywhere?

I have looked everywhere for a security guide, can any one point me in the
direction of good practice documents? I need to learn more about creating
accounts for websites to query databases.

many thanks, Gav.



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

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




mySQL on windows xp

2002-10-16 Thread Mark

Ok, I tried to set up MySQL at home (3.23.53), on my windows machine, so I
can test database stuff before I use it on the UNIX server. I installed it,
set it up as services, the service is running, yet I get:

C:\mysql\binmysql.exe
ERROR 2003: Can't connect to MySQL server on 'localhost' (10061)

I created the following \my.cnf:

---
[mysqld]
bind-address=212.238.195.5
skip-innodb
skip-bdb
datadir=/var/db/mysql
socket=/tmp/mysql.sock
port=3306

[mysql.server]
basedir=/usr/local
---

Obviously, this works fine on my UNIX server; but I must be doing something
wrong on Windoze. Is there a log somewhere I could check? The socket does
not seem to exist either.

Thanks.

- Mark


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

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




Re: How many columns does MySQL Support?

2002-10-16 Thread Brent Baisley

I'm not sure what the limit is. MySQL limits tend to be dictated by the 
OS that is being used. The more columns you have the larger the database 
file will be. You should try to avoid having many empty columns in a 
database design, even if you are using varchar instead of char. Try to 
think ahead in your design to what indexes you will create to speed up 
searching. You obviously don't want to create 300 indexes (don't know if 
you even can) and you want to avoid full database searches, which is 
what happens with no indexes.

Going on a relevant tangent here. What could you need 300 columns for? 
I'd be hard pressed to think of a dataset that would have 300 unique 
pieces of data. Perhaps you can make your columns into records? A simple 
example to clarify. I see many database designs that create maybe 10 or 
more columns to store various phone numbers (home, work, cell, fax, 
beeper, other, etc.). A better design would be to make them records in a 
phone number database with a description field to indicate what phone 
number it is. This gives you the ability to store unlimited phones 
numbers and to easily search for a phone number (i.e. reverse lookup). 
Plus, you can create one index to index all you phone numbers for quick 
searching.
I would not split your data into separate tables. If you have to, create 
a table with a column called field name where you can specify what 
type of information a record holds.

On Tuesday, October 15, 2002, at 09:40 PM, Andrew Kuebler wrote:

 I have a table I need to build with about 300 columns and I'm
 concerned about performance issues, however, I would only extract from
 the table what I need, not all 300 at one time.
--
Brent Baisley
Systems Architect
Landover Associates, Inc.
Search  Advisory Services for Advanced Technology Environments
p: 212.759.6400/800.759.0577


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

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




RE: mySQL on windows xp

2002-10-16 Thread [EMAIL PROTECTED]


Ok, I tried to set up MySQL at home (3.23.53), on my windows machine, so I
can test database stuff before I use it on the UNIX server. I installed it,
set it up as services, the service is running, yet I get:

C:\mysql\binmysql.exe
ERROR 2003: Can't connect to MySQL server on 'localhost' (10061)

I created the following \my.cnf:

---
[mysqld]
bind-address=212.238.195.5

Where did you get this IP address? This probably should be 127.0.0.1, which
is the default IP for 'localhost'.

Ken



mail2web - Check your email from the web at
http://mail2web.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: Crystal Reports MySQL

2002-10-16 Thread Scott Pippin

We use Crystal and it is great.  It is especially good for the more
complicated reports.

 Webmaster MBTRADINGCO [EMAIL PROTECTED] 10/15/02
11:45PM 
Hi, does anyone knows if Crystal reports is a good reporter to make
reports out of MySQL, or does anyone knows a good reporter for PHP
MySQL?

Thanks

The Vampmaster



-
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




Inserting Master and Details records

2002-10-16 Thread Alan McDonald

My task is to insert a new master record and several detail records within
the one transaction.

There is a foreign key on the detail table set to the unique key (autoinc)
field of the master table.

Inserting a master record, even with a special field value so that it can be
quickly returned with the newly created primary key, so that I might then
insert the detail records with this primary key as their foreign key, does
not seem very reliable to me (as suggested a few days ago).

There must be a more reliable way to do this under heavy traffic. I'm afraid
I'm used to being able to grab a generator ID and using that (guaranteed to
be unique) for both the primary key of the master and the foreign key of the
detail records. Surely there is a good method for use with MySQL?

Alan McDonald
http://www.meta.com.au



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

2002-10-16 Thread Greg Knaddison
Ok, so I've broken down your problem into small, manageable steps.

First, users are provided with a box to enter a value (e.g. pumpkin) and the 1)ability 
to select a ranking for pumpkin, or 2)the ability to select which old value (apefruit) 
the new value-pumpkin-belongs above/below (scenarios 1 and 2 are largely the same 
thing, just that 2 has an extra step so I'll assume 2 is your case) OR they can simply 
enter a new value (pumpkin) with no rank entry.

Pseudocode and logic: 

Step 1. If the input has no rank entry, get the max value myLocalRanking = select 
max(colA)+1 from fruitable skip to step 4
Step 2. Find out what value the apefruit has: myLocalRanking = select colB from 
fruitable where colB = 'apefruit'
Step 3. Increment all values in cola greater than or equal to the apefruit value: 
update fruitable set colA = colA+1 where colA  myLocalRanking-1
Step 4. Insert the new value pumpkin with the myLocalRanking value: insert into 
fruitable (colA, colB) values(myLocalRanking, 'pumpkin')

You mention an application so I assume that your application can handle this logic.  
In general, you could also do it with a stored_procedure/trigger.  This solution has 
some problems to it with multi-user environments and corruption of the data if the 
process fails part way through.

You should be able to mitigate the flaws in my solution by using an autoincremented 
value for colA (I think) but I'm not that familiar with the MySQL implementaiton of 
autoincrements, so I'll leave that to you.

Also, you mentioned deleting, which would follow similar steps to the above except 
that you're decrementing everything above a certain value instead of incrementing it.  
And the final display I'm sure your familiar with as something like select colB from 
fruitable sort by colA ascending;


Hope this helps,
Greg

sql, query

-Original Message-
From: kayamboo [mailto:[EMAIL PROTECTED]]

I have a table with only one column and values are inserted by getting user
request from my application.

 I want to display the column values in the order they are inserted. So only
option is to go for another column with an auto increment key.


eg.

col Acol B
 1 apple
 2 orange
 3 apefruit


 But the user should have the option to insert data in between, any two
existing column values. He can also delete any record.
And now I want to display the records in the new order.

eg.
col B
 apple
 orange
 jack
 apefruit


-
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 Master and Details records

2002-10-16 Thread Peter Lovatt

Hi

insert_id returns the key value. I use php, and the mysql_insert_id is the
last insert_id on that connection, so even if other processes have added new
records in the time the script runs the insert_id is the correct one.

You can then use that as the key in the detail records.

HTH

Peter

---
Excellence in internet and open source software
---
Sunmaia
www.sunmaia.net
tel. 0121-242-1473
---

-Original Message-
From: Alan McDonald [mailto:[EMAIL PROTECTED]]
Sent: 16 October 2002 13:45
To: [EMAIL PROTECTED]
Subject: Inserting Master and Details records


My task is to insert a new master record and several detail records within
the one transaction.

There is a foreign key on the detail table set to the unique key (autoinc)
field of the master table.

Inserting a master record, even with a special field value so that it can be
quickly returned with the newly created primary key, so that I might then
insert the detail records with this primary key as their foreign key, does
not seem very reliable to me (as suggested a few days ago).

There must be a more reliable way to do this under heavy traffic. I'm afraid
I'm used to being able to grab a generator ID and using that (guaranteed to
be unique) for both the primary key of the master and the foreign key of the
detail records. Surely there is a good method for use with MySQL?

Alan McDonald
http://www.meta.com.au



-
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 on windows xp

2002-10-16 Thread Egor Egorov

Mark,
Wednesday, October 16, 2002, 4:08:03 PM, you wrote:

M Ok, I tried to set up MySQL at home (3.23.53), on my windows machine, so I
M can test database stuff before I use it on the UNIX server. I installed it,
M set it up as services, the service is running, yet I get:

M C:\mysql\binmysql.exe
M ERROR 2003: Can't connect to MySQL server on 'localhost' (10061)

M I created the following \my.cnf:

M ---
M [mysqld]
M bind-address=212.238.195.5
^^^

Why do you use bind-address=212.238.195.5 if you connect from
localhost(127.0.0.1)?

M skip-innodb
M skip-bdb
M datadir=/var/db/mysql
M socket=/tmp/mysql.sock
M port=3306

M [mysql.server]
M basedir=/usr/local
M ---

M Obviously, this works fine on my UNIX server; but I must be doing something
M wrong on Windoze. Is there a log somewhere I could check? The socket does
M not seem to exist either.



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




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

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




Re: Inserting Master and Details records

2002-10-16 Thread Roger Baklund

* Alan McDonald
 My task is to insert a new master record and several detail records within
 the one transaction.

 There is a foreign key on the detail table set to the unique key (autoinc)
 field of the master table.

 Inserting a master record, even with a special field value so
 that it can be
 quickly returned with the newly created primary key, so that I might then
 insert the detail records with this primary key as their foreign key, does
 not seem very reliable to me (as suggested a few days ago).

 There must be a more reliable way to do this under heavy traffic.
 I'm afraid
 I'm used to being able to grab a generator ID and using that
 (guaranteed to
 be unique) for both the primary key of the master and the foreign
 key of the
 detail records. Surely there is a good method for use with MySQL?

Yes, there is. Check out the function LAST_INSERT_ID():

URL: http://www.mysql.com/doc/en/Miscellaneous_functions.html 
URL: http://www.mysql.com/doc/en/mysql_insert_id.html 

--
Roger


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

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




RE: Inserting Master and Details records

2002-10-16 Thread Alan McDonald

Peter,
Thanks you - I looked up Insert_ID() in the manual...
Page 171-172
If I insert into person but before I insert into short, someone else inserts
into person, surely my inserts into shirt will have their last Insert_ID()?

Do you know if this is true only in the same connection context only? Or
does insert_id() return another connections last insert?

Alan

 -Original Message-
 From: Peter Lovatt [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, 17 October 2002 0:59
 To: Alan McDonald; [EMAIL PROTECTED]
 Subject: RE: Inserting Master and Details records


 Hi

 insert_id returns the key value. I use php, and the mysql_insert_id is the
 last insert_id on that connection, so even if other processes
 have added new
 records in the time the script runs the insert_id is the correct one.

 You can then use that as the key in the detail records.

 HTH

 Peter

 ---
 Excellence in internet and open source software
 ---
 Sunmaia
 www.sunmaia.net
 tel. 0121-242-1473
 ---

 -Original Message-
 From: Alan McDonald [mailto:[EMAIL PROTECTED]]
 Sent: 16 October 2002 13:45
 To: [EMAIL PROTECTED]
 Subject: Inserting Master and Details records


 My task is to insert a new master record and several detail records within
 the one transaction.

 There is a foreign key on the detail table set to the unique key (autoinc)
 field of the master table.

 Inserting a master record, even with a special field value so
 that it can be
 quickly returned with the newly created primary key, so that I might then
 insert the detail records with this primary key as their foreign key, does
 not seem very reliable to me (as suggested a few days ago).

 There must be a more reliable way to do this under heavy traffic.
 I'm afraid
 I'm used to being able to grab a generator ID and using that
 (guaranteed to
 be unique) for both the primary key of the master and the foreign
 key of the
 detail records. Surely there is a good method for use with MySQL?

 Alan McDonald
 http://www.meta.com.au



 -
 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: Inserting Master and Details records

2002-10-16 Thread Alan McDonald


Sorry your second link makes that claim a little clearer - it's on a
per-connection basis
Alan

 -Original Message-
 From: Roger Baklund [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, 16 October 2002 23:58
 To: [EMAIL PROTECTED]
 Cc: Alan McDonald
 Subject: Re: Inserting Master and Details records


 * Alan McDonald
  My task is to insert a new master record and several detail
 records within
  the one transaction.
 
  There is a foreign key on the detail table set to the unique
 key (autoinc)
  field of the master table.
 
  Inserting a master record, even with a special field value so
  that it can be
  quickly returned with the newly created primary key, so that I
 might then
  insert the detail records with this primary key as their
 foreign key, does
  not seem very reliable to me (as suggested a few days ago).
 
  There must be a more reliable way to do this under heavy traffic.
  I'm afraid
  I'm used to being able to grab a generator ID and using that
  (guaranteed to
  be unique) for both the primary key of the master and the foreign
  key of the
  detail records. Surely there is a good method for use with MySQL?

 Yes, there is. Check out the function LAST_INSERT_ID():

 URL: http://www.mysql.com/doc/en/Miscellaneous_functions.html 
 URL: http://www.mysql.com/doc/en/mysql_insert_id.html 

 --
 Roger




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

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




Problems installing on Solaris/Intel

2002-10-16 Thread Ben Goodwin

I've compiled and installed this on my Solaris8/Intel box a few times
without a hitch.. I don't recall seeing what version of Solaris you're
running.. ?
I also compiled with just ./configure - I didn't bother with the other
options.. although that might be asking for trouble under certain
circumstances...
I don't have the source in front of me to check but I seem to recall being
able to compile specifically withOUT curses support?  Is your ncurses
library up to date?  Changing which curses libs to use won't affect this
issue - the issue is a header/include problem, not a library problem.
If that doesn't help, let me know and I'll try to suggest other things as
well as check out my installation

-=| Ben



Resending: sql,query




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

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




re: permissions mysql.user

2002-10-16 Thread Victoria Reznichenko

Gavin,
Wednesday, October 16, 2002, 3:59:04 PM, you wrote:

GL I have a mysql database (version 3.23.47) running on a virtual server.

GL I have taken the running over from someone else and have been having trouble
GL with database permissions. To combat this I bypassed passwords by creating a
GL my.cnf file. I then have deleted all records in the mysql.user table and am
GL starting afresh.

Deleteting all records from privilege table is not the best way to avoid
access denied problem.

GL How is the best way to reconstruct this table?

Add users again. Or what you mean reconstruct?

GL Can I add admin@localhost and
GL say a webmaster with access from anywhere?

Yes. % in the Host field means any host:
 http://www.mysql.com/doc/en/Request_access.html

GL I have looked everywhere for a security guide, can any one point me in the
GL direction of good practice documents?

In the MySQL manual there are enough info about how MySQL privilege
system works, how to add new user, change passwords, add/revoke
privileges:
   http://www.mysql.com/doc/en/Privilege_system.html
   http://www.mysql.com/doc/en/User_Account_Management.html

GL I need to learn more about creating
GL accounts for websites to query databases.


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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: data-type help with NULL entries

2002-10-16 Thread Salada, Duncan

1) What is a syntax example for inserting a NULL into a column? 

insert into projects set costing=NULL

2) If a NULL is inserted into a column with a float type, does that NULL
show up as anything else other than NULL? Like my 0.00 for example. Is that
actually mysql's way of showing a NULL for that data type?

MySQL does not generally go messing around with NULL.  NULL is NULL. It's
not 0; it's not an empty string.  The documentation below might give some
insight into the nature of NULL.
http://www.mysql.com/doc/en/Problems_with_NULL.html
http://www.mysql.com/doc/en/Working_with_NULL.html

Duncan

---
Duncan Salada
Titan Systems Corporation
301-925-3222 x375


-Original Message-
From: Hammons Randy G SSgt 612 ACOMS/SCXX
[mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 16, 2002 9:57 AM
To: Mysql (E-mail)
Subject: RE: data-type help with NULL entries


Re-send.  Hopefully someone can help...

-Original Message-
From: Hammons Randy G SSgt 612 ACOMS/SCXX
[mailto:[EMAIL PROTECTED]]
Sent: Tuesday, October 15, 2002 9:01 AM
To: Mysql (E-mail)
Subject: data-type help with NULL entries


I have a table named projects. Within that table, one specific column is
called costing and is of the following schema (projects float(8,2)). Nothing
fancy. The interface that updates information to this table where the column
(projects) resides in via a php web script. Within that script it is
optional to the user as to whether they want to insert costing information
at this time. The problem lies with what mysql does at that point. If the
user provides no cost info, it simply inserts a default value of 0.00.
Thus when a query like (select * from projects) is executed, the costing
column shows 0.00. I would rather it come up blank than show 0.00. I've
tried everything I can think of to insert a NULL into that column but my
syntax must be wrong. 2 questions: 
1) What is a syntax example for inserting a NULL into a column? 
2) If a NULL is inserted into a column with a float type, does that NULL
show up as anything else other than NULL? Like my 0.00 for example. Is that
actually mysql's way of showing a NULL for that data type?



-
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: data-type help with NULL entries

2002-10-16 Thread Hammons Randy G SSgt 612 ACOMS/SCXX

Re-send.  Hopefully someone can help...

-Original Message-
From: Hammons Randy G SSgt 612 ACOMS/SCXX
[mailto:[EMAIL PROTECTED]]
Sent: Tuesday, October 15, 2002 9:01 AM
To: Mysql (E-mail)
Subject: data-type help with NULL entries


I have a table named projects. Within that table, one specific column is
called costing and is of the following schema (projects float(8,2)). Nothing
fancy. The interface that updates information to this table where the column
(projects) resides in via a php web script. Within that script it is
optional to the user as to whether they want to insert costing information
at this time. The problem lies with what mysql does at that point. If the
user provides no cost info, it simply inserts a default value of 0.00.
Thus when a query like (select * from projects) is executed, the costing
column shows 0.00. I would rather it come up blank than show 0.00. I've
tried everything I can think of to insert a NULL into that column but my
syntax must be wrong. 2 questions: 
1) What is a syntax example for inserting a NULL into a column? 
2) If a NULL is inserted into a column with a float type, does that NULL
show up as anything else other than NULL? Like my 0.00 for example. Is that
actually mysql's way of showing a NULL for that data type?


-
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




startup error

2002-10-16 Thread Zack W Kneisley

I followed the directions in the Mysql documentation, but I can't get it
to fire up properly. I dl the binary distribution

mysql-max-3.23.53-pc-linux-gnu-i686.tar.gz


Mysql 3.23.53
Redhat 8.0

When I start it from safe_mysqld I get in the .err log

Fatal error: 'Can't change to run as user 'mysql'; Please check that the
user exists!


The mysql user does exist :-)

How do I fix this please?

Zack



-
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




Autoextend

2002-10-16 Thread Silmara

How can I create a autoextend database?  
  
I tried using the following configuration: 

inoodb_data_file_path=date_d1:100M:autoextend
  
But the MySQL don't started.  
  
What's wrong?


-
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 Master and Details records

2002-10-16 Thread Michael T. Babcock

Alan McDonald wrote:

Do you know if this is true only in the same connection context only? Or
does insert_id() return another connections last insert?
  

I find it easiest to use MySQL's variables:

INSERT INTO Master ...
SELECT @MasterID:=last_insert_id();
INSERT INTO Detail1 (MasterID, Data) values (@MasterID, ...);
INSERT INTO Detail2 (MasterID, Data) values (@MasterID, ...);
... and so on and so forth.

-- 
Michael T. Babcock
C.T.O., FibreSpeed Ltd.
http://www.fibrespeed.net/~mbabcock



-
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: highly recomended MySQL version

2002-10-16 Thread Egor Egorov

usha,
Wednesday, October 16, 2002, 7:48:26 PM, you wrote:

u Can anyone suggest me the highly  recomended (non vulnerable)MySQL version.
 
What about stable version?

What OS do you use? 3.23.5X has some loading problems on Linux ..

In Ensita we use v3.23.52 and v4.0.4 on production servers.

Here is some that may help you:
 http://www.mysql.com/doc/en/Which_version.html



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




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

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




re: RE: Inserting Master and Details records

2002-10-16 Thread Egor Egorov

Alan,
Wednesday, October 16, 2002, 5:07:05 PM, you wrote:

AM Thanks you - I looked up Insert_ID() in the manual...
AM Page 171-172
AM If I insert into person but before I insert into short, someone else inserts
AM into person, surely my inserts into shirt will have their last Insert_ID()?

last_insert_id() is per-connection.

AM Do you know if this is true only in the same connection context only? Or
AM does insert_id() return another connections last insert?

Exactly.



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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




Is this possible - Remote Connection with SSL

2002-10-16 Thread Fernando Grijalba

I would like to know if this is at all possible using MySQL 4.0.4 in
Windows.

We want to be able to host our web site using either Windows and ASP or
Linux and PHP in our service provider server.  All the scripts will be in
their machine away from our network.  Then I would like for those scripts to
have access to our MySQL Server in our internal network.  The reason is that
we sell airline tickets and we would like the travel agents to book on the
site and be able to read the inventory as it changes either form bookings
on-line or in site.

I was wondering about using SSL from the ISP's machine to ours or using some
kind of VPN.

Please, any help in this matter will be really appreciated.

Thank you,

Fernando
*** sql, query ***


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

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




Re: Autoextend

2002-10-16 Thread Peter Brawley

1. inoodb should be innodb.

2. Does the directory named in innodb_data_home_dir exist?

3. Does the file date_d1 already exist?

PB

-

- Original Message -
From: Silmara [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, October 16, 2002 8:08 AM
Subject: Autoextend


 How can I create a autoextend database?

 I tried using the following configuration:

 inoodb_data_file_path=date_d1:100M:autoextend

 But the MySQL don't started.

 What's wrong?


 -
 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: RE: Inserting Master and Details records

2002-10-16 Thread Paul DuBois


sql,query

At 0:07 +1000 10/17/02, Alan McDonald wrote:
Peter,
Thanks you - I looked up Insert_ID() in the manual...
Page 171-172
If I insert into person but before I insert into short, someone else inserts
into person, surely my inserts into shirt will have their last Insert_ID()?

Surely you've tried it for yourself.

So, when you run a test scenario to check out what happens ... what happens?


Do you know if this is true only in the same connection context only? Or
does insert_id() return another connections last insert?

Alan

No other client can change the value that LAST_INSERT_ID() returns
to *you*.  It's designed to solve the very problem about which you
are concerned.

-
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: Misunderstandings about SQL

2002-10-16 Thread Michael T. Babcock

The section below should be in a loop if you expect it to happen more 
than once ...

John Chang wrote:

 body
 form name=form1 id=form1 method=post action=
   ?php echo $row_Recordset1['Sdo_ID']; ? ?php echo 
 $row_Recordset1['V_ID']; ?
   ?php echo $row_Recordset1['V_image']; ? ?php echo 
 $row_Recordset1['40K']; ?
 /form
 ?php echo $row_Recordset1['V_Title']; ?
 /body

SQL ...

-- 
Michael T. Babcock
C.T.O., FibreSpeed Ltd.
http://www.fibrespeed.net/~mbabcock



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

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




Re: mySQL on windows xp

2002-10-16 Thread Mark

- Original Message -
From: Egor Egorov [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, October 16, 2002 3:56 PM
Subject: re: mySQL on windows xp


 Mark,
 Wednesday, October 16, 2002, 4:08:03 PM, you wrote:

 M Ok, I tried to set up MySQL at home (3.23.53), on my windows machine,
 so I can test database stuff before I use it on the UNIX server. I
installed it,
 M set it up as services, the service is running, yet I get:

 M C:\mysql\binmysql.exe
 M ERROR 2003: Can't connect to MySQL server on 'localhost' (10061)

 M I created the following \my.cnf:

 M ---
 M [mysqld]
 M bind-address=212.238.195.5
 ^^^

 Why do you use bind-address=212.238.195.5 if you connect from
 localhost(127.0.0.1)?


Thanks, guys! :) Binding to 127.0.0.1 did the trick. It works lovely now. It
even works with all the databases I copied from /var/db/mysql on my FreeBSD
box (even the user-database). Since my FreeBSD box is a production server,
this way I can safely test out stuff until everything works as planned, and
not worry about screwing things up.

(Gee, I'm surprised this actually works on Windoze; and, all-in-all, without
much trouble)

- Mark


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

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




information

2002-10-16 Thread Florian Litot

hi,

Somebody saw comparaisons of productivity for mysql  and others RDBMS?
or somebody do comparaisons?

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




Where's safe_mysqld?

2002-10-16 Thread Michael Widenius


Hi!

 Chung == Chung Ha-nyung [EMAIL PROTECTED] writes:

Chung  Dear,

Chung  I installed MySQL 4.0.4 from source tarball and I found that
Chung safe_mysqld is
Chung  mentioned here and there in the manual but I can't where it,
Chung safe_mysqld, is
Chung  located. All that I found with `find . -name *safe*' command is
Chung mysqld_safe
Chung  script.

If you read the 'Upgrading from 3.23' section in the MySQL manual, you
will find that we renamed safe_mysqld to mysqld_safe in 4.0

The reason for this was that it's easier for the MySQL users if all
MySQL commands starts with my...

Regards,
Monty

-- 
For technical support contracts, goto https://order.mysql.com/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Michael Widenius [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, CTO
/_/  /_/\_, /___/\___\_\___/   Helsinki, Finland
   ___/   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: Autoextend

2002-10-16 Thread Paul DuBois

At 12:08 -0300 10/16/02, Silmara wrote:
How can I create a autoextend database? 

I tried using the following configuration:

inoodb_data_file_path=date_d1:100M:autoextend

I assume you mean innodb_... and not innnodb_... ?


But the MySQL don't started. 

What's wrong?

What does the error log say?

Is your version of MySQL older than 3.23.50?


-
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




Solved the local-infile and related problems

2002-10-16 Thread Edward C. Jones

I have solved my problem with MySQL and MySQLdb. The problem was:

I have installed mysql-3.23.52 as part of the Gentoo Linux
distribution. I am accessing MySQL via mysql-python AKA MySQLdb
which calls the MySQL C API. During testing I start MySQL using
safe_mysqld and shutdown MySQL using mysqladmin -u root
--password= shutdown.

When I do a LOAD DATA LOCAL INFILE via MySQLdb, I get the
well-known error message 1148: The used command is not allowed
with this MySQL version.

1. Add to mysql-3.23.52.ebuild the line

myconf=${myconf} --enable-local-infile

It goes in the src_compile() section. Do an emerge dev-db/mysql to rebuild
MySQL.

2. Recompile mysql-python (which contains MySQLdb). I suspect the segfaults
I was having were due to library mismatches. Therefore build MySQLdb after
MySQL.

3. Add local-infile to /etc/mysql/my.cnf in the groups [safe_mysql],
[mysqld], and [mysql]. Do not add it to the group [client].

4. At some point the MySQL GRANT system was changed. Now

GRANT FILE ON my_database.* TO abcdefgh@localhost IDENTIFIED BY '';

does not work. One must use:

GRANT FILE ON *.* TO abcdefgh@localhost IDENTIFIED BY '';

Note that now abcdefgh can access any file on any database. I wish I could
use LOAD DATA LOCAL INFILE is a more secure manner.



-
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




load problems on mysql 3.23.52 with and without Max

2002-10-16 Thread Lars Andersson

I'm managing two database servers, one 3.23.52 and one 3.23.52-Max
(using innodb tables on that one).

They are both running along fine until they suddently start to
accumulate a lot of treads (a lot ~= 200-300), the state of these
threads is mostly closing and opening tables. This drives up the
load to amazing numbers and I'm forced to shut the mysql-server down.

Since I'm running these servers in a shared environment I got a lot of
users using these servers, and so far I haven't got any grip on whats
causing these problems. I got these problems on both servers (one with
max and one without), both servers got diffrent users.

I've ruled out hardware problems since I get exactly the same behaviour
on two independent servers.

It would be great if sombody knows the answer to my questions bellow:
- is there any know problems with mysql on linux? or with 3.23.52 that
  should cause this behaviour

- what should I do to find the error, my logs shows nothing pecuilar.
  I'm currently dumping a processlist each five seconds to a file.


regards
/Lars


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

2002-10-16 Thread Victoria Reznichenko

Silmara,
Wednesday, October 16, 2002, 6:08:18 PM, you wrote:

S I tried using the following configuration: 

S inoodb_data_file_path=date_d1:100M:autoextend
^

innodb_data_file_path
  
S But the MySQL don't started.  
  
S What's wrong?

What error did you get? Check error logs.


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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: RE: data-type help with NULL entries

2002-10-16 Thread Egor Egorov

Hammons,
Wednesday, October 16, 2002, 4:57:10 PM, you wrote:

HRGS6AS I have a table named projects. Within that table, one specific column is
HRGS6AS called costing and is of the following schema (projects float(8,2)). Nothing
HRGS6AS fancy. The interface that updates information to this table where the column
HRGS6AS (projects) resides in via a php web script. Within that script it is
HRGS6AS optional to the user as to whether they want to insert costing information
HRGS6AS at this time. The problem lies with what mysql does at that point. If the
HRGS6AS user provides no cost info, it simply inserts a default value of 0.00.
HRGS6AS Thus when a query like (select * from projects) is executed, the costing
HRGS6AS column shows 0.00. I would rather it come up blank than show 0.00. I've
HRGS6AS tried everything I can think of to insert a NULL into that column but my
HRGS6AS syntax must be wrong. 2 questions: 
HRGS6AS 1) What is a syntax example for inserting a NULL into a column? 

INSERT INTO table_name(column) VALUES(NULL)

HRGS6AS 2) If a NULL is inserted into a column with a float type, does that NULL
HRGS6AS show up as anything else other than NULL? Like my 0.00 for example. Is that
HRGS6AS actually mysql's way of showing a NULL for that data type?

No, if column can have NULL values (not defined as NOT NULL).



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




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

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




re: startup error

2002-10-16 Thread Victoria Reznichenko

Zack,
Wednesday, October 16, 2002, 5:56:11 PM, you wrote:

ZWK I followed the directions in the Mysql documentation, but I can't get it
ZWK to fire up properly. I dl the binary distribution

ZWK mysql-max-3.23.53-pc-linux-gnu-i686.tar.gz


ZWK Mysql 3.23.53
ZWK Redhat 8.0

ZWK When I start it from safe_mysqld I get in the .err log

ZWK Fatal error: 'Can't change to run as user 'mysql'; Please check that the
ZWK user exists!


ZWK The mysql user does exist :-)

ZWK How do I fix this please?

Run nscd and then run MySQL server.

3.23.53 was built with another glibc that has no nss staticlly linked
in.


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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




one table frozen, rest is okey...

2002-10-16 Thread Przemyslaw Popielarski

I'm using mysql  Ver 11.16 Distrib 3.23.49, for slackware-linux-gnu (i386).

Everything was just fine for months, but yeasterday I started to use one of
the tables by connecting to it with MS Access 2000. The table has ~10
records.  And the strange thing: it was working for few hours (queries,
updates, etc.. everything from Access through myODBC 2.50), and then
suddenly it frozen!  So I checked the server - every table on the server
worked just fine.

Describe problematic_table also ok. But select * from problematic_table
limit 10 :  freeze. Select * from another_table : OK.

I have no idea why only one table stoped working. I shutdowned the server
and brought it up and it is ok now. But what was the reason for freezing the
table ?

--
./ premax
./ [EMAIL PROTECTED]



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

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




Re: Slow performance with full text index

2002-10-16 Thread Michael T. Babcock

Xavier LENOIR wrote:


I use queries like this :
SELECT count(*) FROM MyTable WHERE (MATCH(Title) AGAINST('a word'));
SELECT * FROM MyTable WHERE (MATCH(Title) AGAINST('a word')) LIMIT 10;

  

Have you tried building a seperate table of titles for the sake of 
having a smaller table to scan through?

SELECT * FROM MyTable LEFT JOIN Titles ON TitleID = Titles.ID WHERE 
(MATCH (Titles.Name) AGAINST ('a word')) LIMIT 10;

... I've found this type of optimization helps on large (disk-size) 
tables.  It helps even more if you make the table like:

CREATE TABLE Titles (
ID int unsigned not null auto_increment,
Name CHAR(150),
PRIMARY KEY (ID),
FULLTEXT (Name),
INDEX NameIdx(Name)
);

(Try both types of index to see if either is faster ... )

Also try putting your 'Autx' fields in a seperate table, for the sake of 
good design, then create a cross-linked table to join it to the main table.

tables
--
MyTable: ID, TitleID, details. { PRIMARY KEY (ID) }
Titles: ID, Name { PRIMARY KEY {ID) }
Auts: ID, Data { PRIMARY KEY (ID) }

PS, would you believe this message never contained SQL or QUERY?
MovieAuts: MovieID, AutID { PRIMARY KEY MovieAutIDX (MovieID, AutID);

-- 
Michael T. Babcock
C.T.O., FibreSpeed Ltd.
http://www.fibrespeed.net/~mbabcock



-
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: Normalization sql

2002-10-16 Thread Michael T. Babcock

John Chang wrote:


 Studios (StudioName, StudioID)
 Genres (GenreName, GenreID)
 Titles (VideoTitle, Details, StudioID, GenreID, BitRateID, TitleID)
 Actors (F_Name, L_Name, ActorID)
 Stars (TitleID, ActorID)

 TitleGenres (TitleID, GenreID)

 So, if I just use theses tables I will be OK if the video has multiple 
 titles, multiple actors,  multiple genres?

 How do I create a junction table?  Example, between Genres and Titles, 
 how do I add the to PK fields to TitleGenres?  Do I just create the 
 TitleGenres table and add the TitleID  GenreID field and does the 
 database know they are linked?

Sort of; assuming you create a junction table called TitleActors with 
TitleID, ActorID, and you want the movies with Stalone as the actor 
them, you might do a query like:

select * from Titles
LEFT JOIN TitleActors ON Title.ID = TitleID
LEFT JOIN Actors ON ActorID = Actors.ID
WHERE Actors.L_Name = Stalone;

-- 
Michael T. Babcock
C.T.O., FibreSpeed Ltd.
http://www.fibrespeed.net/~mbabcock



-
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: about use Dev-cpp and C++

2002-10-16 Thread Michael T. Babcock

Insanely Great wrote:

Is it necessary that you usee STL. Other wise MySQL C API are much more
easy to maintain and program. Even SQLyog which I am a beta tester is
written using MySQL C API and its very fast.
  

But it would be so nice to write:

MySQLConn DB = new MySQLConn ('host', 'port');
DB.Login('user', 'pass');
MySQLTransaction X = new MySQLQuery(DB);

// STL-derived slist:
MySQLResults Results = X.Query(...);

// STL map:
map Row;
while (Results.NextRow(Row)) {
cout  ID:   Row[ID]  , Value:   Row[Value]  endl;
}

... PS, anyone seen such an API? :)

-- 
Michael T. Babcock
C.T.O., FibreSpeed Ltd.
http://www.fibrespeed.net/~mbabcock



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

2002-10-16 Thread Silmara


- Original Message -
From: Paul DuBois [EMAIL PROTECTED]
To: Silmara [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Wednesday, October 16, 2002 12:16 PM
Subject: Re: Autoextend


 At 12:08 -0300 10/16/02, Silmara wrote:
 How can I create a autoextend database?
 
 I tried using the following configuration:
 
 inoodb_data_file_path=date_d1:100M:autoextend

 I assume you mean innodb_... and not innnodb_... ?

It's Ok. innodb_data_file_path=date_d1:100M:autoextend and date_d1 don't
exists.



 
 But the MySQL don't started.
 
 What's wrong?

 What does the error log say?

 Is your version of MySQL older than 3.23.50?

My version of MySQL is 3.23.39


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

2002-10-16 Thread Silmara


- Original Message - 
From: Peter Brawley [EMAIL PROTECTED]
To: Silmara [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Wednesday, October 16, 2002 12:18 PM
Subject: Re: Autoextend


 1. inoodb should be innodb.
Ok. I typed wrong in the e-mail.
 
 2. Does the directory named in innodb_data_home_dir exist?
Yes
 
 3. Does the file date_d1 already exist?
No
 
 PB
 
 -
 
 - Original Message -
 From: Silmara [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Wednesday, October 16, 2002 8:08 AM
 Subject: Autoextend
 
 
  How can I create a autoextend database?
 
  I tried using the following configuration:
 
  inoodb_data_file_path=date_d1:100M:autoextend
 
  But the MySQL don't started.
 
  What's wrong?
 
 
  -
  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: Autoextend

2002-10-16 Thread Paul DuBois

At 13:33 -0300 10/16/02, Silmara wrote:
- Original Message -
From: Paul DuBois [EMAIL PROTECTED]
To: Silmara [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Wednesday, October 16, 2002 12:16 PM
Subject: Re: Autoextend


  At 12:08 -0300 10/16/02, Silmara wrote:
  How can I create a autoextend database?
  
  I tried using the following configuration:
  
  inoodb_data_file_path=date_d1:100M:autoextend

  I assume you mean innodb_... and not innnodb_... ?

It's Ok. innodb_data_file_path=date_d1:100M:autoextend and date_d1 don't
exists.



  
  But the MySQL don't started.
  
  What's wrong?

  What does the error log say?

  Is your version of MySQL older than 3.23.50?

My version of MySQL is 3.23.39


That's the problem.  autoextend is supported as of 3.23.50.

-
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: load problems on mysql 3.23.52 with and without Max

2002-10-16 Thread Lars Andersson

This problems are making me a bit tired, forgot to give you information
about the systems.

MySQL-3.23.52
dual pentium 700, 800MB ram
RedHat 6.1
Kernel 2.2.19-6.2.1smp
glibc-2.1.3-27

MySQL-3.23.52-Max
dual pentium 1.4Ghz, 2 GB ram
Redhat 7.3
Kernel 2.4.18-10smp
glibc-2.2.5-40

regards
/Lars


On Wed, 16 Oct 2002, Lars Andersson wrote:

 I'm managing two database servers, one 3.23.52 and one 3.23.52-Max
 (using innodb tables on that one).

 They are both running along fine until they suddently start to
 accumulate a lot of treads (a lot ~= 200-300), the state of these
 threads is mostly closing and opening tables. This drives up the
 load to amazing numbers and I'm forced to shut the mysql-server down.

 Since I'm running these servers in a shared environment I got a lot of
 users using these servers, and so far I haven't got any grip on whats
 causing these problems. I got these problems on both servers (one with
 max and one without), both servers got diffrent users.

 I've ruled out hardware problems since I get exactly the same behaviour
 on two independent servers.

 It would be great if sombody knows the answer to my questions bellow:
 - is there any know problems with mysql on linux? or with 3.23.52 that
   should cause this behaviour

 - what should I do to find the error, my logs shows nothing pecuilar.
   I'm currently dumping a processlist each five seconds to a file.


 regards
 /Lars




-
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: adding a string to enum

2002-10-16 Thread Michael T. Babcock

Russ  Cindy Stanger wrote:

When I try to add a string to the end of an enum list I get the following
error message:

You have an error in your SQL syntax near '\','Historical
  

It looks like you've accidentally added a slash to quote a quote ... 
check your code.

However, I'd highly suggest using another table and doing a JOIN when 
you're at this size of ENUM and you plan on adding/removing values.

Add standards_topic_id to INT UNSIGNED NOT NULL and create a table:
standards_topics ( id INT UNSIGNED NOT NULL AUTO_INCREMENT, topic_name 
VARCHAR(50));

Then insert the values into standards_topics and use a JOIN in your query.
For example ...
SELECT * FROM table
LEFT JOIN standards_topics ON standards_topic_id = standards_topics.id
WHERE  AND topic_name = Foundation and Government;

You'll find the values a lot easier to maintain this way.

-- 
Michael T. Babcock
C.T.O., FibreSpeed Ltd.
http://www.fibrespeed.net/~mbabcock



-
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 installing on Solaris/Intel

2002-10-16 Thread Jesse Sheidlower

On Wed, Oct 16, 2002 at 10:15:43AM -0400, Ben Goodwin wrote:
 I've compiled and installed this on my Solaris8/Intel box a few times
 without a hitch.. I don't recall seeing what version of Solaris you're
 running.. ?

I'm running Solaris 8 with gcc 2.95.2.

 I also compiled with just ./configure - I didn't bother with the other
 options.. although that might be asking for trouble under certain
 circumstances...
 I don't have the source in front of me to check but I seem to recall being
 able to compile specifically withOUT curses support?  Is your ncurses
 library up to date?  Changing which curses libs to use won't affect this
 issue - the issue is a header/include problem, not a library problem.
 If that doesn't help, let me know and I'll try to suggest other things as
 well as check out my installation

I've finally managed to get past this by updating ncurses to 5.2 and
setting the -I flag to the CFLAGS and CXXFLAGS to point to the location
of the new ncurses. Now I've gotten past this but hit another error
that is even more mystifying:

---
creating thread_test
Making all in strings
gcc -c -o strings-x86.o strings-x86.s
Assembler:
strings-x86.s, line 1 : Illegal mnemonic
strings-x86.s, line 1 : Syntax error
strings-x86.s, line 1 : Illegal mnemonic
strings-x86.s, line 1 : Illegal mnemonic
[...]
strings-x86.s, line 3 : Illegal mnemonic
Too many errors - Goodbye
*** Error code 1
make: Fatal error: Command failed for target `strings-x86.o'
Current working directory /usr/local/src/mysql-3.23.52/strings
*** Error code 1
make: Fatal error: Command failed for target `all-recursive'
Current working directory /usr/local/src/mysql-3.23.52
*** Error code 1
make: Fatal error: Command failed for target `all-recursive-am'
---

I've looked for this error in various places and been unable to
find it.

Any ideas this time? And thanks again!

Jesse Sheidlower
sql, query

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

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




Re: load problems on mysql 3.23.52 with and without Max

2002-10-16 Thread David BORDAS

This problem is due to the glibc used by mysql AB for building binary ...

Have a look to mysql 3.23.53 change log :

We've hopefully fixed the problem with spurious load spikes on Linux
 systems when accessing the Database via TCP/IP. This was caused by
the
 static glibc files we used to link against and should now be resolved


But 3.23.53 have other problems, so if you want to upgrade, wait some hours
for 3.23.53a binary ...

David


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

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




killing a hung thread

2002-10-16 Thread Inandjo Taurel

hi,
i'd like to know if there is a way to tell the mysqld to remove a thread 
that has hang, without human intervention.
Let say an update query is fired to the engine, and the client just freezes 
and we have to reboot the machine manually:  how can i make sure that mysqld 
will remove that thread from the process list thus freeing the table locked 
during the update??

SQLSQL



_
Broadband? Dial-up? Get reliable MSN Internet Access. 
http://resourcecenter.msn.com/access/plans/default.asp


-
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: remote connections have stopped working

2002-10-16 Thread Jon Keller



Mysql was installed from binary, and this is redhat 7.3 running kernel 
2.4.18-3



At 02:16 PM 10/16/2002 +0300, you wrote:
Jon,
Wednesday, October 16, 2002, 8:04:12 AM, you wrote:

JK I'm running mysql-3.23.49 on a redhat machine, mysql has stopped 
responding
JK to remote connections ever since i rebooted it today.
JK /var/log/mysqld.log says

JK Number of processes running now: 1
JK mysqld process hanging, pid 3062 - killed
JK 021015 20:37:05 mysqld restarted
JK /usr/libexec/mysqld: ready for connections

JK when a connection is made.
JK I ran safe_mysqld from the command line and tried to connect i got 
this error.

JK /usr/bin/safe_mysqld: line 273: 16126 Segmentation fault $NOHUP_NICENESS
JK $ledir/$MYSQLD $defaults --basedir=$MY_BASEDIR_VERSION --datadir=$DATADIR
JK $USER_OPTION --pid-file=$pid_file --skip-locking $err_log 21

JK Number of processes running now: 1
JK mysqld process hanging, pid 16129 - killed
JK 021015 23:51:15 mysqld restarted

Did you installed MySQL server from binary or from source?
What is the version of RedHat? What is the kernel version?


--
For technical support contracts, goto https://order.mysql.com/?ref=ma02-010c
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


-
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 db as filesystem.

2002-10-16 Thread Michael T. Babcock

Jan Steinman wrote:

I believe the Pick operating system from the 70's had a database filesystem, for 
example. It was popular among business types. As I recall, it also had a BASIC 
command interpreter as its primary way of interacting with the system.

FWIW, we use Pick database systems quite a bit where I work -- see 
http://www.picksys.com and http://www.jbase.com for more information.

Today's modern operating systems really stopped evolving in the 80's. Many ideas 
like database filesystems never really got a chance to show their utility.

Although recent filesystem developments like ReiserFS (especially 
version 4) are really shining through.

I agree that it would be interesting to slide MySQL under a filesystem, but it sounds 
like a lot of work!
  

... although probably not the least bit useful -- if you look at some of 
the great stuff Reiser4 does, you probably won't see a need to use a 
backend like MySQL at all.

-- 
Michael T. Babcock
C.T.O., FibreSpeed Ltd.
http://www.fibrespeed.net/~mbabcock



-
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: remote connections have stopped working

2002-10-16 Thread Jon Keller

Moving from glibc 2.2.5-40 to glibc 2.2.5-39 has solved the problem i was 
having with remote connections,
Thanks to everyone who helped.


-Jon Keller



At 06:18 AM 10/16/2002 -0500, you wrote:
I started to receive this error as well after upgrading the glibc update
just released from Red Hat.

I was told to either upgrade mysql from mysql.com or downgrade the glibc.
I chose to downgrade glibc and wait for Red Hat's fix.  The bug is posted on
their site.

Once I downgraded the glibc packages, all was fine again.

regards,
-dan

-Original Message-
From: Jon Keller [mailto:[EMAIL PROTECTED]]
Sent: October 16, 2002 12:04 AM
To: [EMAIL PROTECTED]
Subject: remote connections have stopped working


I'm running mysql-3.23.49 on a redhat machine, mysql has stopped responding
to remote connections ever since i rebooted it today.
/var/log/mysqld.log says

Number of processes running now: 1
mysqld process hanging, pid 3062 - killed
021015 20:37:05 mysqld restarted
/usr/libexec/mysqld: ready for connections

when a connection is made.
I ran safe_mysqld from the command line and tried to connect i got this
error.

/usr/bin/safe_mysqld: line 273: 16126 Segmentation fault $NOHUP_NICENESS
$ledir/$MYSQLD $defaults --basedir=$MY_BASEDIR_VERSION --datadir=$DATADIR
$USER_OPTION --pid-file=$pid_file --skip-locking $err_log 21

Number of processes running now: 1
mysqld process hanging, pid 16129 - killed
021015 23:51:15 mysqld restarted



Any help with this issue would be much appreciated.

-Jon Keller


-
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: about use Dev-cpp and C++

2002-10-16 Thread Ed Carp

sql, query

 But it would be so nice to write:

 MySQLConn DB = new MySQLConn ('host', 'port');
 DB.Login('user', 'pass');
 MySQLTransaction X = new MySQLQuery(DB);

 // STL-derived slist:
 MySQLResults Results = X.Query(...);

 // STL map:
 map Row;
 while (Results.NextRow(Row)) {
 cout  ID:   Row[ID]  , Value:   Row[Value]  endl;
 }

 ... PS, anyone seen such an API? :)

How about:

OpenDatabase(host, database, user, pass);
OpenRecordset(select * from blah);
while(RecordsetEOF() != EOF)
{
printf(ID: %d Value: %s\n, GetField(ID), GetField(Value));
MoveNext();
}
CloseRecordset();
}

Look for MyC on mysql.com - if you can't find it, email me directly.  The most recent 
version supports nested SQL, too.  The
Escapade server-side programming language is built on top of MyC.
--
Ed Carp, N7EKG  http://www.pobox.com/~erc   214/986-5870
Licensed Texas Peace Officer
Computer Crime Investigation Consultant

Director, Software Development
Escapade Server-Side Scripting Engine Development Team
Pensacola - Dallas - London - Dresden
http://www.squishedmosquito.com

The whole aim of practical politics is to keep the populace alarmed-- and
thus clamorous to be led to safety-- by menacing it with an endless series
of hobgoblins, all of them imaginary.
-- H. L. Mencken


-
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: load problems on mysql 3.23.52 with and without Max

2002-10-16 Thread Lars Andersson

I had the same problem with 4.0.4, I downgraded to 3.23.52 because I 
thought it was something with the unstable version. Is 4.0.4 also built 
against the same static glibc?

regards
/Lars

This problem is due to the glibc used by mysql AB for building binary ...

Have a look to mysql 3.23.53 change log :

We've hopefully fixed the problem with spurious load spikes on Linux
  systems when accessing the Database via TCP/IP. This was caused by
the
  static glibc files we used to link against and should now be resolved
 

But 3.23.53 have other problems, so if you want to upgrade, wait some hours
for 3.23.53a binary ...

David


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

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




Oracle wrapper in MYSQL

2002-10-16 Thread mtralhao

Hi,

 I'd like to know if there is something similar to Oracle's Wrapper
in MYSQL.

 Thanks in advance.


-
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




Help Migrating from NuSphere

2002-10-16 Thread Mark Graves

Previously I had been a NuSphere subscriber for MySQL (and PHP and Apache).  As you 
probably know, NuSphere no longer produces or supports the MySQL product.  How do I 
migrate out of the NuSphere?

I currently have:

RH Linux 7.2 (kernel 2.4.9-34)
MySQL 3.23.44-100.nusphere
Location: /usr/local/nusphere/mysql/bin

I would like to move everything over to the current version of MySQL directly from 
MySQL without loosing all my databases and/or creating other problems.  What the best 
(easiest) way to do this?

Thanks in advance,
mg


-
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




multiple incremental inserts

2002-10-16 Thread Andrew Hazen

Greetings,

I need to be able to insert many rows into a table at once.  Only one
field, an incremental serial number will change for each row.  Is there
a way to do that in a single query? I need to be able to specify the
start and end points (i.e. start at 59 and end at 605000) Or do I
have to put the query in a for_next loop and let the webserver churn
away on it?

Thanks.

Andrew Hazen, O.C.P.   Jatech Solutions Inc.
E-Commerce Developer   www.jatech.ca

Specializing in OSCOMMERCE applications and PHP/MySQL programming.

[EMAIL PROTECTED]
[EMAIL PROTECTED]



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

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




Back Table syntax

2002-10-16 Thread Karam Chand

hello..

i have a winxp and linux 7.2 on the same machine. I
have mysql on the linux server and MyCC in the win
partition. 

i connect to the linux MySQL using the vmware lopback
adapter. everything is working fine. 

now when i issue a backup table syntax. it is giving
syntax. Is back table only works in backing up table
in the server or I can make a copy thru a client
software like MyCC

karam

__
Do you Yahoo!?
Faith Hill - Exclusive Performances, Videos  More
http://faith.yahoo.com

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

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




Re: How many columns does MySQL Support?

2002-10-16 Thread Jan Steinman

From: Andrew Kuebler [EMAIL PROTECTED]

2) Is it just as fast with Mysql to access 10 fields in a table with 10
columns as it would be to access those same 10 fields among let's say 90
other fields in a 100 column table?

Are you certain that performance should be your primary concern here?

I prefer to design databases with separate tables of tightly coupled information, then 
LEFT JOIN them as needed. This makes maintenance much easier, and may also be a 
performance plus, due to locality of reference issues.

Only when I'm certain that this form (4NF? I forget) is negatively impacting 
performance do I bother optimizing to 3NF by permanently joining tables.

 SQL SQL SQL SQL SQL SQL SQL SQL 

-- 
: Jan Steinman -- nature photography: http://www.Bytesmiths.com
: Bytesmiths -- artists' services: http://www.Bytesmiths.com/Services
: Join the forums at http://www.Bytesmiths.com/wiki


-
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




Query for multiple rows

2002-10-16 Thread Phillip S. Baker

Greetings all,

I have a users table in the DB.
I am importing allot of existing data from various places into this users 
table.
There is a strong likelihood of the same user getting entered twice.
Though each record will have a separate and unique ID, I want to be able to 
query the table and look for duplicate records based on first name last name.

So for clarity I want to execute a query to one table.
The results I want displayed are a listing of records that have the same 
first name and last name of other records in that same table.

Am I making this clear and what do I need to do?

Thanx

Fibilt


-
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 UPDATE table ... can u help plz?

2002-10-16 Thread STIBS

Hi from Dresden, Germany!

I have a littlebig problem:

I want to UPDATE table1.fields with data from table2.fields WHERE the id (in this
case a product number) is the same in both tables.

OK, I did this:

UPDATE table1 SET table1.field1 = table2.field1, table1.field2 = table2.field2,...
WHERE table1.id = table2.id;

The answer from MySQL is: Unknown table 'table2' in WHERE clause .

Heading to MySQL.com the docs tell me nothing than there is a INSERT ... SELECT.

In my case this would be an UPDATE ... SELECT coz I don't want a new table, just
updating records of an existing with data from another.

I'm sure I just miss the right topic to look at. Point me please.

Second try:

I used

UPDATE table1, table2 SET table1.field1 = table2.field1, table1.field2 = 
table2.field2,...
WHERE table1.id = table2.id;

It still gives me an error, now  in the SQL Syntax when I set the table1.field2 value. 
It doesn't find the second tables name [You have an error... near ... table(2.field2 
should be here)].

Could someone give me the right direction?

TIA!

Michael Stibane (STIBS)
[EMAIL PROTECTED]
Training, Linux, Admin, Programming, Web
http://www.stibs.cc

Escapade Server-Side Scripting Engine Development Team
Pensacola - Dallas - Dresden - London
http://www.escapade.org


-
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: killing a hung thread

2002-10-16 Thread Lopez David E-r9374c

Inandjo

Try setting the variable connection_timeout to 300 seconds.
That way, the mysqld will close the connection automatically.

Set the variable in file my.cnf.

David


 -Original Message-
 From: Inandjo Taurel [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, October 16, 2002 9:54 AM
 To: [EMAIL PROTECTED]
 Subject: killing a hung thread
 
 
 hi,
 i'd like to know if there is a way to tell the mysqld to 
 remove a thread 
 that has hang, without human intervention.
 Let say an update query is fired to the engine, and the 
 client just freezes 
 and we have to reboot the machine manually:  how can i make 
 sure that mysqld 
 will remove that thread from the process list thus freeing 
 the table locked 
 during the update??
 
 SQLSQL
 
 
 
 _
 Broadband? Dial-up? Get reliable MSN Internet Access. 
 http://resourcecenter.msn.com/access/plans/default.asp
 
 
 -
 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-max-3.23.52-win

2002-10-16 Thread Silmara

I installed MySQL-max-3.23.52-win in the Win98 with the following
configuration

#This File was made using the WinMySQLAdmin 1.4 Tool
#16/10/2002 14:37:55

#Uncomment or Add only the keys that you know how works.
#Read the MySQL Manual for instructions

[WinMySQLadmin]
Server=C:/MYSQL/bin/mysqld-max.exe
user=root


[mysqld]
basedir=C:/MYSQL
datadir=C:/MYSQL/data
innodb_data_home_dir=C:/MYSQL/data
innodb_data_file_path=data_d1:50M:autoextend
innodb_log_group_home_dir=c:/mysql/data
innodb_log_arch_dir=c:/mysql/data
set-variable=key_buffer=32M
set-variable=innodb_buffer_pool_size=32M

but the startup is very slower.
Is it normal?
What's the problem?
Should I use another stableer version?
I want to use Innodb with autoextend.


-
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-max-3.23.52-win

2002-10-16 Thread Dyego Souza do Carmo

Dobrý den,
quarta-feira, 16 de outubro de 2002, 17:33:00, napsal jste:

S I installed MySQL-max-3.23.52-win in the Win98 with the following
S configuration

S #This File was made using the WinMySQLAdmin 1.4 Tool
S #16/10/2002 14:37:55

S #Uncomment or Add only the keys that you know how works.
S #Read the MySQL Manual for instructions

S [WinMySQLadmin]
S Server=C:/MYSQL/bin/mysqld-max.exe
S user=root


S [mysqld]
S basedir=C:/MYSQL
S datadir=C:/MYSQL/data
S innodb_data_home_dir=C:/MYSQL/data
S innodb_data_file_path=data_d1:50M:autoextend
S innodb_log_group_home_dir=c:/mysql/data
S innodb_log_arch_dir=c:/mysql/data
S set-variable=key_buffer=32M
S set-variable=innodb_buffer_pool_size=32M

S but the startup is very slower.
S Is it normal?
S What's the problem?
S Should I use another stableer version?
S I want to use Innodb with autoextend.

Yes, in = .52 is normal... use the 3.23.53 version.

http://www.mysql.com


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


-
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: Query for multiple rows

2002-10-16 Thread Lopez David E-r9374c

Fibilt

try: 

  SELECT id, concat(lname, fname) as name, count(*) as cnt 
FROM table1 
GROUP BY name 
HAVING cnt  1;

This is close anyhow.

David

 -Original Message-
 From: Phillip S. Baker [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, October 16, 2002 1:17 PM
 To: [EMAIL PROTECTED]
 Subject: Query for multiple rows
 
 
 Greetings all,
 
 I have a users table in the DB.
 I am importing allot of existing data from various places 
 into this users 
 table.
 There is a strong likelihood of the same user getting entered twice.
 Though each record will have a separate and unique ID, I want 
 to be able to 
 query the table and look for duplicate records based on first 
 name last name.
 
 So for clarity I want to execute a query to one table.
 The results I want displayed are a listing of records that 
 have the same 
 first name and last name of other records in that same table.
 
 Am I making this clear and what do I need to do?
 
 Thanx
 
 Fibilt
 
 
 -
 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: Query for multiple rows

2002-10-16 Thread Greg Knaddison

I've tested this on a table of mine with different names, so it should work when you 
tweak your columns/table.  The having clause is a seldom taught, but highly useful 
clause.

select count(1), first_name, last_name
from myuserstable
group by first_name, last_name
having count(1)  1;

You should be able to get rid of the count(1) in the select list if you want.

For more information on select queries and the having clause you can look at this 
manual page:

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

Greg

SQL, query, duplicate, having clause

-Original Message-
From: Phillip S. Baker [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 16, 2002 2:17 PM
To: [EMAIL PROTECTED]
Subject: Query for multiple rows


Greetings all,

I have a users table in the DB.
I am importing allot of existing data from various places into this users 
table.
There is a strong likelihood of the same user getting entered twice.
Though each record will have a separate and unique ID, I want to be able to 
query the table and look for duplicate records based on first name last name.

So for clarity I want to execute a query to one table.
The results I want displayed are a listing of records that have the same 
first name and last name of other records in that same table.

Am I making this clear and what do I need to do?

Thanx

Fibilt

-
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




Wierd login problem

2002-10-16 Thread Bill Leath

I am trying to use mysql.

I use the line

mysql -u username -p
and then enter the correct password

The error message I get is  error 1045 access denied for user:
username@localhost (Using password: YES)

I know that I am using the correct username and password, because an
application using jdbc uses the same username and password and can
login.

Any Ideas?

Thanks,

Bill




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

2002-10-16 Thread Gustavo Vieira Gonçalves Coelho Rios

Florian Litot wrote:
 
 hi,
 
 Somebody saw comparaisons of productivity for mysql  and others RDBMS?
 or somebody do comparaisons?
 
 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


Sorry gentleman,

I don't even have an ideia about what you say!

Productivity for MySQL ? What do mean about that?

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

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




Re: Problem with UPDATE table ... can u help plz?

2002-10-16 Thread Bruce Lewis

You need an InnerJoin to perform the operation similar to:

UPDATE table1 SET table1.field1 = table2.field1, table1.field2 =
table2.field2,...
 INNER JOIN Table1 ON Table2.ID = Table1.ID


Bruce Lewis


- Original Message -
From: STIBS [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, October 16, 2002 4:26 PM
Subject: Problem with UPDATE table ... can u help plz?


Hi from Dresden, Germany!

I have a littlebig problem:

I want to UPDATE table1.fields with data from table2.fields WHERE the id (in
this
case a product number) is the same in both tables.

OK, I did this:

UPDATE table1 SET table1.field1 = table2.field1, table1.field2 =
table2.field2,...
WHERE table1.id = table2.id;

The answer from MySQL is: Unknown table 'table2' in WHERE clause .

Heading to MySQL.com the docs tell me nothing than there is a INSERT ...
SELECT.

In my case this would be an UPDATE ... SELECT coz I don't want a new table,
just
updating records of an existing with data from another.

I'm sure I just miss the right topic to look at. Point me please.

Second try:

I used

UPDATE table1, table2 SET table1.field1 = table2.field1, table1.field2 =
table2.field2,...
WHERE table1.id = table2.id;

It still gives me an error, now  in the SQL Syntax when I set the
table1.field2 value. It doesn't find the second tables name [You have an
error... near ... table(2.field2 should be here)].

Could someone give me the right direction?

TIA!

Michael Stibane (STIBS)
[EMAIL PROTECTED]
Training, Linux, Admin, Programming, Web
http://www.stibs.cc

Escapade Server-Side Scripting Engine Development Team
Pensacola - Dallas - Dresden - London
http://www.escapade.org


-
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: Problem with UPDATE table ... can u help plz?

2002-10-16 Thread Greg Knaddison

When I try that modified for my tables that fit this hypothetical, I get:

CREATE TABLE `sales_table` (
  `item_s` varchar(100) default '',
  `price_s` varchar(100) default ''
) TYPE=MyISAM

CREATE TABLE `lookup_table` (
  `item_l` varchar(100) default '',
  `price_l` varchar(100) default ''
) TYPE=MyISAM


mysql UPDATE sales_table SET sales_table.price_s = lookup_table.price_l INNER JOIN 
sales_table ON lookup_table.item_l = sales_table.item_s;

[localhost] ERROR 1064: You have an error in your SQL syntax near 'INNER JOIN 
sales_table ON lookup_table.item_l = sales_table.item_s' at line 1

The Update Syntax Manual page 6.4.5 http://www.mysql.com/doc/en/UPDATE.html doesn't 
mention INNER JOIN and the comments on that page seem to indicate that this is a 
functionality lacking in MySQL though the last comment on the page shows a kluge 
workaround.

Greg


-Original Message-
From: Bruce Lewis [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 16, 2002 4:03 PM
To: STIBS; [EMAIL PROTECTED]
Subject: Re: Problem with UPDATE table ... can u help plz?


You need an InnerJoin to perform the operation similar to:

UPDATE table1 SET table1.field1 = table2.field1, table1.field2 =
table2.field2,...
 INNER JOIN Table1 ON Table2.ID = Table1.ID


Bruce Lewis


- Original Message -
From: STIBS [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, October 16, 2002 4:26 PM
Subject: Problem with UPDATE table ... can u help plz?


Hi from Dresden, Germany!

I have a littlebig problem:

I want to UPDATE table1.fields with data from table2.fields WHERE the id (in
this
case a product number) is the same in both tables.

OK, I did this:

UPDATE table1 SET table1.field1 = table2.field1, table1.field2 =
table2.field2,...
WHERE table1.id = table2.id;

The answer from MySQL is: Unknown table 'table2' in WHERE clause .

Heading to MySQL.com the docs tell me nothing than there is a INSERT ...
SELECT.

In my case this would be an UPDATE ... SELECT coz I don't want a new table,
just
updating records of an existing with data from another.

I'm sure I just miss the right topic to look at. Point me please.

Second try:

I used

UPDATE table1, table2 SET table1.field1 = table2.field1, table1.field2 =
table2.field2,...
WHERE table1.id = table2.id;

It still gives me an error, now  in the SQL Syntax when I set the
table1.field2 value. It doesn't find the second tables name [You have an
error... near ... table(2.field2 should be here)].

Could someone give me the right direction?

TIA!

Michael Stibane (STIBS)
[EMAIL PROTECTED]
Training, Linux, Admin, Programming, Web
http://www.stibs.cc

Escapade Server-Side Scripting Engine Development Team
Pensacola - Dallas - Dresden - London
http://www.escapade.org


-
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




MySql module won't load in Apache (DebianLinux)

2002-10-16 Thread Chip Rose

Apache document root works fine, and php3 is fine also.  I uncommented the
lines in /etc/apache/httpd.conf
LoadModule php3_module /usr/lib/apache/1.3/libphp3.so
AddType application/x-httpd-php3 .php3
AddType application/x-httpd-php3-source .phps

I added a webpage to document root, with the following, and when I loaded
it into my browser it doesn't show any MySql support/modules/extensions,
and my php interface to Mysql doesn't work.  Mysql normally works fine..
html body
?php
phpinfo();
?
/body/html

Does anyone have a clue about what I'm *TRYING* to convey??
Thanks/Chip Rose


-
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: Normalization sql

2002-10-16 Thread Arthur Fuller

Ooops! You just threw a new wrench into the works! A video may have
multiple titles. In this case you must distinguish the original from its
presumably foreign-translations (or whatever). In other words, you might
store the master as La Cage aux Folles and the English subtitled version
as something else, which implies another 1:M table, residing above Titles in
the hierarchy. For simplicity let's call it Videos, and then rename Titles
to VideoTitles, giving it a foreign key referencing Videos. Thus in the
Videos table we have entry 12345, La Cage Aux Folles and in the
VideoTitles table we have an entry The Cage of Fools or whatever, with an
FK referencing 12345.

A title search would then require interrogation of two tables, which in
itself isn't terrible since one could UNION the titles from both tables, but
possibly this is not the best model. Perhaps the Videos table should contain
no Title info, and all that data should be exported to the Titles table. I'd
have to give that some thought before deciding.

 How do I create a junction table?  Example, between Genres and Titles, how
 do I add the to PK fields to TitleGenres?  Do I just create the
TitleGenres
 table and add the TitleID  GenreID field and does the database know they
 are linked?

The database knows nothing except what is permitted. (Hope Dostoevsky didn't
design the database:-)

You front end application should anticipate this and present pretty controls
for the user. The table TitleGenres implies a reference to both Titles and
Genres, so each of these could be presented as a dropdown list, or in a web
app you could pass in the PK from the Titles table and have your insert code
write the received parameter into the table. (By sticking to Titles rather
than shifting the relationship to Videos, you could account for the strange
belief in France that Jerry Lewis is funny :-)

Creating a junction table is simple. Just add the columns you need and
declare them as foreign keys, specifying their reference-tables (InnoDB). If
you're using MyISAM tables the responsibility falls entirely on your front
end.

You may want to modify the Stars table to reference Videos rather than
Titles, since the stars remain the same even if you translate the film into
Russian or Swahili.

hth,
Arthur

- Original Message -
From: John Chang [EMAIL PROTECTED]
To: Arthur Fuller [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Monday, October 14, 2002 7:26 PM
Subject: Re: Normalization sql



 Studios (StudioName, StudioID)
 Genres (GenreName, GenreID)
 Titles (VideoTitle, Details, StudioID, GenreID, BitRateID, TitleID)
 Actors (F_Name, L_Name, ActorID)
 Stars (TitleID, ActorID)
 TitleGenres (TitleID, GenreID)

 So, if I just use theses tables I will be OK if the video has multiple
 titles, multiple actors,  multiple genres?

 How do I create a junction table?  Example, between Genres and Titles, how
 do I add the to PK fields to TitleGenres?  Do I just create the
TitleGenres
 table and add the TitleID  GenreID field and does the database know they
 are linked?

 Thank you.


 At 09:50 AM 10/14/2002 -0400, Arthur Fuller wrote:
 You're starting off ok, just missing the links between the tables. I
would
 suggest for simplicity though that you change the names of your PKs to
 reflect their table, i.e. Title (VideoTitle, Details, TitleID). Otherwise
 once you do multi-table queries joins you will have to specify the table
 names every time.
 
 A studio makes zero or more titles (videos).
 A film belongs to zero or more genres (your answer may be that a film
 belongs to precisely one genre)
 A title stars one or more actors (you may plan on storing only one, but
how
 will you decide in a case such as Eight Women?) I would say you need a
 junction table between Titles and Actors so you can handle multiple
stars.
 I'm not sure what BitRate means but I guess it is an attribute of the
Title.
 
 Studios (StudioName, StudioID)
 Genres (GenreName, GenreID)
 Titles (VideoTitle, Details, StudioID, GenreID, BitRateID, TitleID)
 Actors (F_Name, L_Name, ActorID)
 Stars (TitleID, ActorID)
 
 If you decide that a Title can belong to more than one Genre, then you
need
 a junction table there too:
 
 TitleGenres (TitleID, GenreID)
 
 This change would involve removing the GenreID from the Titles table.
 
 This design lets you easily find all the titles made by a studio, all the
 titles featuring a given actor (even if she is the co-star rather than
the
 star), all the titles in a genre and even compound queries such as all
the
 MGM thrillers featuring actor XYZ.
 
 hth,
 Arthur
 
 - Original Message -
 From: John Chang [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Monday, October 14, 2002 8:49 AM
 Subject: Normalization sql
 
 
  
   I've read a bunch about normalization in MySQL and still can't do it
very
   well.  What I want to normalize is videos (Title, Studios, Actors,
Genre,
   bitrate).
  
   These are the tables and fields I think it needs.  Is this
   normalized?  Thank 

Re: Problem with UPDATE table ... can u help plz?

2002-10-16 Thread Bruce Lewis

You need to include the field names along with the table name.

UPDATE table1 INNER JOIN Table1 ON Table2.FieldID = Table1.FieldID
Set Table1.Field1=Table2.Field1, Table1.Field2=Table2.Field2, ...


Bruce Lewis


- Original Message -
From: Greg Knaddison [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, October 16, 2002 5:15 PM
Subject: RE: Problem with UPDATE table ... can u help plz?


When I try that modified for my tables that fit this hypothetical, I get:

CREATE TABLE `sales_table` (
  `item_s` varchar(100) default '',
  `price_s` varchar(100) default ''
) TYPE=MyISAM

CREATE TABLE `lookup_table` (
  `item_l` varchar(100) default '',
  `price_l` varchar(100) default ''
) TYPE=MyISAM


mysql UPDATE sales_table SET sales_table.price_s = lookup_table.price_l
INNER JOIN sales_table ON lookup_table.item_l = sales_table.item_s;

[localhost] ERROR 1064: You have an error in your SQL syntax near 'INNER
JOIN sales_table ON lookup_table.item_l = sales_table.item_s' at line 1

The Update Syntax Manual page 6.4.5
http://www.mysql.com/doc/en/UPDATE.html doesn't mention INNER JOIN and the
comments on that page seem to indicate that this is a functionality lacking
in MySQL though the last comment on the page shows a kluge workaround.

Greg


-Original Message-
From: Bruce Lewis [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 16, 2002 4:03 PM
To: STIBS; [EMAIL PROTECTED]
Subject: Re: Problem with UPDATE table ... can u help plz?


You need an InnerJoin to perform the operation similar to:

UPDATE table1 SET table1.field1 = table2.field1, table1.field2 =
table2.field2,...
 INNER JOIN Table1 ON Table2.ID = Table1.ID


Bruce Lewis


- Original Message -
From: STIBS [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, October 16, 2002 4:26 PM
Subject: Problem with UPDATE table ... can u help plz?


Hi from Dresden, Germany!

I have a littlebig problem:

I want to UPDATE table1.fields with data from table2.fields WHERE the id (in
this
case a product number) is the same in both tables.

OK, I did this:

UPDATE table1 SET table1.field1 = table2.field1, table1.field2 =
table2.field2,...
WHERE table1.id = table2.id;

The answer from MySQL is: Unknown table 'table2' in WHERE clause .

Heading to MySQL.com the docs tell me nothing than there is a INSERT ...
SELECT.

In my case this would be an UPDATE ... SELECT coz I don't want a new table,
just
updating records of an existing with data from another.

I'm sure I just miss the right topic to look at. Point me please.

Second try:

I used

UPDATE table1, table2 SET table1.field1 = table2.field1, table1.field2 =
table2.field2,...
WHERE table1.id = table2.id;

It still gives me an error, now  in the SQL Syntax when I set the
table1.field2 value. It doesn't find the second tables name [You have an
error... near ... table(2.field2 should be here)].

Could someone give me the right direction?

TIA!

Michael Stibane (STIBS)
[EMAIL PROTECTED]
Training, Linux, Admin, Programming, Web
http://www.stibs.cc

Escapade Server-Side Scripting Engine Development Team
Pensacola - Dallas - Dresden - London
http://www.escapade.org


-
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




  1   2   >