Re: Can't start MYSQL on Linux

2001-08-07 Thread mike cullerton

on 8/6/01 10:13 PM, Trond Eivind Glomsrød at [EMAIL PROTECTED] wrote:

 Ling Wang [EMAIL PROTECTED] writes:
 
 I have a fresh installed Linux 7.1 from Redhat. The mysal 3.23.36 was
 installed together with the Redhat Linux. I can not start the mysql
 server by executing /usr/bin/safe_mysqld .
 
 You're not supposed to. To start mysql, as any service, do

snip

 What you've done (and too many others, where do they get this idea?)

um, perhaps from the INSTALL-SOURCE notes that come with the mysql
distribution

quote from the aforementioned INSTALL-SOURCE

After everything has been unpacked and installed, you should initialize
and test your distribution.

You can start the *MySQL* server with the following command:

 shell bin/safe_mysqld --user=mysql 

/quote

i believe it's the way most of the world does it.

 is that you've created the database files as root. Then you start the
 database, which will run as mysql. This user can obviously not write
 to root's files. Change the ownership manually, and try again - with
 service mysqld start.


 -- mike cullerton



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

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] Database size

2001-08-07 Thread Grigory Bakunov

Date |Fri, 3 Aug 2001 17:21 +0200
From |TIGNAC BRUNO [EMAIL PROTECTED]

Hello!

TB --- Reçu de   CMB.TIGNABR 0298426574 03-08-01 17.21

TB Hello,

TB I plan to use MySQL/InnoDB to store about 13 GB of data, into 40 tables. One
TB of the tables is over 5 GB, and a second over 1,5 GB. Do you think I can use
TB MySQL/InnoDB ?

In short words: YES.
___
For technical support contracts, visit https://order.mysql.com/
This email is sponsored by SWSoft, http://www.asplinux.ru/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Grigory Bakunov [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB / SWSoft
/_/  /_/\_, /___/\___\_\___/
   ___/   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




Got an error reading communication packets

2001-08-07 Thread DS

Anyone seen this in your log file before?

It's perlscripts on the same host, so before the DBI
routine all the data needed for an insert is on the
machine, not like it's loggin in from another machine.

Could this be a problem with the loop back device? Any
other ideas as to what causes mysql to spit this out?

Thanks
David




010804 20:00:40  mysqld started
/usr/local/mysql/bin/mysqld: ready for connections
010805  4:08:29  Aborted connection 140 to db: 'rose'
user: 'rainman2' host: `localhost' (Got an error
reading
 communication packets)
010805  4:09:48  Aborted connection 166 to db: 'rose'
user: 'rainman2' host: `localhost' (Got an error
reading
 communication packets)



=
http/email [EMAIL PROTECTED]
+380676920324

__
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.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: Got an error reading communication packets

2001-08-07 Thread Colin Faber

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


DS wrote:
 
 Anyone seen this in your log file before?
 
 It's perlscripts on the same host, so before the DBI
 routine all the data needed for an insert is on the
 machine, not like it's loggin in from another machine.
 
 Could this be a problem with the loop back device? Any
 other ideas as to what causes mysql to spit this out?
 
 Thanks
 David
 
 010804 20:00:40  mysqld started
 /usr/local/mysql/bin/mysqld: ready for connections
 010805  4:08:29  Aborted connection 140 to db: 'rose'
 user: 'rainman2' host: `localhost' (Got an error
 reading
  communication packets)
 010805  4:09:48  Aborted connection 166 to db: 'rose'
 user: 'rainman2' host: `localhost' (Got an error
 reading
  communication packets)
 
 =
 http/email [EMAIL PROTECTED]
 +380676920324
 
 __
 Do You Yahoo!?
 Make international calls for as low as $.04/minute with Yahoo! Messenger
 http://phonecard.yahoo.com/
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail [EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

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

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




Build problems (+solution) on HPUX 10.20/gcc 2.95

2001-08-07 Thread verkouter

Description:
I tried to compile the mysql client stuff. 
The first configure command was:
./configure --prefix=/jaw0_3/jops/verkout --without-server --without-docs 
--without-bench --without-debug --with-pthread

This (obviously) did not fully work. Almost everyting was built, except the 
mysql binary (mysql{admin,show,..} were ok (and did work).
When compiling mysql.cc it gave *a lot* of errors, on include stdio.h and 
some other files. Mostly errors on lines wher _fpos_t and/or int64 were used.

Checked www.mysql.com. Found HPUX 10.20 build instructions.
Did another configure (env. vars. changes as per the webpage first).
./configure --prefix=/jaw0_3/jops/verkout --without-server --without-docs 
--without-bench --without-debug --with-pthread --with-named-thread-libs='-ldce' 
--disable-shared

Still didn't work; the errors were still the same... I suspected they had to 
do with large-file support. Gave it another try with this configure command:
./configure --prefix=/jaw0_3/jops/verkout --without-server --without-docs 
--without-bench --without-debug --with-pthread --with-named-thread-libs='-ldce' 
--disable-shared --disable-large-files

You guessed it: no difference.

Fix:

Went into 'include/my_config.h'. Found that the #defn's usually used to 
indicate large-file support were still defined?!
Did a #undef on the following variables:
_FILE_OFFSET_BITS
_LARGEFILE_SOURCE
_LARGE_FILES

After that, gmake in the 'client' subdir worked like a charm! The produced 
binaries seem to work ok.


Originator: Harro Verkouter
MySQL support: none
Synopsis:   Buildprobs on HPUX 10.20
Severity:   non-critical
Priority:   medium
Category:   mysql
Class:  sw-bug
Release:mysql-3.23.40 (Source distribution)

Environment:
System: HP-UX jaw0 B.10.20 A 9000/782 298990 two-user license


Some paths:  /local/bin/perl /local/bin/make /local/bin/gmake /local/gcc-2.95/bin/gcc 
/usr/bin/cc
GCC: Reading specs from /local/gcc-2.95/lib/gcc-lib/hppa2.0-hp-hpux10.20/2.95.2/specs
gcc version 2.95.2 19991024 (release)
Compilation info: CC='gcc'  CFLAGS='-DHPUX -I/opt/dce/include'  CXX='gcc'  
CXXFLAGS='-DHPUX -I/opt/dce/include -felide-constructors -fno-exceptions -fno-rtti'  
LDFLAGS=''
LIBC: 
-r-xr-xr-x   1 binbin1863680 Nov 10  1999 /lib/libc.1
-r--r--r--   1 binbin2456532 Nov 10  1999 /lib/libc.a
lrwxr-xr-x   1 root   sys 15 Jun 16  1998 /lib/libc.sl - 
/usr/lib/libc.1
-r-xr-xr-x   1 binbin1863680 Nov 10  1999 /usr/lib/libc.1
-r--r--r--   1 binbin2456532 Nov 10  1999 /usr/lib/libc.a
lrwxr-xr-x   1 root   sys 15 Jun 16  1998 /usr/lib/libc.sl - 
/usr/lib/libc.1
Configure command: ./configure  --prefix=/jaw0_3/jops/verkout --without-server 
--without-docs --without-bench --without-debug --with-pthread 
--with-named-thread-libs=-ldce --disable-shared
Perl: This is perl, version 5.005_02 built for PA-RISC2.0

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

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




Design Question

2001-08-07 Thread Curtis Spencer

I was wondering what would be a better database design for long term
performance growth.

Design A:
   Data Mapping
Definitions
Three Tables:  Corporation ID  1 -- many   Corporation ID
   Corporation Data Code ID 1 -- 1
Code ID

Code Definition

Each of these corporations has many code definitions and they are
searched by the code definition.

Select Definitions.definition from Data, Mapping, Definitions where
Data.ID = Mapping.ID and Mapping.CodeID = Definitions.CodeID and
Definitions.Definition LIKE %Searchable Definition%;

Hence it looks like three table joins.


Design B:

Because each company has this list of Definitions, would it be better to
put these definitions using a programming language into a TEXT field
called definitions so that one could make a table like this, the TEXT
field would be a comma delimited list of Definitions.

Data
Corporation ID
Corporation Data
Definitions TEXT

And the select would like this:  Select * from data where Definitions
LIKE %Searchable Definition%;

Any ideas.  A company has a maximum of 10-15 definitions usually just
one or two.  I know the table ceases to be relational, but could this
make it faster?

Also, another off topic question.  When I do explain on one of these
selects even with the definitions indexed it says no indices are used.
Does this have to do with the LIKE operator?

Thanks for any help,
Curtis

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

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




unix application to Windows NT

2001-08-07 Thread Nicolas Grehalle

hello,

i must convert a Web application from Unix to Windows NT.

The application is in C (cgi) and uses the library libmysqlclient.a
But this library doesn't exist in the Windows version of MySQL.

Somebody could help me ?

Thank you

N.G.  



RE: INET_ATON

2001-08-07 Thread Basil Hussain

Hi,

 i just tried using INET_ATON() and INET_NTOA() and i keep getting syntax
 errors

snip

 am i missing something easy here? is this a known issue? perhaps a version
 thing? i am running 3.22.32.

Yes, you are missing something. If I may quote from the manual - in section
F.2.20, Changes in release 3.23.15 there is this:

* Added functions INET_NTOA() and INET_ATON().

So, you need to upgrade your MySQL before you can use these functions.

Regards,

Basil Hussain
---
Internet Developer, Kodak Weddings
E-Mail: [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: INET_ATON

2001-08-07 Thread Ian Barwick

Hi

On Tuesday 07 August 2001 07:23, mike cullerton wrote:

 i just tried using INET_ATON() and INET_NTOA() and i keep getting syntax
 errors

  near '(100.100.100.100)' at line 1

 no manner of quoting that i can think of solves this. i tried the examples
 at the bottom of http://www.mysql.com/doc/M/i/Miscellaneous_functions.html
 and they got the same error.

 am i missing something easy here? is this a known issue? perhaps a version
 thing? i am running 3.22.32.

Definitely a version thing, works fine on 3.23.37 (but doesn't on 3.22.32 - I 
just tried ;-)

HTH 

Ian Barwick

--  
Ian Barwick - Developer - [EMAIL PROTECTED]  
akademie.de asp GmbH - http://www.akademie.de  

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

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 w/SSL support howto?..

2001-08-07 Thread louie miranda

Is it possible for mysql 3.23.40 to support SSL.

hm, how?


i guess..

i will download, openssl? first.

then

./configure -- etc
make
make install

then, download the mysql source.

then..

./configure --prefix=/usr/local/mysql --enable-assembler --with-mysqld-ldfla
gs=-all-static --with-ssl=../openssl-ver#
make
make install



am i correct?


or better yet try and download the mysql 4 ?




hehe, hope someone could help me out here..

ty



















louie miranda
---
(axishift.ath.cx) PGPID: 0xDABA60C7





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

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

2001-08-07 Thread Siim Einfeldt aka Itpunk


  I think this is supported from 3.23...not sure though, but might be:-)

 hey folks,

 i just tried using INET_ATON() and INET_NTOA() and i keep getting syntax
 errors

  near '(100.100.100.100)' at line 1

 no manner of quoting that i can think of solves this. i tried the examples
 at the bottom of http://www.mysql.com/doc/M/i/Miscellaneous_functions.html
 and they got the same error.

 am i missing something easy here? is this a known issue? perhaps a version
 thing? i am running 3.22.32.

 thanks,
 mike

  -- mike cullerton



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

 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: MyOdbc to unix

2001-08-07 Thread SRIVATSAN RAGHURAMAN

Hi Venu,
I want some sample codes for ODBC connection to MySQL. Where can I get it?
R.Srivatsan
 [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




SQL question

2001-08-07 Thread Healthwell.com


I have a general how do you do that SQL question.

I have a table with links in it.  One link per row, with URL link name, etc.

The client wants to be able to specify the order in which the links appear.
In other words, they want to set any link to show up first, another other
link to show up second, etc, etc.

I did a rough think like this a while back, by allowing then to set a
precedent field, than the sorted on that field.  The trick is, of course,
if they ad a link and want it to show up in the second slot, then the
precedence filed for records higher then 2 need to be incremented by one,
so the sequence will still be in tack.

I'm thinking there must be a better way to do this, but I don't know what it
is.

Thanks in advance,

Peter Janett

New Media One Web Services

WEB HOSTING FOR WEB DEVELOPERS

Sun, IRIX, Windows 2000, Linux;
PHP, MySQL, Perl, Cold Fusion,
MS SQL, ASP, SSI, SSL
http://www.newmediaone.net
[EMAIL PROTECTED]
(303)828-9882



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

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: Truncated User List

2001-08-07 Thread Steve Wright

I've tried mysqldump, it worked perfectly, my data is now on the new machine.
I did have to alter the output file so the tables in the mysql database where 
recreated without error. 
(eg adding drop table columns_priv; before the CREATE TABLE columns_priv; 
line)
What I want to know now is why didn't just moving the /var/lib/mysql/ 
databases work ?
I was given to understand if I wanted to exactly duplicate all the databases 
on a machine I could just tar them  move them ?
Is this not the case ?

With Thanks
Steve

---
On Tuesday 07 August 2001 06:32, you wrote:
 Date |Mon, 6 Aug 2001 13:51:09 +0100
 From |Steve Wright [EMAIL PROTECTED]

 Hello!


 SW Hi,
 SW Wondering if anyone can here can help,
 SW We've got a small selection of MySQL databases used by our customers
 (for SW websites).
 SW Until now we've used the Debian package of MySQL (latest deb. version),
 SW however the systems are being updated  we're starting to use source
 builds, SW (this is where the problem starts).

 SW I have 3.23.39 built  installed, we installed the old databases on the
 new SW machine by shutting down the sql server  duplicating the
 /var/lib/mysql SW directory structure.
 SW When the users are listed on the new machine however half are missing,
 I am SW very confused as I don't seem to be able to make them reappear !
 SW I have looked in the /var/lib/mysql/mysql/user. files  can see them 
 SW /etc/my.cnf is looking in the right place


 You must use mysqldump utility for data export and then
 import old data to the table.
 It's much clean way.
 http://www.mysql.com/doc/m/y/mysqldump.html

 ___
 For technical support contracts, visit https://order.mysql.com/
 This email is sponsored by SWSoft, http://www.asplinux.ru/
__  ___ ___   __
   /  |/  /_ __/ __/ __ \/ /Grigory Bakunov [EMAIL PROTECTED]
  / /|_/ / // /\ \/ /_/ / /__   MySQL AB / SWSoft
 /_/  /_/\_, /___/\___\_\___/
___/   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: Got an error reading communication packets

2001-08-07 Thread Werner Stuerenburg



Colin Faber schrieb am Dienstag, 7. August 2001, 09:29:45:

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

Very nice hint, indeed, I didn't think of it before, and I
experience these things, too. So I went to it and did a search on

error reading communication packets

which gave me 5 results. Fine.

The first hint I found was

max_allowed_packet

Well, this is taken care of:

set-variable= max_allowed_packet=16M

http://www.mysql.com/documentation/mysql/bychapter/manual_Clients.html

then continues to

The MySQL server shrinks each communication buffer to
net_buffer_length bytes after each query. For clients, the size
of the buffer associated with a connection is not decreased until
the connection is closed, at which time client memory is
reclaimed.

Does this mean that the error signals that buffer has become too
low and will be increased again with each error? Sorry, I don't
get that.

 DS wrote:
 
 Anyone seen this in your log file before?
 
 It's perlscripts on the same host, so before the DBI
 routine all the data needed for an insert is on the
 machine, not like it's loggin in from another machine.
 
 Could this be a problem with the loop back device? Any
 other ideas as to what causes mysql to spit this out?
 
 Thanks
 David
 
 010804 20:00:40  mysqld started
 /usr/local/mysql/bin/mysqld: ready for connections
 010805  4:08:29  Aborted connection 140 to db: 'rose'
 user: 'rainman2' host: `localhost' (Got an error
 reading
  communication packets)
 010805  4:09:48  Aborted connection 166 to db: 'rose'
 user: 'rainman2' host: `localhost' (Got an error
 reading
  communication packets)
 
 =
 http/email [EMAIL PROTECTED]
 +380676920324
 
 __
 Do You Yahoo!?
 Make international calls for as low as $.04/minute with Yahoo! Messenger
 http://phonecard.yahoo.com/
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail [EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

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

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



-- 
Herzlich
Werner Stuerenburg

_
ISIS Verlag, Teut 3, D-32683 Barntrup-Alverdissen
Tel 0(049) 5224-997 407 · Fax 0(049) 5224-997 409
http://pferdezeitung.de



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

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




Tables relationships

2001-08-07 Thread Chris Malloch

Hi folks,

Can someone please point me in the right direction to let me know how to
define a relationship between tables in MySQL eg one-to-many.  I haven't
come across it in the manual yet, but am sure it must be there somewhere.

Many thanks in advance,

Chris Malloch



Re: Localization..

2001-08-07 Thread SDiZ Cheng


- Original Message -
From: Grigory Bakunov [EMAIL PROTECTED]
To: SDiZ Cheng [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 1:16 PM
Subject: Re: Localization..


 Date |Tue, 7 Aug 2001 04:01:17 +0800
 From |SDiZ Cheng [EMAIL PROTECTED]

 Hello!

 SC I have a table which contain data of some different charsets,
 SC some of them are multi-byte character..
 SC They are currently stored in raw, binary format..
 SC In order to make % match those multi-byte characters correctly,
 SC I am planning to convect the table format to correct charset.
 SC However, i cannot find any infomation on how to create a table
 SC with multi-charsets. May anyone give me some hints here?
 Look here:
 http://www.mysql.com/doc/L/o/Localization.html
 And here:
 http://www.mysql.com/doc/M/u/Multi-byte_characters.html


I have read these docs. I can't find any charset option in CREATE TABLE
syntax.


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

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




Timezone problem.

2001-08-07 Thread Peter Zaitsev

Hello mysql,

  It seems like you made an incomportable changes in 3.23.40 without
  taking a time to write a release note :(

  The mysql 3.23.39  used the system timezone by default:

maindb:/spylog/mysql/logs # date
Tue Aug  7 13:31:56 MSD 2001

| transaction_isolation   | READ-COMMITTED 
|  
| |
| timezone| MSD
|  
| |
| tmp_table_size  | 4194304


Therefore MYSQL 3.23.40 does not determinate the timezone correctly:

  |
| transaction_isolation   | READ-COMMITTED 
|  
| |
| timezone| Local time zone must be set--see´Ÿ manual page 
|  
|   |
| tmp_table_size  | 4194304
|  
| |


It uses GMT in this case which could dammage the data (as went in my
case)

The other thing is the manual  does not contains much info about
setting timezone - only option to safe_mysqld which exports TZ
variable, which does not work:

root 19380 1  0 13:43 pts/800:00:00 sh /usr/local/mysql/bin/safe_mysqld 
--mysqld=mysqld --user=mysql --pid-file=/spylog/db/mysqld.pid --timezone=MSD 
--datadir=/spylog/db

It set's the timezone according to required value but date still bad:

| transaction_isolation   | READ-COMMITTED 
|  
| |
| timezone| MSD
|  
| |
| tmp_table_size  | 4194304


mysql select now();
+-+
| now()   |
+-+
| 2001-08-07 09:44:44 |
+-+
1 row in set (0.00 sec)

Therefore date returns correct value.

rat:/spylog/layers # date
Tue Aug  7 13:47:05 MSD 2001
rat:/spylog/layers #


Do you have any ideas about this ?  How I can fix the problem ?






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


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

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




Migrating to MS SQL Server

2001-08-07 Thread Frank Fisher

My company just stole my web server running MySQL.  I will now have to 
host my site on a consolidated server that has MS SQL Server.

How do I migrate?  I think my SQL code will be good except for 
auto_increment, but are there any migration tools?

Frank Fisher


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

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 to get last entry

2001-08-07 Thread Eldon Ziegler

I have a table that includes a device ID (indexed) and the name of the 
device with multiple records ordered over time. How can I retrieve the last 
record for each device ID without retrieving them all to find the most 
recent name?

Eldon Ziegler
ProAtion Systems
[EMAIL PROTECTED]
http://www.proation.com


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

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




Re: MySQL++ API under Mac OS X

2001-08-07 Thread Sinisa Milivojevic

Halim Chtourou writes:
 I was able to compile and install the MySQL++ API on my Mac OS X system, 
 however, whenever I try to run a program linked against the library, I 
 get undefined symbol errors.
 
 dyld: bin/wopsql Undefined symbols:
 __t12basic_string3ZcZt18string_char_traits1ZcZt23__malloc_alloc_template1i0.
 nilRep
 ___iomanip_setw__FR3iosi
 __t23__malloc_alloc_template1i0.__malloc_alloc_oom_handler
 __t24__default_alloc_template2b0i0._S_end_free
 __t24__default_alloc_template2b0i0._S_free_list
 __t24__default_alloc_template2b0i0._S_heap_size
 __t24__default_alloc_template2b0i0._S_start_free
 __t12basic_string3ZcZt18string_char_traits1ZcZt24__default_alloc_template2b0i0.
 nilRep
 
 Seems like a similar problem as described in the post: 
 http://www.geocrawler.com/archives/3/362/1999/5/50/1804413/
 However, the solution in that post does not produce any different 
 results.
 
 This even happens for the MySQL++ example programs.
 
 Anyone have any suggestions? I'd really really like to be able to use 
 this in a project I'm working on, but MySQL++'s lack of portability 
 seems rather insane.  Tons of patching required to just get it working 
 on minor gcc version increments.  Is this inflexibility due to the 
 design of MySQL++, design of GNU's STL, or all both?
 
 -Halim Chtourou
 

Hi!

First of all, every new version of GNU compiler has it's own STL
library and it's own set of quirks !!

MySQL++ can not do anything about it!

You could try uisng GCC 3.0 , for which you will find patch on MySQL++
page. May be 3.0 has  lesser problems in porting.

Regarding the above symbols they look to me like normal STL
symbols. Check out which library you have to add to linker command.

What GNU version did you use anyway ??

-- 
Regards,
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Sinisa Milivojevic [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, FullTime Developer
/_/  /_/\_, /___/\___\_\___/   Larnaca, Cyprus
   ___/   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: Build problems (+solution) on HPUX 10.20/gcc 2.95

2001-08-07 Thread Sinisa Milivojevic

[EMAIL PROTECTED] writes:
 Description:
   I tried to compile the mysql client stuff. 
   The first configure command was:
   ./configure --prefix=/jaw0_3/jops/verkout --without-server --without-docs 
--without-bench --without-debug --with-pthread
 
   This (obviously) did not fully work. Almost everyting was built, except the 
mysql binary (mysql{admin,show,..} were ok (and did work).
   When compiling mysql.cc it gave *a lot* of errors, on include stdio.h and 
some other files. Mostly errors on lines wher _fpos_t and/or int64 were used.

Thanks ...

We shall try to fix our configure script.

-- 
Regards,
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Sinisa Milivojevic [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, FullTime Developer
/_/  /_/\_, /___/\___\_\___/   Larnaca, Cyprus
   ___/   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: Truncated User List

2001-08-07 Thread Steve Wright


I shut the server down but did not flush the tables, presumably that 
shouldn't matter (data saved to disk at server shutdown) ?

Also if I replace the binary files (debian) on the old server with the new 
compile I can restart sql (now source build)  use my databases perfectly, 
its only when I move the databases to a new machine it doesn't work.
Is there more than just the /usr/local/mysql, /var/lib/mysql  /etc/my.cnf 
that needs to be moved ?

(I'm trying flushing the tables then moving the databases now)

Steve
---

On Tuesday 07 August 2001 11:32, you wrote:
 If you want to do that, you have to flush all tables and shut the
 server down, IIUC. Then it should work, I think - and I think we
 did this before, but I am not sure.

 Steve Wright schrieb am Dienstag, 7. August 2001, 10:40:04:
  I've tried mysqldump, it worked perfectly, my data is now on the new
  machine. I did have to alter the output file so the tables in the mysql
  database where recreated without error.
  (eg adding drop table columns_priv; before the CREATE TABLE
  columns_priv; line)
  What I want to know now is why didn't just moving the /var/lib/mysql/
  databases work ?
  I was given to understand if I wanted to exactly duplicate all the
  databases on a machine I could just tar them  move them ?
  Is this not the case ?
 
  With Thanks
  Steve
 
  ---
 
  On Tuesday 07 August 2001 06:32, you wrote:
  Date |Mon, 6 Aug 2001 13:51:09 +0100
  From |Steve Wright [EMAIL PROTECTED]
 
  Hello!
 
 
  SW Hi,
  SW Wondering if anyone can here can help,
  SW We've got a small selection of MySQL databases used by our customers
  (for SW websites).
  SW Until now we've used the Debian package of MySQL (latest deb.
  version), SW however the systems are being updated  we're starting to
  use source builds, SW (this is where the problem starts).
 
  SW I have 3.23.39 built  installed, we installed the old databases on
  the new SW machine by shutting down the sql server  duplicating the
  /var/lib/mysql SW directory structure.
  SW When the users are listed on the new machine however half are
  missing, I am SW very confused as I don't seem to be able to make them
  reappear ! SW I have looked in the /var/lib/mysql/mysql/user. files 
  can see them  SW /etc/my.cnf is looking in the right place
 
 
  You must use mysqldump utility for data export and then
  import old data to the table.
  It's much clean way.
  http://www.mysql.com/doc/m/y/mysqldump.html
 
  ___
  For technical support contracts, visit https://order.mysql.com/
  This email is sponsored by SWSoft, http://www.asplinux.ru/
 __  ___ ___   __
/  |/  /_ __/ __/ __ \/ /Grigory Bakunov [EMAIL PROTECTED]
   / /|_/ / // /\ \/ /_/ / /__   MySQL AB / SWSoft
  /_/  /_/\_, /___/\___\_\___/
 ___/   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


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

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




How to change max column length befor the compilation

2001-08-07 Thread Mikael Lang

Hi
Im trying to convert an oracle database to a mysql database, and have run in
to the problem that oracle alows more signs in some types for some columns
than mysql do, now I heard that it is possible to change the max length
paraeter before compiling the mysql server, do enyone know witch parameter
to change and how to do it?

best regards / mike 

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

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: MyOdbc to unix

2001-08-07 Thread Sinisa Milivojevic

SRIVATSAN RAGHURAMAN writes:
 Hi Venu,
 I want some sample codes for ODBC connection to MySQL. Where can I get it?
 R.Srivatsan
  [EMAIL PROTECTED]


To connect from Unix or from Windows ?? 

-- 
Regards,
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Sinisa Milivojevic [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, FullTime Developer
/_/  /_/\_, /___/\___\_\___/   Larnaca, Cyprus
   ___/   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:SQLException Error Before start of result set

2001-08-07 Thread Mark Matthews

You need to call .next() and check to see that true was returned on your
ResultSet before trying to read any data from it (see the api-docs for
java.sql.ResultSet for more information)

-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




MySql and PHP

2001-08-07 Thread Matt Gaskin

Hi All

Currently I have rented space on a Web Server that has MySql installed and
PHP, They have created a database directory for myself. Do I need to install
Mysql and PHP locally to take advantage of this. If so where do I start. I
have had no experience of the above two products, although I have written a
number of websites in HTML and a number of access databases. We have just
started to get a number of enquiries for databases online and would like to
develope in this area.

Thanks
M


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

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: MyOdbc to unix

2001-08-07 Thread SRIVATSAN RAGHURAMAN

Hi Sinisa,
  Sorry I should have mentioned this earlier. From Windows.
R.Srivatsan
 [EMAIL PROTECTED]
___
Sinisa Milivojevic [EMAIL PROTECTED] Wrote---
SRIVATSAN RAGHURAMAN writes:
 Hi Venu,
 I want some sample codes for ODBC connection to MySQL. Where can I get it?
 R.Srivatsan
  [EMAIL PROTECTED]


To connect from Unix or from Windows ?? 

-- 
Regards,
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Sinisa Milivojevic [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, FullTime Developer
/_/  /_/\_, /___/\___\_\___/   Larnaca, Cyprus
   ___/   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




Some questions About DBMS.

2001-08-07 Thread Heo, Jungsu Mr.

(I'm sorry if my question does not fit to this
mailing list)

Hi~ there.!

Is there A Book about implementing RDBMS?

I just found Database System Implementation
written by Ullman.

looking for another Book if there is.

Monty, What's the Best Resource(helping you) when
you have started making MySQL?

Umm. MySQL AB Has any plan to make MMDB or Embedded DBMS?

(Last month's survey asked us 'bout Embedded DBMS)

Thank you for Avanced Answer!
 

Member OF
http://database.sarang.net
http://www.nnr.or.kr



--MIME Multi-part separator--


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

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[2]: Timezone problem.

2001-08-07 Thread Peter Zaitsev

Hello Sinisa,

Tuesday, August 07, 2001, 4:48:56 PM, you wrote:

1) SUSE. Destributions does not have TZ variable set by default. And
the idea is it worked quite well wothout it with .39
2) The strange  thing is why settng TZ makes mysql to print correct
timezone in variables but still produces the wrong time ?

SM Peter Zaitsev writes:
 Hello mysql,
 
   It seems like you made an incomportable changes in 3.23.40 without
   taking a time to write a release note :(
 
   The mysql 3.23.39  used the system timezone by default:
 
 maindb:/spylog/mysql/logs # date
 Tue Aug  7 13:31:56 MSD 2001
 
 | transaction_isolation   | READ-COMMITTED  
  
|
 | timezone| MSD 
  
|
 | tmp_table_size  | 4194304
 
 
 Therefore MYSQL 3.23.40 does not determinate the timezone correctly:
 
   |
 | transaction_isolation   | READ-COMMITTED  
  
|
 | timezone| Local time zone must be set--see´Ÿ manual page  
  
  |
 | tmp_table_size  | 4194304 
  
|
 
 
 It uses GMT in this case which could dammage the data (as went in my
 case)
 
 The other thing is the manual  does not contains much info about
 setting timezone - only option to safe_mysqld which exports TZ
 variable, which does not work:
 
 root 19380 1  0 13:43 pts/800:00:00 sh /usr/local/mysql/bin/safe_mysqld 
--mysqld=mysqld --user=mysql --pid-file=/spylog/db/mysqld.pid --timezone=MSD 
--datadir=/spylog/db
 
 It set's the timezone according to required value but date still bad:
 
 | transaction_isolation   | READ-COMMITTED  
  
|
 | timezone| MSD 
  
|
 | tmp_table_size  | 4194304
 
 
 mysql select now();
 +-+
 | now()   |
 +-+
 | 2001-08-07 09:44:44 |
 +-+
 1 row in set (0.00 sec)
 
 Therefore date returns correct value.
 
 rat:/spylog/layers # date
 Tue Aug  7 13:47:05 MSD 2001
 rat:/spylog/layers #
 
 
 Do you have any ideas about this ?  How I can fix the problem ?
 
 
 
  Peter  mailto:[EMAIL PROTECTED]

SM Hi Pjotr,

SM I just tested the above, and it worked just fine for me with 4.0.

SM But I have noticed something. If I mess up my shell, it will mess up
SM all programs started from it, including MySQL. We can not do anything
SM about it ...

SM If a shell that starts up MySQL does not have TZ set properly then
SM there is not much we can do about it ...




-- 
Best regards,
 Petermailto:[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: Sub select.

2001-08-07 Thread Anders Alstrin

Den 01-08-07 14.57, skrev Anders Alstrin [EMAIL PROTECTED]:

 Does anyone know how to do this sub select in MySQL.
 I know how to do it in Oracle!
 
 table media
 +--+---+--+
 | media_id | price |filename  |
 +--+---+--+
 |3 | 0 | cal.jpg  |
 |   82 | 0 | Soa.jpg  |
 |   13 | 0 | ca.jpg   |
 |   71 | 0 | gt.pdf   |
 |   67 | 0 | low.pdf  |
 |   68 | 0 | 10.pdf   |
 |   83 | 0 | B5.pdf   |
 +--+---+--+
 
 table category_locks
 +--+-+--+
 | category_lock_id | category_id | media_id |
 +--+-+--+
 |   92 |   0 |   68 |
 |   93 |   0 |   67 |
 |   94 |   0 |   13 |
 |   91 |   0 |   71 |
 |   90 |   0 |3 |
 |  118 |  43 |   82 |
 |  121 |  43 |   83 |
 +--+-+--+
 
 table categories
 +-+-++---+--+
 | category_id | category_up | upload | dynamic_media | name |
 +-+-++---+--+
 |  43 |   0 | false  | true  | web  |
 |  0  |   0 | false  | false | trine|
 |  0  |   0 | false  | false | shop |
 +-+-++---+--+
 
 A Oracle way to do it:
 
 SELECT * FROM media
 WHERE media_id = (SELECT media_id FROM category_locks
 WHERE category_id = (SELECT category_id FROM categories
 WHERE dynamic_media = 'true'))
 
 A MySQL way to do it?
 
 
 -
 Before posting, please check:
  http://www.mysql.com/manual.php   (the manual)
  http://lists.mysql.com/   (the list archive)
 
 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail
 [EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
 
 

Sorry! I figure it out by my self.

SELECT media.media_id,media.filename
FROM media,category_locks
LEFT JOIN categories ON (media.media_id=category_locks.media_id)
WHERE categories.dynamic_media = 'true'
AND category_locks.category_id != '0';

/Anders


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

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




need one help

2001-08-07 Thread Priti Kaviraj

Is it possible to open two recordsets for the same table without closing the
first one?
With Regards
Priti



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

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




Timezone problem.

2001-08-07 Thread Michael Widenius

Hi!

 "Peter" == Peter Zaitsev [EMAIL PROTECTED] writes:

Peter Hello mysql,
Peter   It seems like you made an incomportable changes in 3.23.40 without
Peter   taking a time to write a release note :(

Peter   The mysql 3.23.39  used the system timezone by default:

Peter maindb:/spylog/mysql/logs # date
Peter Tue Aug  7 13:31:56 MSD 2001

Peter | transaction_isolation   | READ-COMMITTED  
   
   |
Peter | timezone| MSD 
   
   |
Peter | tmp_table_size  | 4194304


Peter Therefore MYSQL 3.23.40 does not determinate the timezone correctly:

Peter   |
Peter | transaction_isolation   | READ-COMMITTED  
   
   |
Peter | timezone| Local time zone must be set--see´Ÿ manual 
page   
   |
Peter | tmp_table_size  | 4194304 
   
   |
Are you sure you are not starting mysqld differently ?

According to my knowing, we have not changed anything in timezone
usage in MySQL.

The name if the timezone mysqld displays is what we get from the
following call:

  {
struct tm tm_tmp;
localtime_r(start_time,tm_tmp);
strmov(time_zone,tzname[tm_tmp.tm_isdst == 1 ? 1 : 0]);
  }

I don't know why localtime_r() doesn't work in your case, but I would guess
something in your setup that has changed.

The only way to affect the timezone is to set the TZ variable before
starting mysqld/safe_mysqld or by starting safe_mysqld with the
--timezone= option.

Peter It uses GMT in this case which could dammage the data (as went in my
Peter case)

Peter The other thing is the manual  does not contains much info about
Peter setting timezone - only option to safe_mysqld which exports TZ
Peter variable, which does not work:

Peter root 19380 1  0 13:43 pts/800:00:00 sh 
/usr/local/mysql/bin/safe_mysqld --mysqld=mysqld --user=mysql 
--pid-file=/spylog/db/mysqld.pid --timezone=MSD --datadir=/spylog/db

Peter It set's the timezone according to required value but date still bad:

Peter | transaction_isolation   | READ-COMMITTED  
   
   |
Peter | timezone| MSD 
   
   |
Peter | tmp_table_size  | 4194304


mysql select now();
Peter +-+
Peter | now()   |
Peter +-+
Peter | 2001-08-07 09:44:44 |
Peter +-+
Peter 1 row in set (0.00 sec)

Peter Therefore date returns correct value.

Peter rat:/spylog/layers # date
Peter Tue Aug  7 13:47:05 MSD 2001
Peter rat:/spylog/layers #

Peter Do you have any ideas about this ?  How I can fix the problem ?

Sorry, no ideas;  It looks like there is some problem with your glibc
library.

Did you try the MySQL 3.23.39 and 3.23.40 binaries on the same
machine?
If not, then I think this is a glibc problem!

Regards,
Monty

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

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: Sub select.

2001-08-07 Thread Tyler Longren

I don't think MySQL supports sub selects.

Tyler


On Tue, 07 Aug 2001 14:57:33 +0200
Anders Alstrin [EMAIL PROTECTED] wrote:

 Does anyone know how to do this sub select in MySQL.
 I know how to do it in Oracle!
 
 table media
 +--+---+--+
 | media_id | price |filename  |
 +--+---+--+
 |3 | 0 | cal.jpg  |
 |   82 | 0 | Soa.jpg  |
 |   13 | 0 | ca.jpg   |
 |   71 | 0 | gt.pdf   |
 |   67 | 0 | low.pdf  |
 |   68 | 0 | 10.pdf   |
 |   83 | 0 | B5.pdf   |
 +--+---+--+
 
 table category_locks
 +--+-+--+
 | category_lock_id | category_id | media_id |
 +--+-+--+
 |   92 |   0 |   68 |
 |   93 |   0 |   67 |
 |   94 |   0 |   13 |
 |   91 |   0 |   71 |
 |   90 |   0 |3 |
 |  118 |  43 |   82 |
 |  121 |  43 |   83 |
 +--+-+--+
 
 table categories
 +-+-++---+--+
 | category_id | category_up | upload | dynamic_media | name |
 +-+-++---+--+
 |  43 |   0 | false  | true  | web  |
 |  0  |   0 | false  | false | trine|
 |  0  |   0 | false  | false | shop |
 +-+-++---+--+
 
 A Oracle way to do it:
 
 SELECT * FROM media
 WHERE media_id = (SELECT media_id FROM category_locks
 WHERE category_id = (SELECT category_id FROM categories
 WHERE dynamic_media = 'true'))
 
 A MySQL way to do it?
 
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail
 [EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
 

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

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




Re: Re[2]: Timezone problem.

2001-08-07 Thread Sinisa Milivojevic

Peter Zaitsev writes:
 Hello Sinisa,
 
 Tuesday, August 07, 2001, 4:48:56 PM, you wrote:
 
 1) SUSE. Destributions does not have TZ variable set by default. And
 the idea is it worked quite well wothout it with .39
 2) The strange  thing is why settng TZ makes mysql to print correct
 timezone in variables but still produces the wrong time ?
 
 
 -- 
 Best regards,
  Petermailto:[EMAIL PROTECTED]

Hello Pjotr,

We did not changed it recently. If you take a look at Changelog, you
will see that nothing like that was introduced. 

mysqld.cc has the following code at the beginning :

tzset(); 

and that is all.

Regarding a strange thing when you set TZ that it changes time, this
is /bin/sh doing by help of kernel, of course.

Check it out. Change TZ and watch your time change. 


We truly can't do anything about it. We must use OS C API functions
for such things. Anyway, all those functions we use are POSIX compliant.


-- 
Regards,
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Sinisa Milivojevic [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, FullTime Developer
/_/  /_/\_, /___/\___\_\___/   Larnaca, Cyprus
   ___/   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: C API Compile Error

2001-08-07 Thread Rob Doornbos

Good Morning -

Thank you so much, your suggestion worked perfectly!

Best Regards,
  Rob

--- Grigory Bakunov [EMAIL PROTECTED] wrote:
 Date |Mon, 6 Aug 2001 14:46:13 -0700 (PDT)
 From |Rob Doornbos [EMAIL PROTECTED]
 
 Hello!
 
 RD Good Afternoon -
 
 RD I receive the following error when attempting to
 RD compile an application to use the C API.
 
 RD gcc -oclient1 client1.c
 -I/usr/local/mysql/include
 RD -L/usr/local/mysql/lib -lmysqlclient
 
 RD

/usr/local/mysql/lib/libmysqlclient.a(my_compress.o):
 RD In function `my_uncompress':
 RD my_compress.o(.text+0x9a): undefined reference
 to
 RD `uncompress'
 
 RD

/usr/local/mysql/lib/libmysqlclient.a(my_compress.o):
 RD In function `my_compress_alloc':
 RD my_compress.o(.text+0x12a): undefined reference
 to
 RD `compress'
 RD collect2: ld returned 1 exit status
 
 RD Any ideas would be much appreciated.
 
 RD Best Regards,
 RD Rob
 Try to add -lz to gcc command line,
 gcc -oclient1 client1.c -I/usr/local/mysql/include
 -L/usr/local/mysql/lib -lmysqlclient -lz
 

___
Truly yours,
 Grigory Bakunov
  
 ASPLinux Support Team
 
http://www.asplinux.ru


=
~~
Robert A. Doornbos, Jr.
Leader, Forecast Systems Group
WeatherNews, Inc. (USA)
[EMAIL PROTECTED](530) 893-0308
~~

__
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.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: MySql and PHP

2001-08-07 Thread Tyler Longren

No need to install locally.  You could write everything locally, upload it
to the server, and see if what you wrote works.

Tyler


On Tue, 7 Aug 2001 13:51:01 +0100
Matt Gaskin [EMAIL PROTECTED] wrote:

 Hi All
 
 Currently I have rented space on a Web Server that has MySql installed
 and
 PHP, They have created a database directory for myself. Do I need to
 install
 Mysql and PHP locally to take advantage of this. If so where do I start.
 I
 have had no experience of the above two products, although I have
 written a
 number of websites in HTML and a number of access databases. We have
 just
 started to get a number of enquiries for databases online and would like
 to
 develope in this area.
 
 Thanks
 M
 
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 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




Remote MySQL Console?

2001-08-07 Thread Chris

Is there a method I can use to log into a remote mysql server through something such 
as telnet to pass queries on my database?



Re: SELECT to get last entry

2001-08-07 Thread Tonu Samuel

On 07 Aug 2001 07:24:59 -0400, Eldon Ziegler wrote:
 I have a table that includes a device ID (indexed) and the name of the 
 device with multiple records ordered over time. How can I retrieve the last 
 record for each device ID without retrieving them all to find the most 
 recent name?

I believe your answer is in using GROUP BY clause together with MAX()
function. Other choise is to have separate tables for all device ID-s
and join them using MERGE table type.

-- 
For technical support contracts, goto https://order.mysql.com/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Tonu Samuel [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, Security Administrator
/_/  /_/\_, /___/\___\_\___/   Hong Kong, China
   ___/   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: Timezone problem.

2001-08-07 Thread Sinisa Milivojevic

Peter Zaitsev writes:
 Hello mysql,
 
   It seems like you made an incomportable changes in 3.23.40 without
   taking a time to write a release note :(
 
   The mysql 3.23.39  used the system timezone by default:
 
 maindb:/spylog/mysql/logs # date
 Tue Aug  7 13:31:56 MSD 2001
 
 | transaction_isolation   | READ-COMMITTED   
  
   |
 | timezone| MSD  
  
   |
 | tmp_table_size  | 4194304
 
 
 Therefore MYSQL 3.23.40 does not determinate the timezone correctly:
 
   |
 | transaction_isolation   | READ-COMMITTED   
  
   |
 | timezone| Local time zone must be set--see´Ÿ manual page   
  
 |
 | tmp_table_size  | 4194304  
  
   |
 
 
 It uses GMT in this case which could dammage the data (as went in my
 case)
 
 The other thing is the manual  does not contains much info about
 setting timezone - only option to safe_mysqld which exports TZ
 variable, which does not work:
 
 root 19380 1  0 13:43 pts/800:00:00 sh /usr/local/mysql/bin/safe_mysqld 
--mysqld=mysqld --user=mysql --pid-file=/spylog/db/mysqld.pid --timezone=MSD 
--datadir=/spylog/db
 
 It set's the timezone according to required value but date still bad:
 
 | transaction_isolation   | READ-COMMITTED   
  
   |
 | timezone| MSD  
  
   |
 | tmp_table_size  | 4194304
 
 
 mysql select now();
 +-+
 | now()   |
 +-+
 | 2001-08-07 09:44:44 |
 +-+
 1 row in set (0.00 sec)
 
 Therefore date returns correct value.
 
 rat:/spylog/layers # date
 Tue Aug  7 13:47:05 MSD 2001
 rat:/spylog/layers #
 
 
 Do you have any ideas about this ?  How I can fix the problem ?
 
 
 
  Peter  mailto:[EMAIL PROTECTED]

Hi Pjotr,

I just tested the above, and it worked just fine for me with 4.0.

But I have noticed something. If I mess up my shell, it will mess up
all programs started from it, including MySQL. We can not do anything
about it ...

If a shell that starts up MySQL does not have TZ set properly then
there is not much we can do about it ...

-- 
Regards,
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Sinisa Milivojevic [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, FullTime Developer
/_/  /_/\_, /___/\___\_\___/   Larnaca, Cyprus
   ___/   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: Sub select.

2001-08-07 Thread Remco Brood

you can rewrite this query to simple joins so you dont use sub selects.

select media.media_id , media.price, media.filename
from media,category_locks,categories
where media.media_id = category_locks.media_id
and category_locks.category_id = categories.category_id
and categories.dynamic_media = 'true'

-Original Message-
From: Anders Alstrin [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, August 07, 2001 2:58 PM
To: [EMAIL PROTECTED]
Subject: Sub select.


Does anyone know how to do this sub select in MySQL.
I know how to do it in Oracle!

table media
+--+---+--+
| media_id | price |filename  |
+--+---+--+
|3 | 0 | cal.jpg  |
|   82 | 0 | Soa.jpg  |
|   13 | 0 | ca.jpg   |
|   71 | 0 | gt.pdf   |
|   67 | 0 | low.pdf  |
|   68 | 0 | 10.pdf   |
|   83 | 0 | B5.pdf   |
+--+---+--+

table category_locks
+--+-+--+
| category_lock_id | category_id | media_id |
+--+-+--+
|   92 |   0 |   68 |
|   93 |   0 |   67 |
|   94 |   0 |   13 |
|   91 |   0 |   71 |
|   90 |   0 |3 |
|  118 |  43 |   82 |
|  121 |  43 |   83 |
+--+-+--+

table categories
+-+-++---+--+
| category_id | category_up | upload | dynamic_media | name |
+-+-++---+--+
|  43 |   0 | false  | true  | web  |
|  0  |   0 | false  | false | trine|
|  0  |   0 | false  | false | shop |
+-+-++---+--+

A Oracle way to do it:

SELECT * FROM media
WHERE media_id = (SELECT media_id FROM category_locks
WHERE category_id = (SELECT category_id FROM categories
WHERE dynamic_media = 'true'))

A MySQL way to do it?


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

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


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

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




Re: MySql and PHP

2001-08-07 Thread Gerald Jensen

Matt:

MySQL and PHP are both 'server-side' components, so there is no need to
instal them locally (unless, of course, you want to do your development and
testing off-line).

If you are doing any significant level of PHP work, I would suggest
installing a local version of both MySQL and PHP. I have local versions
installed on both WinNT and Linux machines on the network ... everything
gets tested on both platforms before it goes live.

Gerald Jensen

- Original Message -
From: Matt Gaskin [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 7:51 AM
Subject: MySql and PHP


 Hi All

 Currently I have rented space on a Web Server that has MySql installed and
 PHP, They have created a database directory for myself. Do I need to
install
 Mysql and PHP locally to take advantage of this. If so where do I start. I
 have had no experience of the above two products, although I have written
a
 number of websites in HTML and a number of access databases. We have just
 started to get a number of enquiries for databases online and would like
to
 develope in this area.

 Thanks
 M


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

 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: Timezone problem.

2001-08-07 Thread Peter Zaitsev

Hello Michael,

Tuesday, August 07, 2001, 10:20:18 PM, you wrote:

OK guys I think I've found the problem.
It seems like new innodb version (40b) does something bad with time.

I've tested 3 binaries

1) Plain .40 with  normal GLIBC - OK
2) Plain .40 with patched GLIBC - OK
3) Plain .40 with new INNODB with doublewrite - This binary shiftes
the time.

Could you Heikke please check if you have something similar ?




MW Hi!

 Peter == Peter Zaitsev [EMAIL PROTECTED] writes:

Peter Hello mysql,
Peter   It seems like you made an incomportable changes in 3.23.40 without
Peter   taking a time to write a release note :(

Peter   The mysql 3.23.39  used the system timezone by default:

Peter maindb:/spylog/mysql/logs # date
Peter Tue Aug  7 13:31:56 MSD 2001

Peter | transaction_isolation   | READ-COMMITTED 
   
|
Peter | timezone| MSD
   
|
Peter | tmp_table_size  | 4194304


Peter Therefore MYSQL 3.23.40 does not determinate the timezone correctly:

Peter   |
Peter | transaction_isolation   | READ-COMMITTED 
   
|
Peter | timezone| Local time zone must be set--see´Ÿ manual 
page   
   |
Peter | tmp_table_size  | 4194304
   
|
MW Are you sure you are not starting mysqld differently ?

MW According to my knowing, we have not changed anything in timezone
MW usage in MySQL.

MW The name if the timezone mysqld displays is what we get from the
MW following call:

MW   {
MW struct tm tm_tmp;
MW localtime_r(start_time,tm_tmp);
MW strmov(time_zone,tzname[tm_tmp.tm_isdst == 1 ? 1 : 0]);
MW   }

MW I don't know why localtime_r() doesn't work in your case, but I would guess
MW something in your setup that has changed.

MW The only way to affect the timezone is to set the TZ variable before
MW starting mysqld/safe_mysqld or by starting safe_mysqld with the
MW --timezone= option.

Peter It uses GMT in this case which could dammage the data (as went in my
Peter case)

Peter The other thing is the manual  does not contains much info about
Peter setting timezone - only option to safe_mysqld which exports TZ
Peter variable, which does not work:

Peter root 19380 1  0 13:43 pts/800:00:00 sh 
/usr/local/mysql/bin/safe_mysqld --mysqld=mysqld --user=mysql 
--pid-file=/spylog/db/mysqld.pid --timezone=MSD --datadir=/spylog/db

Peter It set's the timezone according to required value but date still bad:

Peter | transaction_isolation   | READ-COMMITTED 
   
|
Peter | timezone| MSD
   
|
Peter | tmp_table_size  | 4194304


mysql select now();
Peter +-+
Peter | now()   |
Peter +-+
Peter | 2001-08-07 09:44:44 |
Peter +-+
Peter 1 row in set (0.00 sec)

Peter Therefore date returns correct value.

Peter rat:/spylog/layers # date
Peter Tue Aug  7 13:47:05 MSD 2001
Peter rat:/spylog/layers #

Peter Do you have any ideas about this ?  How I can fix the problem ?

MW Sorry, no ideas;  It looks like there is some problem with your glibc
MW library.

MW Did you try the MySQL 3.23.39 and 3.23.40 binaries on the same
MW machine?
MW If not, then I think this is a glibc problem!

MW Regards,
MW Monty



-- 
Best regards,
 Petermailto:[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




mysql+gemini compile errors

2001-08-07 Thread Brian P. Millett

Hello,
SunOS shaka 5.8 Generic_108529-08 i86pc i386 i86pc
gcc version 2.95.3 20010315 (release)

I'm trying to compile mysql+gemini-3.23.39 on a x86 Solaris 8 box.
I get the following error which has me completly confussed:

ctstset: Compile tstset.cc -- tstset.[c|s] -- tstset.o
Assembler:
tstset.s, line 43 : Illegal mnemonic
tstset.s, line 43 : Syntax error
tstset.s, line 43 : Illegal mnemonic
tstset.s, line 44 : Illegal mnemonic
tstset.s, line 44 : Syntax error
tstset.s, line 45 : Illegal mnemonic
tstset.s, line 45 : Syntax error
tstset.s, line 45 : Illegal mnemonic
tstset.s, line 47 : Illegal mnemonic
tstset.s, line 47 : Syntax error
tstset.s, line 47 : Illegal register: o0
tstset.s, line 47 : Illegal register: o1
tstset.s, line 47 : Illegal mnemonic
tstset.s, line 47 : Illegal mnemonic
tstset.s, line 48 : Syntax error
tstset.s, line 48 : Illegal mnemonic
tstset.s, line 48 : Illegal mnemonic
tstset.s, line 48 : Illegal mnemonic
tstset.s, line 48 : Illegal register: o0
tstset.s, line 48 : Illegal register: o1
tstset.s, line 49 : Syntax error
tstset.s, line 49 : Illegal mnemonic
tstset.s, line 49 : Illegal mnemonic
tstset.s, line 49 : Illegal register: o0
tstset.s, line 50 : Illegal mnemonic
tstset.s, line 50 : Syntax error
tstset.s, line 50 : Illegal register: o1
tstset.s, line 50 : Illegal mnemonic
tstset.s, line 50 : Illegal mnemonic
tstset.s, line 50 : Illegal mnemonic
tstset.s, line 50 : Illegal mnemonic
Too many errors - Goodbye
-rw-r--r--   1 bpm  develop 2252 Jul 16 17:53 tstset.c
-rwxr-xr-x   1 bpm  develop32426 Jul 16 18:00 tstset.cc
-rw-r--r--   1 bpm  develop  897 Aug  1 14:53 tstset.s
rm -f libdb.a
ar cru libdb.a bkcheck.o bkcrashtest.o bkio.o bkiolk.o bkiotop.o bklog.o
bkopen.o bkrec.o bkrepl.o bksubs.o bmapw.o bmbuf.o cx.o cxaux.o
cxblock.o cxcompact.o cxdo.o cxfil.o cxgen.o cxkill.o cxky.o cxkyut.o
cxmove.o cxnxt.o cxtag.o cxundo.o cxvsi.o db.o dbarea.o dbblob.o
dbclose.o dbindex.o dblang.o dblksch.o dbobject.o dbopen.o dbquiet.o
dbrecord.o dbtable.o dbuser.o dbwdog.o geminifromkey.o geminikey.o
keysvc.o keyut.o ky.o kyut.o latctl.o lkmu.o lkrecd.o om.o omundo.o
rec.o recformt.o recget.o recput.o rlai.o rlaiovl.o rlaoff.o rlcl.o
rlmem.o rlnote.o rlrej.o rlrw.o rlset.o rltl.o rm.o rmdoundo.o semadm.o
semmgr.o seqdundo.o seqgen.o shm.o shmatt.o shmcr.o shmdel.o shmpid.o
shmptoq.o shmsiz.o stm.o tm.o tmdoundo.o tstset.o
ar: cannot open tstset.o
No such file or directory
ar: tstset.o not found
gmake[4]: *** [libdb.a] Error 1
gmake[4]: Leaving directory `/opt/src/mysql+gemini-3.23.39/gemini/db'
gmake[3]: *** [all-recursive] Error 1
gmake[3]: Leaving directory `/opt/src/mysql+gemini-3.23.39/gemini'
gmake[2]: *** [all-recursive-am] Error 2
gmake[2]: Leaving directory `/opt/src/mysql+gemini-3.23.39/gemini'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/opt/src/mysql+gemini-3.23.39'
gmake: *** [all-recursive-am] Error 2
shaka:


--
Brian Millett
Enterprise Consulting Group Shifts in paradigms
(314) 205-9030 often cause nose bleeds.
[EMAIL PROTECTED]   Greg Glenn

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

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: Some questions About DBMS.

2001-08-07 Thread Tonu Samuel

On 07 Aug 2001 22:18:04 +0900, Heo, Jungsu Mr. wrote:

 
 Umm. MySQL AB Has any plan to make MMDB or Embedded DBMS?
 
 (Last month's survey asked us 'bout Embedded DBMS)

Yes we are working hard to get embedded MySQL version possible in MysQL
4.0. This should make life easier for many software providers and also
embedded version should be faster because missing communication
overhead.

-- 
For technical support contracts, goto https://order.mysql.com/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Tonu Samuel [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, Security Administrator
/_/  /_/\_, /___/\___\_\___/   Hong Kong, China
   ___/   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: Sub select.

2001-08-07 Thread Trond Eivind Glomsrød

Anders Alstrin [EMAIL PROTECTED] writes:

 Does anyone know how to do this sub select in MySQL.

MySQL doesn't have subselects. Some workarounds can be found at 

http://www.mysql.com/documentation/mysql/bychapter/manual_Introduction.html#Missing_Sub-selects

PostgreSQL supports them.

-- 
Trond Eivind Glomsrød
Red Hat, Inc.

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

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




Re: Sub select.

2001-08-07 Thread Tonu Samuel

On 07 Aug 2001 14:57:33 +0200, Anders Alstrin wrote:

 SELECT * FROM media
 WHERE media_id = (SELECT media_id FROM category_locks
 WHERE category_id = (SELECT category_id FROM categories
 WHERE dynamic_media = 'true'))
 
 A MySQL way to do it?

Something like that should work:

SELECT * FROM media 
LEFT JOIN category_locks USING (media_id)
LEFT JOIN category_id ON (media.category_id=categories.category_id)
WHERE dynamic_media = 'true'

(never tested as I do not have your tables handy)

-- 
For technical support contracts, goto https://order.mysql.com/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Tonu Samuel [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, Security Administrator
/_/  /_/\_, /___/\___\_\___/   Hong Kong, China
   ___/   www.mysql.co


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

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: Timezone problem.

2001-08-07 Thread Heikki Tuuri

Hi!

No idea what is wrong. Below is the code which
prints the timestamp in InnoDB:
.

  struct tm  cal_tm;
  struct tm* cal_tm_ptr;
  time_t tm;

  time(tm);

#ifdef HAVE_LOCALTIME_R
  localtime_r(tm, cal_tm);
  cal_tm_ptr = cal_tm;
#else
  cal_tm_ptr = localtime(tm);
#endif

  fprintf(file,%02d%02d%02d %2d:%02d:%02d,
  cal_tm_ptr-tm_year % 100,
  cal_tm_ptr-tm_mon+1,
  cal_tm_ptr-tm_mday,
  cal_tm_ptr-tm_hour,
  cal_tm_ptr-tm_min,
  cal_tm_ptr-tm_sec);
...
I tested 3.23.40b on our Linux computer and got the following:

heikki@donna:~/mysql-3.23.40/sql  mysqld
010807 18:01:01  Warning: setrlimit couldn't increase number of open files
to mo
re than 1024
010807 18:01:01  Warning: Changed limits: max_connections: 250  table_cache:
382
010807 18:01:02  InnoDB: Started
010807 18:01:02  mysqld: Table 'mysql.func' doesn't exist
010807 18:01:02  Can't open mysql/func table
mysqld: ready for connections


mysql select now();
+-+
| now()   |
+-+
| 2001-08-07 18:03:24 |
+-+
1 row in set (0.00 sec)

mysql
..

Any ideas anybody?

Regards,

Heikki

-Original Message-
From: Peter Zaitsev [EMAIL PROTECTED]
To: Michael Widenius [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED] [EMAIL PROTECTED]; [EMAIL PROTECTED]
[EMAIL PROTECTED]; [EMAIL PROTECTED] [EMAIL PROTECTED]
Date: Tuesday, August 07, 2001 5:41 PM
Subject: Re: Timezone problem.


Hello Michael,

Tuesday, August 07, 2001, 10:20:18 PM, you wrote:

OK guys I think I've found the problem.
It seems like new innodb version (40b) does something bad with time.

I've tested 3 binaries

1) Plain .40 with  normal GLIBC - OK
2) Plain .40 with patched GLIBC - OK
3) Plain .40 with new INNODB with doublewrite - This binary shiftes
the time.

Could you Heikke please check if you have something similar ?




MW Hi!

 Peter == Peter Zaitsev [EMAIL PROTECTED] writes:

Peter Hello mysql,
Peter   It seems like you made an incomportable changes in 3.23.40
without
Peter   taking a time to write a release note :(

Peter   The mysql 3.23.39  used the system timezone by default:

Peter maindb:/spylog/mysql/logs # date
Peter Tue Aug  7 13:31:56 MSD 2001

Peter | transaction_isolation   | READ-COMMITTED
|
Peter | timezone| MSD
|
Peter | tmp_table_size  | 4194304


Peter Therefore MYSQL 3.23.40 does not determinate the timezone
correctly:

Peter   |
Peter | transaction_isolation   | READ-COMMITTED
|
Peter | timezone| Local time zone must be
set--see´Ÿ manual page
|
Peter | tmp_table_size  | 4194304
|
MW Are you sure you are not starting mysqld differently ?

MW According to my knowing, we have not changed anything in timezone
MW usage in MySQL.

MW The name if the timezone mysqld displays is what we get from the
MW following call:

MW   {
MW struct tm tm_tmp;
MW localtime_r(start_time,tm_tmp);
MW strmov(time_zone,tzname[tm_tmp.tm_isdst == 1 ? 1 : 0]);
MW   }

MW I don't know why localtime_r() doesn't work in your case, but I would
guess
MW something in your setup that has changed.

MW The only way to affect the timezone is to set the TZ variable before
MW starting mysqld/safe_mysqld or by starting safe_mysqld with the
MW --timezone= option.

Peter It uses GMT in this case which could dammage the data (as went in
my
Peter case)

Peter The other thing is the manual  does not contains much info about
Peter setting timezone - only option to safe_mysqld which exports TZ
Peter variable, which does not work:

Peter root 19380 1  0 13:43 pts/800:00:00 sh
/usr/local/mysql/bin/safe_mysqld --mysqld=mysqld --user=mysql --pid-file=/sp
ylog/db/mysqld.pid --timezone=MSD --datadir=/spylog/db

Peter It set's the timezone according to required value but date still
bad:

Peter | transaction_isolation   | READ-COMMITTED
|
Peter | timezone| MSD
|
Peter | tmp_table_size  | 4194304


mysql select now();
Peter +-+
Peter | now()   |
Peter +-+
Peter | 2001-08-07 09:44:44 |
Peter +-+
Peter 1 row in set (0.00 sec)

Peter Therefore date returns correct value.

Peter rat:/spylog/layers # date
Peter Tue Aug  7 13:47:05 MSD 2001
Peter rat:/spylog/layers #

Peter Do you have any ideas about this ?  How I can fix the problem ?

MW Sorry, no ideas;  It looks like there is some problem with your glibc
MW library.

MW Did you try the MySQL 3.23.39 and 3.23.40 binaries on the same
MW machine?
MW If not, then I think this is a glibc problem!

MW Regards,
MW Monty



--
Best regards,
 Petermailto:[EMAIL PROTECTED]


-
Before posting, please check:
   

Re: SQL question

2001-08-07 Thread Dave Rigby

Hi,

Could you create a linked list of the links- i.e. have a 'Next' field,
which contains the ID of the next URL in order. You will also need a
field to store if the link is the first (i.e. root) of the list. Then
you can just iterate though the rows, using the next field to tell you
which URL is next. To add or delete will only require one or two changes

It might be a bit overkill if the list of URLs is quite small, but it
will scale up to any size

Regards

Dave Rigby

On 07 Aug 2001 02:35:26 -0600, Healthwell.com wrote:
 
 I have a general how do you do that SQL question.
 
 I have a table with links in it.  One link per row, with URL link name, etc.
 
 The client wants to be able to specify the order in which the links appear.
 In other words, they want to set any link to show up first, another other
 link to show up second, etc, etc.
 
 I did a rough think like this a while back, by allowing then to set a
 precedent field, than the sorted on that field.  The trick is, of course,
 if they ad a link and want it to show up in the second slot, then the
 precedence filed for records higher then 2 need to be incremented by one,
 so the sequence will still be in tack.
 
 I'm thinking there must be a better way to do this, but I don't know what it
 is.
 
 Thanks in advance,
 
 Peter Janett
 
 New Media One Web Services
 
 WEB HOSTING FOR WEB DEVELOPERS
 
 Sun, IRIX, Windows 2000, Linux;
 PHP, MySQL, Perl, Cold Fusion,
 MS SQL, ASP, SSI, SSL
 http://www.newmediaone.net
 [EMAIL PROTECTED]
 (303)828-9882
 
 
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail [EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
 
-- 
Dave Rigby

Opal Telecom

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

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




importing data

2001-08-07 Thread Kevin Fonner

Is there an easy way or perhaps a utility to import a tab delimeted text 
file of data into a mysql table

Thanks,

-- 
Kevin Fonner



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

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: Can't start MYSQL on Linux

2001-08-07 Thread Gerald Clark

chown -R mysql /var/lib/mysql

Ling Wang wrote:

 I have a fresh installed Linux 7.1 from Redhat. The mysal 3.23.36 was 
 installed together with the Redhat Linux. I can not start the mysql 
 server by executing /usr/bin/safe_mysqld . It always ends immediately. 
 When I look at the /var/log/mysql.log, the message says:
 
 mysql started
 /usr/libexec/mysql: Can't find file './mysql/host.frm' (errno: 13)
 mysql ended
 
 
 I tried start safe_mysqld from many directories and without any success. 
 Can anyone please help me out?
 
 Thanks.
 
 Ling Wang
 
 _
 Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.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


-- 
Gerald L. Clark
[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: Nested Queries in MySQl

2001-08-07 Thread William R. Mussatto

You can also do it programatically.  I find, even with MySQL that this is 
faster since it avoids the NxM intermediate table creation where one can 
limit the number of rows intially. I'm using Debian so I'm stuck on .22 
for now, this might change in .23.  It would definitely be the way to go 
for you nested queries. 

On Tue, 7 Aug 2001, Grigory Bakunov 
wrote:

 Date: Tue, 7 Aug 2001 09:57:52 +0500
 From: Grigory Bakunov [EMAIL PROTECTED]
 To: Steven Robillard [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Subject: Re: Nested Queries in MySQl
 
 Date |6 Aug 2001 19:59:46 -0700
 From |Steven Robillard [EMAIL PROTECTED]
 
 Hello!
 
 SR Hi all, I have not been using MySQL for too long but have been using SQL7.0 for 
a while now, so I am generally familiar with the structure.  
 SR My basic problem right now is trying to figure out how to get MySQL to do nested 
queries such as ...
 SR select count(*) from (select count(*) as A, group_col from my_table group by 
group_col) as B
 SR Could someone help me out with getting the nested query to work, (I know this 
can be done here with a distinct but work with me here.)  Thanks in advance.
 
 MySQL does'nt support nested queries now.
 You can try to play with JOIN syntax
 http://www.mysql.com/doc/J/O/JOIN.html
 
 ___
Truly yours, Grigory Bakunov
   ASPLinux Support Team
  http://www.asplinux.ru
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 To request this thread, e-mail [EMAIL PROTECTED]
 To unsubscribe, e-mail [EMAIL PROTECTED]
 Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
 

Sincerely,

William Mussatto, Senior Systems Engineer
CyberStrategies, Inc
ph. 909-920-9154 ext. 27


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

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




WANTED: Utility to reverse engineer existing database II

2001-08-07 Thread Kevin


Thanks for pointing out mysqldump.

I now need to be able to copy a limited number of data records.  I see that
mysqldump allows data copy by providing the cooresponding INSERT statements.
However, I don't always want all of the records.  Some of my tables have
thousands of records and I may only want the first 200 or so.  I did not see
an option on mysqldump that would limit the number of records.  Any ideas
without writing a program?

Kevin

 -Original Message-
 From: Kevin [mailto:[EMAIL PROTECTED]]
 Sent: Monday, August 06, 2001 4:58 PM
 To: [EMAIL PROTECTED]
 Subject: WANTED: Utility to reverse engineer existing database



 I need a utility that will probe my existing mysql database,
 analyze the 90+
 tables and spit out the data definition language (create table, create
 index, etc.) needed to recreate the database.  Does such a utility exist?

 Kevin


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

 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: Sub select.

2001-08-07 Thread Sam Masiello


You are correct, Tyler.

http://www.mysql.com/doc/M/i/Missing_Sub-selects.html

The above URL has some more information on this.

HTH :)

Sam Masiello
Software Quality Assurance Engineer
Synacor
(716) 853-1362 x289
[EMAIL PROTECTED]

 -Original Message-
From:   Tyler Longren [mailto:[EMAIL PROTECTED]]
Sent:   Tuesday, August 07, 2001 9:58 AM
To: Anders Alstrin
Cc: [EMAIL PROTECTED]
Subject:Re: Sub select.

I don't think MySQL supports sub selects.

Tyler


On Tue, 07 Aug 2001 14:57:33 +0200
Anders Alstrin [EMAIL PROTECTED] wrote:

 Does anyone know how to do this sub select in MySQL.
 I know how to do it in Oracle!

 table media
 +--+---+--+
 | media_id | price |filename  |
 +--+---+--+
 |3 | 0 | cal.jpg  |
 |   82 | 0 | Soa.jpg  |
 |   13 | 0 | ca.jpg   |
 |   71 | 0 | gt.pdf   |
 |   67 | 0 | low.pdf  |
 |   68 | 0 | 10.pdf   |
 |   83 | 0 | B5.pdf   |
 +--+---+--+

 table category_locks
 +--+-+--+
 | category_lock_id | category_id | media_id |
 +--+-+--+
 |   92 |   0 |   68 |
 |   93 |   0 |   67 |
 |   94 |   0 |   13 |
 |   91 |   0 |   71 |
 |   90 |   0 |3 |
 |  118 |  43 |   82 |
 |  121 |  43 |   83 |
 +--+-+--+

 table categories
 +-+-++---+--+
 | category_id | category_up | upload | dynamic_media | name |
 +-+-++---+--+
 |  43 |   0 | false  | true  | web  |
 |  0  |   0 | false  | false | trine|
 |  0  |   0 | false  | false | shop |
 +-+-++---+--+

 A Oracle way to do it:

 SELECT * FROM media
 WHERE media_id = (SELECT media_id FROM category_locks
 WHERE category_id = (SELECT category_id FROM categories
 WHERE dynamic_media = 'true'))

 A MySQL way to do it?


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

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


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

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


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

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] Database size

2001-08-07 Thread Heikki Tuuri

Hi!

At 02:59 PM 8/7/01 +0300, you wrote:
Grigory Bakunov writes:
 Date |Fri, 3 Aug 2001 17:21 +0200
 From |TIGNAC BRUNO [EMAIL PROTECTED]
 
 Hello!
 
 TB --- Reçu de   CMB.TIGNABR 0298426574 03-08-01
17.21
 
 TB Hello,
 
 TB I plan to use MySQL/InnoDB to store about 13 GB of data, into 40
tables. One
 TB of the tables is over 5 GB, and a second over 1,5 GB. Do you think I
can use
 TB MySQL/InnoDB ?
 
 In short words: YES.
 ___
 For technical support contracts, visit https://order.mysql.com/
 This email is sponsored by SWSoft, http://www.asplinux.ru/
__  ___ ___   __
   /  |/  /_ __/ __/ __ \/ /Grigory Bakunov [EMAIL PROTECTED]
  / /|_/ / // /\ \/ /_/ / /__   MySQL AB / SWSoft
 /_/  /_/\_, /___/\___\_\___/
___/   www.mysql.com
 


Next time provide more info. 

Actually largest tablespace in InnoDB is 4 Gb, but a single table can be
spanned over as many tablespaces as you wish.

Heikki, am I right ?

The totality of your data files is called the 'tablespace'.
The tablespace can be 4 billion database pages (page == 16 kB)
in size. A single table is allowed to extend to the whole tablespace.

A data file should be  4 GB, or  2 GB if your file system only
supports  2 GB files.

Regards,

Heikki

-- 
Regards,
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Sinisa Milivojevic [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, FullTime Developer
/_/  /_/\_, /___/\___\_\___/   Larnaca, Cyprus
   ___/   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




Upgrading to 3.23.37 from 3.22.32

2001-08-07 Thread Adam Douglas

I just upgraded MySQL from 3.22.32 to MySQL 3.23.37. All I did was
pkg_delete the old MySQL and install the new one. Before I delete the old
MySQL I copied all the database files to a temporary location. Once the new
installation was successful I copied over all the database files into the
proper location. 

My problem is I seem to have 3 extra tables now, A-1, A-9 and A-ce. The
funny thing is they all seem to be linked to my tables. These tables to my
knowledge were not present in the MySQL 3.22.32. Also I can't seem to remove
the test user from mysql-db, MySQL says it's read only. I never made the
table read only and doesn't seem to be.

Anyone have any ideas of what is going on? I feel kind of lost now, any help
would be greatly appreciated.

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

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 MySQL Console?

2001-08-07 Thread Tyler Longren

Get the mysql client from www.mysql.com.

Tyler

On Sun, 5 Aug 2001 13:38:09 -0400
Chris [EMAIL PROTECTED] wrote:

 Is there a method I can use to log into a remote mysql server through
 something such as telnet to pass queries on my database?
 

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

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




RE: MyOdbc to unix

2001-08-07 Thread Venu

Hi !

 -Original Message-
 From: SRIVATSAN RAGHURAMAN [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 6:13 PM
 To: [EMAIL PROTECTED]
 Subject: RE: MyOdbc to unix


 Hi Sinisa,
   Sorry I should have mentioned this earlier. From Windows.
 R.Srivatsan
  [EMAIL PROTECTED]
 ___
 Sinisa Milivojevic [EMAIL PROTECTED] Wrote---
 SRIVATSAN RAGHURAMAN writes:
  Hi Venu,
  I want some sample codes for ODBC connection to MySQL.
 Where can I get it?
  R.Srivatsan
   [EMAIL PROTECTED]


 To connect from Unix or from Windows ??

We are sorry to say this, at present there is no MyODBC samples available
for the public. We are in the plan of distributing some basic samples with
the next release version of the driver, shortly.

FYI, to establish a connection to MySQL through MyODBC, follow the following
instrcutions:

-- Download MyODBC driver from
http://www.mysql.com/downloads/api-myodbc.html
-- Follow the instructions from the online manual to install and configure
the DSN.
http://www.mysql.com/documentation/mysql/bychapter/manual_ODBC.html#ODBC
-- If you want to use it on Unix, configure the MyODBC with iODBC or
unixODBC. Please read the following archive which gives complete details in
setting up the MyODBC with iODBC/unixODBC:
http://lists.mysql.com/cgi-ez/ezmlm-cgi?5:mss:3657:200108:einnhiokafobjmjbmc
bm
-- Once DSN (lets say MyTest) as configured in ODBC.INI, write a simple
C-ODBC as given below and build it by linking through DM libraries. On NT,
use odbc32.lib.

Hope this helps you, let me know if you have any questions on this.
Regards
Venu

/* Common system headers */
#include windows.h /* for WINDOWS */
#include stdio.h
#include assert.h

/* MS SQL API headers */
#include sql.h
#include sqlext.h

/* PROTOTYPE */
void tmysql_error(RETCODE rc,HENV henv,HDBC hdbc,HSTMT hstmt);
void my_test(HDBC hdbc,HSTMT hstmt);

/* UTILITY MACROS */
#define MyEnvCHECK(henv,r)  \
if ( ((r) != SQL_SUCCESS) ) \
tmysql_error(r, henv, NULL, NULL); \
assert( ((r) == SQL_SUCCESS) || ((r) == SQL_SUCCESS_WITH_INFO) )

#define MyConCHECK(hdbc,r)  \
if ( ((r) != SQL_SUCCESS) ) \
tmysql_error(r, NULL, hdbc, NULL); \
assert( ((r) == SQL_SUCCESS) || ((r) == SQL_SUCCESS_WITH_INFO) )

#define MyStmtCHECK(hstmt,r)  \
if ( ((r) != SQL_SUCCESS) ) \
tmysql_error(r, NULL, NULL, hstmt); \
assert( ((r) == SQL_SUCCESS) || ((r) == SQL_SUCCESS_WITH_INFO) )

void main()
{
  HENV henv;
  HDBC hdbc;
  HSTMT hstmt;
  RETCODE rc;
  char *dsn= MyTest;
  char *uid= username;
  char *pwd= password;

  /* ALLOCATE ENVIRONMENT HANDLE */
  rc = SQLAllocEnv(henv);
  MyEnvCHECK(henv,rc);

  /* ALLOCATE CONNECTION HANDLE */
  rc = SQLAllocConnect(henv, hdbc);
  MyEnvCHECK(henv,rc);

  /* CONNECT TO THE SERVER */
  printf(connecting to '%s' with user name '%s'...\n,dsn,uid);
  rc = SQLConnect(hdbc, dsn, SQL_NTS, uid, SQL_NTS,  pwd, SQL_NTS);
  MyConCHECK(hdbc,rc);

  /* ALLOCATE STATEMENT HANDLE */
  rc = SQLAllocStmt(hdbc, hstmt);
  MyConCHECK(hdbc,rc);

  /* CALL FUNCTION TO PERFORM BASIC SQL OPS */
  my_test(hdbc, hstmt);

  /* FREE ALL HANDLES and DISCONNECT FROM SERVER */
  rc = SQLFreeStmt(hstmt, SQL_DROP);
  MyStmtCHECK(hstmt,rc);

  printf(disconnecting from server ...\n);
  rc = SQLDisconnect(hdbc);
  MyConCHECK(hdbc,rc);

  rc = SQLFreeConnect(hdbc);
  MyConCHECK(hdbc,rc);

  rc = SQLFreeEnv(henv);
  MyEnvCHECK(henv,rc);

} /* END OF MAIN */
/**
 Simple function to do basic ops with MySQL
*/
void myodbc_test(HDBC hdbc,HSTMT hstmt)
{
  RETCODE rc;
  int nInData = 1;
  int nOutData, nRowCount;
  char szOutData[31]={0};

/* CREATE TABLE 'myodbc' */
SQLExecDirect(hstmt,drop table tmyodbc ,SQL_NTS);
rc = SQLExecDirect(hstmt,create table tmyodbc (col1 int, col2
varchar(30)),SQL_NTS);
MyStmtCHECK(hstmt,rc);

rc = SQLTransact(NULL,hdbc,SQL_COMMIT);
MyConCHECK(hdbc,rc);

rc = SQLFreeStmt(hstmt,SQL_CLOSE);
MyStmtCHECK(hstmt,rc);

/* DIRECT INSERT */
rc = SQLExecDirect(hstmt,insert into tmyodbc
values(10,'direct-insert'),SQL_NTS);
MyStmtCHECK(hstmt,rc);

/* PREPARE INSERT */
rc = SQLPrepare(hstmt,insert into tmyodbc
values(?,'PARAM_INSERT'),SQL_NTS);
MyStmtCHECK(hstmt,rc);

rc = SQLBindParameter(hstmt,1,SQL_PARAM_INPUT, SQL_C_LONG,SQL_INTEGER,
  0,0,nIndata,0,NULL);
MyStmtCHECK(hstmt,rc);

for (nIndata=20 ; nIndata100; nIndata=index+10)
{
 rc = SQLExecute(hstmt);
   MyStmtCHECK(hstmt,rc);
}

rc = SQLTransact(NULL,hdbc,SQL_COMMIT);
MyConCHECK(hdbc,rc);

/* FREE THE PARAM BUFFERS */
rc = SQLFreeStmt(hstmt,SQL_RESET_PARAMS);
MyStmtCHECK(hstmt,rc);

rc = SQLFreeStmt(hstmt,SQL_CLOSE);
MyStmtCHECK(hstmt,rc);


Re: Remote MySQL Console?

2001-08-07 Thread Shon Stephens

Setup a user account that can access your databases from the remote hosts 
you wish to use. Do this using GRANT. Then install the mysql client on 
those systems and use
mysql -h hostname -u user -p password to connect.

Shon Stephens

At 01:38 PM 8/5/01 -0400, Chris wrote:
Is there a method I can use to log into a remote mysql server through
something such as telnet to pass queries on my database?


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

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




Re: SELECT to get last entry

2001-08-07 Thread Stefan Hinz

Dear Eldon,

 record for each device ID without retrieving them all to find the most
 recent name?

SELECT * FROM my_table WHERE ID = LAST_INSERT_ID(ID)

Check: http://www.mysql.com/doc/M/i/Miscellaneous_functions.html

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: Eldon Ziegler [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 1:24 PM
Subject: SELECT to get last entry


 I have a table that includes a device ID (indexed) and the name of the
 device with multiple records ordered over time. How can I retrieve the
last
 record for each device ID without retrieving them all to find the most
 recent name?

 Eldon Ziegler
 ProAtion Systems
 [EMAIL PROTECTED]
 http://www.proation.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: Sub select.

2001-08-07 Thread Stefan Hinz

Dear Anders,

subselects have not yet been implemented. You can find lots of
workaround examples here:

http://www.mysql.com/doc/M/i/Missing_Sub-selects.html

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: Anders Alstrin [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 2:57 PM
Subject: Sub select.


 Does anyone know how to do this sub select in MySQL.
 I know how to do it in Oracle!

 table media
 +--+---+--+
 | media_id | price |filename  |
 +--+---+--+
 |3 | 0 | cal.jpg  |
 |   82 | 0 | Soa.jpg  |
 |   13 | 0 | ca.jpg   |
 |   71 | 0 | gt.pdf   |
 |   67 | 0 | low.pdf  |
 |   68 | 0 | 10.pdf   |
 |   83 | 0 | B5.pdf   |
 +--+---+--+

 table category_locks
 +--+-+--+
 | category_lock_id | category_id | media_id |
 +--+-+--+
 |   92 |   0 |   68 |
 |   93 |   0 |   67 |
 |   94 |   0 |   13 |
 |   91 |   0 |   71 |
 |   90 |   0 |3 |
 |  118 |  43 |   82 |
 |  121 |  43 |   83 |
 +--+-+--+

 table categories
 +-+-++---+--+
 | category_id | category_up | upload | dynamic_media | name |
 +-+-++---+--+
 |  43 |   0 | false  | true  | web  |
 |  0  |   0 | false  | false | trine|
 |  0  |   0 | false  | false | shop |
 +-+-++---+--+

 A Oracle way to do it:

 SELECT * FROM media
 WHERE media_id = (SELECT media_id FROM category_locks
 WHERE category_id = (SELECT category_id FROM categories
 WHERE dynamic_media = 'true'))

 A MySQL way to do it?


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

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



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

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




Re: Can't start MYSQL on Linux

2001-08-07 Thread Stefan Hinz

Dear Wang,

 /usr/libexec/mysql: Can't find file './mysql/host.frm' (errno: 13)

It's tricky, but you have to install the two databases (mysql and test)
shipped along with the MySQL distribution. Here's that part:

shell ./scripts/mysql_install_db

And here's the manual part:
http://www.mysql.com/doc/P/o/Post-installation.html

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: Ling Wang [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 4:02 AM
Subject: Can't start MYSQL on Linux


 I have a fresh installed Linux 7.1 from Redhat. The mysal 3.23.36 was
 installed together with the Redhat Linux. I can not start the mysql
server
 by executing /usr/bin/safe_mysqld . It always ends immediately. When
I look
 at the /var/log/mysql.log, the message says:

 mysql started
 /usr/libexec/mysql: Can't find file './mysql/host.frm' (errno: 13)
 mysql ended


 I tried start safe_mysqld from many directories and without any
success. Can
 anyone please help me out?

 Thanks.

 Ling Wang

 _
 Get your FREE download of MSN Explorer at
http://explorer.msn.com/intl.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




Re: Help in Administration

2001-08-07 Thread Stefan Hinz

Dear Carsten,

  Hi, Sorry to bother you people but I've just locked
  myself out of my own DB.

Stop the MySQL server (mysqladmin shutdown) and start it again like
this: mysqld --skip-grant-tables :)

Here's the manual part:
http://www.mysql.com/doc/C/o/Command-line_options.html

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: Carsten H. Pedersen [EMAIL PROTECTED]
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Monday, August 06, 2001 11:14 PM
Subject: RE: Help in Administration


  Hi, Sorry to bother you people but I've just locked
  myself out of my own DB. I was installing some stupid
  program which required me to do some changes in the
  permissions and now I get this error Access Denied
  for user: 'root@localhost' (Using password: NO).

 http://www.bitbybit.dk/mysqlfaq/faq.html#ch7_2_0

 / Carsten
 --
 Carsten H. Pedersen
 keeper and maintainer of the bitbybit.dk MySQL FAQ
 http://www.bitbybit.dk/mysqlfaq


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

 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: Tables relationships

2001-08-07 Thread Stefan Hinz

Dear Chris,

look here: http://www.mysql.com/doc/J/O/JOIN.html

It's one of the JOINs (INNER JOIN or LEFT JOIN) you are looking for.

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: Chris Malloch [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 10:54 AM
Subject: Tables relationships


 Hi folks,

 Can someone please point me in the right direction to let me know how
to
 define a relationship between tables in MySQL eg one-to-many.  I
haven't
 come across it in the manual yet, but am sure it must be there
somewhere.

 Many thanks in advance,

 Chris Malloch



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

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: Truncated User List

2001-08-07 Thread Stefan Hinz

Dear Steve,

 (eg adding drop table columns_priv; before the CREATE TABLE
columns_priv;

You can use various options for mysqldump, like --add-drop-table. This
will add a drop table statement :)

Anyway, it's always a good idea to re-create tables and their data. One
reason: By default, mysqldump will add TYPE=MyISAM to every create table
statement, so old ISAM tables will be set up with the new (and better)
MyISAM format. Another reason: Tables will automatically be in
optimized state.

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: Steve Wright [EMAIL PROTECTED]
To: Grigory Bakunov [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 10:40 AM
Subject: Re: Truncated User List


 I've tried mysqldump, it worked perfectly, my data is now on the new
machine.
 I did have to alter the output file so the tables in the mysql
database where
 recreated without error.
 (eg adding drop table columns_priv; before the CREATE TABLE
columns_priv;
 line)
 What I want to know now is why didn't just moving the /var/lib/mysql/
 databases work ?
 I was given to understand if I wanted to exactly duplicate all the
databases
 on a machine I could just tar them  move them ?
 Is this not the case ?

 With Thanks
 Steve

 ---
 On Tuesday 07 August 2001 06:32, you wrote:
  Date |Mon, 6 Aug 2001 13:51:09 +0100
  From |Steve Wright [EMAIL PROTECTED]
 
  Hello!
 
 
  SW Hi,
  SW Wondering if anyone can here can help,
  SW We've got a small selection of MySQL databases used by our
customers
  (for SW websites).
  SW Until now we've used the Debian package of MySQL (latest deb.
version),
  SW however the systems are being updated  we're starting to use
source
  builds, SW (this is where the problem starts).
 
  SW I have 3.23.39 built  installed, we installed the old databases
on the
  new SW machine by shutting down the sql server  duplicating the
  /var/lib/mysql SW directory structure.
  SW When the users are listed on the new machine however half are
missing,
  I am SW very confused as I don't seem to be able to make them
reappear !
  SW I have looked in the /var/lib/mysql/mysql/user. files  can see
them 
  SW /etc/my.cnf is looking in the right place
 

  You must use mysqldump utility for data export and then
  import old data to the table.
  It's much clean way.
  http://www.mysql.com/doc/m/y/mysqldump.html
 
  ___
  For technical support contracts, visit https://order.mysql.com/
  This email is sponsored by SWSoft, http://www.asplinux.ru/
 __  ___ ___   __
/  |/  /_ __/ __/ __ \/ /Grigory Bakunov [EMAIL PROTECTED]
   / /|_/ / // /\ \/ /_/ / /__   MySQL AB / SWSoft
  /_/  /_/\_, /___/\___\_\___/
 ___/   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



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

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




Re: how to delete a database table?

2001-08-07 Thread Stefan Hinz

Dear Louie,

 how can i delete a database table?

Check the manual? http://www.mysql.com/doc/D/R/DROP_TABLE.html

DROP TABLE [IF EXISTS] tbl_name [, tbl_name,...]

Or something like DROP TABLE my_database.my_table

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: louie miranda [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 4:15 AM
Subject: how to delete a database table?




 how can i delete a database table?

 ty






 louie miranda
 ---
 (axishift.ath.cx) PGPID: 0xDABA60C7





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

 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: Import data question

2001-08-07 Thread Stefan Hinz

Dear Chip,

you cannot use reserved words as column names. You have password as a
col name which is a reserved word in SQL. The error derives from there,
only MySQL gets it wrong and points you into the wrong direction as to
where to search.

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, August 06, 2001 10:48 PM
Subject: Import data question


 I have a table I want to import some records into. The table has 4
columns
 -
 user_id, name, account, password.
 The file I have to be imported has 3 columns -
 password,name,account.
 I have been trying to use load data infile and keep ending up with a
lot of
 junk in the database.
 The file is of this format -
 password,name,account
 password,name,account
 etc
 File name is users and table name is users.

 mysql load data infile '/usr/home/chip/users' into table users
 - (name,password,account)
 - fields terminated by ',';
 ERROR 1064: You have an error in your SQL syntax near 'fields
terminated by ','' at l
 ine 3
 mysql

 Regards,
 Chip Wiegand
 Computer Services
 www.simradusa.com
 [EMAIL PROTECTED]
 Simrad, Inc
 Lynnwood, WA
 425-712-1138

 There is no reason anyone would want a computer in their home.
  --Ken Olson, president, chairman and founder of Digital Equipment
Corp.,
 1977
   (-- Then why do I have nine? Somebody help me!)


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

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

2001-08-07 Thread Stefan Hinz

Dear Matt,

 have had no experience of the above two products

just some useful links:

www.phpmyadmin.com

www.php.net/documentation

www.mysql.com/documentation

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: Matt Gaskin [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 2:51 PM
Subject: MySql and PHP


 Hi All

 Currently I have rented space on a Web Server that has MySql installed
and
 PHP, They have created a database directory for myself. Do I need to
install
 Mysql and PHP locally to take advantage of this. If so where do I
start. I
 have had no experience of the above two products, although I have
written a
 number of websites in HTML and a number of access databases. We have
just
 started to get a number of enquiries for databases online and would
like to
 develope in this area.

 Thanks
 M


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

 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: Remote MySQL Console?

2001-08-07 Thread Steve Brazill

You did not mention what the 'client' or the 'server' were (i.e. NT, UNIX,
Mac),  or what the 'distance' between the 2 was (over the Internet ?,  thru
firewalls, etc).

If you're trying to connect over any distance on a network,  make sure you
DON'T use 'telnet' or 'ftp' (or you will find your server being 'hacked' as
soon as someone notices the packets going by with the login name and
password).

This topic has come up in this list numerous times,  and you can search the
archives for ssh to find the answer you're looking for...

- Original Message -
From: Chris [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, August 05, 2001 10:38 AM
Subject: Remote MySQL Console?


Is there a method I can use to log into a remote mysql server through
something such as telnet to pass queries on my database?



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

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




Save object into MySQL

2001-08-07 Thread Zengfa Gao

Hi, 

I want to save object into MySQL database. Since MySQL
in not object relational database, is any problem to
save object into it? Which attribute I should select
to save object? Varchar BINARAY?

Thanks for your help!

Zengfa

__
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.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: Truncated User List

2001-08-07 Thread Steve Wright

Ok, I follow that, in future when moving databases I will use mysqldump.
However, I still wish to know why moving the databases by duplicating the 
files  directory structure does not work. This is 100% repeatable and I 
can't see why (unless file(s) exist I am not copying).

If for some reason sql stops responding / my server dies I will want the most 
recent copy of the sql databases, this will always be /var/lib/mysql/  if I 
can access it on the disk, I want to know I can recover it.

I don't mean to sound ungrateful to those who are trying to help me, I just 
need to grasp an understanding of what is causing my problem  why.
mysqldump has helped me  solved moving my databases, however I can still 
recreate the original problem  still do not understand it.

With Thanks,
Steve.
---

On Tuesday 07 August 2001 17:10, you wrote:
 Dear Steve,

  (eg adding drop table columns_priv; before the CREATE TABLE

 columns_priv;

 You can use various options for mysqldump, like --add-drop-table. This
 will add a drop table statement :)

 Anyway, it's always a good idea to re-create tables and their data. One
 reason: By default, mysqldump will add TYPE=MyISAM to every create table
 statement, so old ISAM tables will be set up with the new (and better)
 MyISAM format. Another reason: Tables will automatically be in
 optimized state.

 Regards,

 --
   Stefan Hinz
   Geschäftsführer / CEO iConnect e-commerce solutions GmbH
   #  www.js-webShop.com www.iConnect.de
   #  Gustav-Meyer-Allee 25, 13355 Berlin
   #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

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

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 MySQL Console?

2001-08-07 Thread Stefan Hinz

Dear Chris,

Is there a method I can use to log into a remote mysql server through
something such as telnet to pass queries on my database?

If you have a telnet account on the remote machine, log in. Then start
mysql (MySQL monitor, command line tool) which will connect to the MySQL
server. You may have to enter MySQL user name and password, like this:

mysql -u username -p
(server will prompt for password then)

If network connection are permitted, you can log on from your local
machine using mysql as well. Something like this:

mysql -h hostname_or_ip -u username -p

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: Chris [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, August 05, 2001 7:38 PM
Subject: Remote MySQL Console?


Is there a method I can use to log into a remote mysql server through
something such as telnet to pass queries on my database?



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

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




RE: Speed (char or integer)

2001-08-07 Thread Carsten H. Pedersen

 I have a table with (char)Username attribute which is the primary 
 key of the table and also acts as a  foreign key in many other tables. 
 
 My question is if the queries would be faster if i used a numeric 
 value for the primary key?

Integers would be faster, but the question is really
by *how much*.

If the Username field is long (though I presume it 
isn't) and/or you have many rows, the index will take 
up more space, and might not fit in memory (and will 
thus need to read from disk during queries).

If the field is not declared BINARY, MySQL will do the
search in a case-insensitive manner, which will
of course be *very* slow compared to both a BINARY
char column and an integer column.

All that aside, keeping the Username column as the 
primary key may be more logical and easier to maintain
in the long run, and by introducing an integer key,
you may be giving up simplicity for the sake of a 
potentially very small gain in speed.

/ Carsten
--
Carsten H. Pedersen
keeper and maintainer of the bitbybit.dk MySQL FAQ
http://www.bitbybit.dk/mysqlfaq
 

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

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

2001-08-07 Thread Tonu Samuel

On 07 Aug 2001 13:51:01 +0100, Matt Gaskin wrote:

 Currently I have rented space on a Web Server that has MySql installed and
 PHP, They have created a database directory for myself. Do I need to install
 Mysql and PHP locally to take advantage of this. If so where do I start. I
 have had no experience of the above two products, although I have written a
 number of websites in HTML and a number of access databases. We have just
 started to get a number of enquiries for databases online and would like to
 develope in this area.

I believe your provider should support first step help for you as it
depends on exact details how this site is set up and configured. Also
take a look on simple PHP tutorials on the web.

-- 
For technical support contracts, goto https://order.mysql.com/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Tonu Samuel [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, Security Administrator
/_/  /_/\_, /___/\___\_\___/   Hong Kong, China
   ___/   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: SQL question

2001-08-07 Thread Carsten H. Pedersen

Dave Rigby wrote: 

 Hi,
 
 Could you create a linked list of the links- i.e. have a 'Next' field,
 which contains the ID of the next URL in order. You will also need a
 field to store if the link is the first (i.e. root) of the list. Then
 you can just iterate though the rows, using the next field to tell you
 which URL is next. To add or delete will only require one or two changes
 
 It might be a bit overkill if the list of URLs is quite small, but it
 will scale up to any size

Errmm... every now and then someone will say linked list
in this forum. Now, everybody, repeat after me:

SQL is NOT suited for linked lists. SQL is about thinking
in SETs of data. If you need linked lists, there's a thousand
languages more suited for the purpose.

Now, returning to the original question:

Hold on to the idea of a precedence field, then add a
DATETIME field precedence_changed, where you note
the last time the precence was set.

Then, whenever you query the data:

ORDER BY precedence, precedence_changed DESC

That will give you the records in order of precedence,
placing the more recently proceeded records first.

The solution and its effects may require a bit of 
explanation to the customer, tho'

/ Carsten
--
Carsten H. Pedersen
keeper and maintainer of the bitbybit.dk MySQL FAQ
http://www.bitbybit.dk/mysqlfaq

 
 Regards
 
 
 On 07 Aug 2001 02:35:26 -0600, Healthwell.com wrote:
  
  I have a general how do you do that SQL question.
  
  I have a table with links in it.  One link per row, with URL 
 link name, etc.
  
  The client wants to be able to specify the order in which the 
 links appear.
  In other words, they want to set any link to show up first, 
 another other
  link to show up second, etc, etc.
  
  I did a rough think like this a while back, by allowing then to set a
  precedent field, than the sorted on that field.  The trick 
 is, of course,
  if they ad a link and want it to show up in the second slot, then the
  precedence filed for records higher then 2 need to be 
 incremented by one,
  so the sequence will still be in tack.
  
  I'm thinking there must be a better way to do this, but I don't 
 know what it
  is.
  
  Thanks in advance,
  
  Peter Janett
  
  New Media One Web Services
  
  WEB HOSTING FOR WEB DEVELOPERS
  
  Sun, IRIX, Windows 2000, Linux;
  PHP, MySQL, Perl, Cold Fusion,
  MS SQL, ASP, SSI, SSL
  http://www.newmediaone.net
  [EMAIL PROTECTED]
  (303)828-9882
  
  
  
  -
  Before posting, please check:
 http://www.mysql.com/manual.php   (the manual)
 http://lists.mysql.com/   (the list archive)
  
  To request this thread, e-mail [EMAIL PROTECTED]
  To unsubscribe, e-mail 
 [EMAIL PROTECTED]
  Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
  
 -- 
 Dave Rigby
 
 Opal Telecom
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 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 w/SSL support howto?..

2001-08-07 Thread Tonu Samuel

On 07 Aug 2001 16:21:13 +0800, louie miranda wrote:
 Is it possible for mysql 3.23.40 to support SSL.
 
 hm, how?

No, from MySQL 4.0 only.

-- 
For technical support contracts, goto https://order.mysql.com/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Mr. Tonu Samuel [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB, Security Administrator
/_/  /_/\_, /___/\___\_\___/   Hong Kong, China
   ___/   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




Auditing...

2001-08-07 Thread Wyly Wade
Title: Blank



Has anyone built or implemented field level 
auditing in a mysql database? Any body have a quick down and dirty way of doing 
this? 

Thanks for the suggestions

Wyly Wade
Forefront Inc
1413 S. Howard Ave
Suite 104
Tampa Fl, 33606
813-253-2267


Re: Localization..

2001-08-07 Thread Grigory Bakunov

Date |Tue, 7 Aug 2001 17:25:48 +0800
From |SDiZ Cheng [EMAIL PROTECTED]

Hello!


SC I have read these docs. I can't find any charset option in CREATE TABLE
SC syntax.
Oh no.
You need to set up charset in mysql configuration.
like this:
http://www.mysql.com/doc/C/h/Character_sets.html

___
For technical support contracts, visit https://order.mysql.com/
This email is sponsored by SWSoft, http://www.asplinux.ru/
   __  ___ ___   __
  /  |/  /_ __/ __/ __ \/ /Grigory Bakunov [EMAIL PROTECTED]
 / /|_/ / // /\ \/ /_/ / /__   MySQL AB / SWSoft
/_/  /_/\_, /___/\___\_\___/
   ___/   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: importing data

2001-08-07 Thread Carsten H. Pedersen

Look up 
IMPORT DATA INFILE
in the manual

/ Carsten
--
Carsten H. Pedersen
keeper and maintainer of the bitbybit.dk MySQL FAQ
http://www.bitbybit.dk/mysqlfaq

 -Original Message-
 From: Kevin Fonner [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 07, 2001 5:09 PM
 To: [EMAIL PROTECTED]
 Subject: importing data
 
 
 Is there an easy way or perhaps a utility to import a tab delimeted text 
 file of data into a mysql table
 
 Thanks,
 
 -- 
 Kevin Fonner
 
 
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 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




Driver? - SQLException Error Before start of result set

2001-08-07 Thread Lucy

Hi
Problems started after I upgraded my Driver from mm.mysql.jdbc-1.2c to
mm.mysql-2.0.4-bin.jar,
still using MySQL v.3.23.33 on ApacheTomcat (Win2000) where I formerly had
the \org\ Driver dir in \classes\ but now have new Driver in \lib\ and
haven't unzipped jar.  Yes, updated Environ Var'bles pointing to mysql\ dir.
1.  New Driver works fine with normal Servlets on normal Database Tables so
I assumed everything was OK.
2.  New Servlets to new Database Tables produces SQLException Error Before
start of result set and blank screen from searches to DB, showing no
parameters output from new DB.  New DB Tables produced since installing new
Driver.
3.  Tested New Servlets on normal Database Tables and they produce search
results OK, no SQLException errors.
4.  Have dropped new DB Tables many times and re-input data, starting again,
but still same result as point 3.
5.  Re-installed old Driver for testing, normal Servlets to normal DB Tables
work fine.  Slight improvement to new Servlets to new DB Tables: now shows
null for each respective parameter in Html output instead of a blank
screen.
I am so stuck.  What am I missing?  Cheers, Lucy



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

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: importing data

2001-08-07 Thread j.urban

http://www.mysql.com/doc/L/O/LOAD_DATA.html
http://www.mysql.com/doc/m/y/mysqlimport.html
http://www.mysql.com/doc/L/o/Loading_tables.html


On Tue, 7 Aug 2001, Kevin Fonner wrote:

 Is there an easy way or perhaps a utility to import a tab delimeted text 
 file of data into a mysql table
 
 Thanks,
 
 -- 
 Kevin Fonner
 
 
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 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: WANTED: Utility to reverse engineer existing database II

2001-08-07 Thread Carsten H. Pedersen

 Thanks for pointing out mysqldump.
 
 I now need to be able to copy a limited number of data records.  
 I see that
 mysqldump allows data copy by providing the cooresponding INSERT 
 statements.

mysqldump -w

/ Carsten
--
Carsten H. Pedersen
keeper and maintainer of the bitbybit.dk MySQL FAQ
http://www.bitbybit.dk/mysqlfaq




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

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: WANTED: Utility to reverse engineer existing database II

2001-08-07 Thread j.urban

Did you see the -w, --where option?  It might be what you're looking
for...

Dump only selected records.
--http://www.mysql.com/doc/m/y/mysqldump.html

If you have a more complicated query and you are using Windows, you can
use urSQL + MyODBC to accomplish this as urSQL 
(http://www.urbanresearch.com/ursql) allows you to export the results of
any query (to a variety of formats). 


On Tue, 7 Aug 2001, Kevin wrote:

 
 Thanks for pointing out mysqldump.
 
 I now need to be able to copy a limited number of data records.  I see that
 mysqldump allows data copy by providing the cooresponding INSERT statements.
 However, I don't always want all of the records.  Some of my tables have
 thousands of records and I may only want the first 200 or so.  I did not see
 an option on mysqldump that would limit the number of records.  Any ideas
 without writing a program?
 
 Kevin
 


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

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




Zerofill Auto_Increment

2001-08-07 Thread mickalo

Hi All,

Not sure if this is a bug or just a standard behavior of a auto_increment
zerofill column.

I have a column in a MySQL database table assigned as such:

memid int(8) auto_increment zerofill primary key,

now when the a new row is inserted in fills the column with the appropriate 0's,
but when I do a 'SELECT LAST_INSERT_ID()', after the insert, I get the last
insert number, without the zeros, IE... Last inserted id value = '0012' but
the return value is '12' and if I do a SELECT * FROM table_name WHERE memid =
'12'; or SELECT * FROM table_name WHERE memid = '0012';

I get the same results, whether I use '12' or '0012' 

Is this suppose to do that?? Just curious :)

THX's


Mike(mickalo)Blezien
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Thunder Rain Internet Publishing
Providing Internet Solutions that work!
http://www.thunder-rain.com
Tel: 1(225)686-2002
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=


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

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: WANTED: Utility to reverse engineer existing database II

2001-08-07 Thread Michael Meltzer

emacs

MJM

- Original Message -
From: Kevin [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 11:30 AM
Subject: WANTED: Utility to reverse engineer existing database II



 Thanks for pointing out mysqldump.

 I now need to be able to copy a limited number of data records.  I see
that
 mysqldump allows data copy by providing the cooresponding INSERT
statements.
 However, I don't always want all of the records.  Some of my tables have
 thousands of records and I may only want the first 200 or so.  I did not
see
 an option on mysqldump that would limit the number of records.  Any ideas
 without writing a program?

 Kevin

  -Original Message-
  From: Kevin [mailto:[EMAIL PROTECTED]]
  Sent: Monday, August 06, 2001 4:58 PM
  To: [EMAIL PROTECTED]
  Subject: WANTED: Utility to reverse engineer existing database
 
 
 
  I need a utility that will probe my existing mysql database,
  analyze the 90+
  tables and spit out the data definition language (create table, create
  index, etc.) needed to recreate the database.  Does such a utility
exist?
 
  Kevin
 
 
  -
  Before posting, please check:
 http://www.mysql.com/manual.php   (the manual)
 http://lists.mysql.com/   (the list archive)
 
  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




clueless newbie question re merge/union

2001-08-07 Thread David Newman


Greetings,

I am attempting to use MySQL's MERGE feature to link tables from different
databases. All tables have identical structures, and I need to do this
because each table is right up against the 2-Gbyte limit imposed by Linux's
ext2 filesystem.

System info: OS is RH Linux 7.1 (2.4.3-12smp kernel), MySQL version is
3.23.36-1.

When I create two small tables within the SAME database and then run a
merge, everything works fine. However, when I run similar commands across
multiple databases, even with small tables, I get an error. In the following
example, t1 and t2 have 10,000 records apiece.

#
# First make and populate t1
#
CREATE DATABASE t1;
USE t1;
CREATE TABLE t1 (type VARCHAR(16), price DOUBLE INDEX (type));
LOAD DATA INFILE 't1.csv' INTO TABLE t1
FIELDS TERMINATED BY ',';
#
# Now create and populate t2
#
CREATE DATABASE t2;
USE t2;
CREATE TABLE t2 (type VARCHAR(16), price DOUBLE INDEX(type));
LOAD DATA INFILE 't2.csv' INTO TABLE t2
FIELDS TERMINATED BY ',';
#
# Now make a union between t1 and t2 called total
#
CREATE DATABASE total;
USE total;
CREATE TABLE total (type VARCHAR(16), price DOUBLE INDEX(type))
TYPE=MERGE UNION=(t1.t1, t2.t2);
DESCRIBE total;

This last command produces the following error:

ERROR 1017: Can't find file: 'total.MRG' (errno: 2)

When I examine total.MRG I see that its contents are simply t1 and t2 on
individual lines. Editing the file to t1.t1 and t2.t2 has no effect, nor
does changing permissions on total.MRG to 777.

How can I get the union to work?

Also, a question about merges: In the example above, if t1 and t2 are huge,
will the resulting 'total' also be huge?

Thanks in advance.

Regards,
David Newman



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

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




My databases got hosed when the server went down hard!

2001-08-07 Thread chip . wiegand

Geez, if it ain't one thing it's another. :-(
My fbsd server went down hard today, now my mysql database is supposedly
gone.
I see the .MYD, .MYI, and .FRM files in the /usr/var/db/mysql/ directory,
but I get this -

mysql use bulletins
Can't read dir of './bulletins/' (Errcode: 13)
Database changed
mysql show tables;
ERROR 12: Can't read dir of './bulletins/' (Errcode: 13)
mysql myisamchk -s /usr/var/db/mysql/bulletins/*.MYI;
ERROR 1064: You have an error in your SQL syntax near 'myisamchk -s /usr/var/db/mysql
/bulletins/*.MYI' at line 1

Obviously I don't know how to use myisamchk properly.
In Webmin I see the icons for the database, but when I select it the screen changes 
and shows
This database has no tables.

Hopefully these files can be restored, I can view them with cat and they do contain the
data that was entered previously.

Chip Wiegand
Computer Services
www.simradusa.com
[EMAIL PROTECTED]
Simrad, Inc
Lynnwood, WA
425-712-1138

There is no reason anyone would want a computer in their home.
 --Ken Olson, president, chairman and founder of Digital Equipment Corp.,
1977
  (-- Then why do I have nine? Somebody help me!)


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

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




Followup on 1054 error

2001-08-07 Thread Mike . Kent

Thanks for all the responses to my posting below.

I was using phpmysqladmin to check on updating the database, and I finally
figured out that phpmysqladmin was misconfigured, with the same database on
two different servers but with different column names. Naturally I was
sending the query to the database with the wrong column name, which is why
I got the error. Once I figured it out (by command line calls to mysql),
all was well.

I appreciate the advice from the list and I've changed some of the column
names as responders suggested to avoid other problems. So thanks much!

   
 Mike Kent The Indianapolis Star - Information 
   Technology  
   
 Internet mail:AOL messenger: mkent INI
 [EMAIL PROTECTED]
   



- Forwarded by Mike Kent/INI on 08/07/01 01:42 PM -
   

Mike Kent  

 To: [EMAIL PROTECTED] 

08/06/01 cc:   

11:56 AM Subject: 1054 error   

   

   




I'm new to MySQL and I get a 1054 error on this SQL query sent by a PHP 4
script:

1054: Unknown column 'pricerange' in 'field list'


$sql is INSERT INTO CCC_reviews (restname, type, specialties, address,
phone, hours, pricerange, creditcards, reservations, rating, miscinfo,
area, wheelchair, maplink, byline, date, reviewsum, review) VALUES
('Junkyard dog', 'Bakery', 'dogburgers', 'who cares', 'none', 'none',
'Moderate', 'Y', 'N', '1 1/2', 'Place stinks', 'North', 'N', 'somewhere',
'By Junkyard Bob', 'August 6, 2001', 'blah blah blah sum', 'blah blah blah
real thing')


The column pricerange does exist, and I've verified there's no trailing
space or the like.


Anyone know what's wrong?


Thanks.

   
 Mike Kent The Indianapolis Star - Information 
   Technology  
   
 Internet mail:AOL messenger: mkent INI
 [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




Problem with MySQL over HP-UX 10.20

2001-08-07 Thread Victor Lopez

HI,

i am trying to install MySQL over an HP-UX 10.20 machine:
# uname -a
HP-UX hpbmp01 B.10.20 E 9000/899 1653421311 8-user license


When i try to run the Installation procedure this fail with the follow 
error (Memory failt).
# scripts/mysql_install_db
Creating db table
Creating host table
Creating user table
Creating func table
Creating tables_priv table
Creating columns_priv table
scripts/mysql_install_db[238]: 22393 Memory fault
Installation of grant tables failed!


I have probed with two differents MySQL version, 3.23.40 and 3.22.32 and 
obtaing the similar problem.


Anybody knows how can i fix this problem??


# ls -al
total 32310
drwxr-x---   3 bmpadmabmpa  1024 Aug  7 13:42 .
drwxr-x---  17 bmpadmabmpa  1024 Aug  6 14:11 ..
--   1 bmpadmabmpa   102 Dec 31  1969 @LongLink
lrwxr-x---   1 bmpadmabmpa34 Aug  7 13:42 mysql - 
mysql-3.22.32-hp-hpux10.20-hppa1.1
drwxr-x---  11 bmpadmabmpa  1024 Aug  7 13:40 
mysql-3.22.32-hp-hpux10.20-hppa1.1
-rw-r--r--   1 bmpadmabmpa   10915840 Aug  7 13:36 
mysql-3.22.32-hp-hpux10.20-hppa1.1.tar
-rw-r--r--   1 bmpadmabmpa   5605598 Aug  6 10:55 
mysql-3.23.40-hp-hpux10.20-hppa1.1.tar.gz


best regards,
Víctor

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

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: importing data

2001-08-07 Thread Bing Du

Please see section 6.17 of http://www.mysql.com/doc/index.html.

Bing

Bing Du [EMAIL PROTECTED], 979-845-9577
Texas AM University, CIS, Operating Systems, Unix

 Kevin Fonner [EMAIL PROTECTED] 08/07/01 10:08AM 
Is there an easy way or perhaps a utility to import a tab delimeted
text 
file of data into a mysql table

Thanks,

-- 
Kevin Fonner



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

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: Localization..

2001-08-07 Thread SDiZ Cheng



 Date |Tue, 7 Aug 2001 17:25:48 +0800
 From |SDiZ Cheng [EMAIL PROTECTED]
 
 Hello!
 
 
 SC I have read these docs. I can't find any charset option in CREATE TABLE
 SC syntax.
 Oh no.
 You need to set up charset in mysql configuration.
 like this:
 http://www.mysql.com/doc/C/h/Character_sets.html

Yes, i have read that too.
that tell me how to compile mysql with multi charset,
but not create such kind of table.

i expect there is somthing like
  CREATE TABLE tbl_name ( 
col_name type CHARSET=char_set, 
col_name2 type CHARSET=char_set2 ) ...

  CREATE DATABASE db_name DEFAULT_CHARSET=char_set 
where can i find these?


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

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: Localization..

2001-08-07 Thread SDiZ Cheng

 Date |Tue, 7 Aug 2001 17:25:48 +0800
 From |SDiZ Cheng [EMAIL PROTECTED]
 
 Hello!
 
 
 SC I have read these docs. I can't find any charset option in CREATE TABLE
 SC syntax.
 Oh no.
 You need to set up charset in mysql configuration.
 like this:
 http://www.mysql.com/doc/C/h/Character_sets.html

Yes, i have read that too.
that tell me how to compile mysql with multi charset,
but not create such kind of table.

i expect there is somthing like
  CREATE TABLE tbl_name ( 
col_name type CHARSET=char_set, 
col_name2 type CHARSET=char_set2 ) ...

  CREATE DATABASE db_name DEFAULT_CHARSET=char_set 
where can i find these?



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

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: WANTED: Utility to reverse engineer existing database II

2001-08-07 Thread Jay Fesco

...Some of my tables have thousands of records and I may only want the first
200 or so.  I did not see
an option on mysqldump that would limit the number of records.  Any ideas
without writing a program?

Kevin




Try the WhereClause option in mysqldump.

Syntax is:

-w 'where_clause'
-or-
--where='where_clause'.

Of course, 'where_clause' would be something like 'id200' or whatever's
appropriate.

It's on page 620 of 'MySQL' by Paul DuBois (New Riders).  Invaluable book,
btw.

Jay Fesco


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

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: Speed (char or integer)

2001-08-07 Thread ryc

A numeric value will be faster in most cases. The reason being that a
comparison between two numbers at most takes 1 comparison... but a
comparison for a char at most takes n comparisons (n being the length of the
field/string). In addition a numeric value would take less space... all
around its a good deal faster.

ryan

- Original Message -
From: Goran Krajacic [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 9:33 AM
Subject: Speed (char or integer)


I have a table with (char)Username attribute which is the primary key of the
table and also acts as a  foreign key in many other tables.

My question is if the queries would be faster if i used a numeric value for
the primary key?



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

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: importing data

2001-08-07 Thread Stefan Hinz

Dear Kevin,

 Is there an easy way or perhaps a utility to import a tab delimeted
text
 file of data into a mysql table

Try PhpMyAdmin (www.phpmyadmin.com). Great browser based utility. You
need to have PHP installed in order to use it.

You may as well use the LOAD DATA INFILE command. Check
http://www.mysql.com/doc/L/O/LOAD_DATA.html for details.

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: Kevin Fonner [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 5:08 PM
Subject: importing data


 Is there an easy way or perhaps a utility to import a tab delimeted
text
 file of data into a mysql table

 Thanks,

 --
 Kevin Fonner



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

 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: WANTED: Utility to reverse engineer existing database II

2001-08-07 Thread Stefan Hinz

Dear Kevin,

 an option on mysqldump that would limit the number of records.  Any
ideas
 without writing a program?

AFAIK you cannot do this with mysqldump. But you can use the SELECT ...
INTO OUTFILE syntax, in some way like this:

SELECT * FROM my_table INTO OUTFILE some_records WHERE id BETWEEN
200 AND 400

or (from the manual ;-)

SELECT a,b,a+b INTO OUTFILE /tmp/result.text
FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY ''
LINES TERMINATED BY \n
FROM test_table
WHERE id BETWEEN 200 AND 400

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

Regards,

--
  Stefan Hinz
  Geschäftsführer / CEO iConnect e-commerce solutions GmbH
  #  www.js-webShop.com www.iConnect.de
  #  Gustav-Meyer-Allee 25, 13355 Berlin
  #  Tel: +49-30-46307-382  Fax: +49-30-46307-388

- Original Message -
From: Kevin [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, August 07, 2001 5:30 PM
Subject: WANTED: Utility to reverse engineer existing database II



 Thanks for pointing out mysqldump.

 I now need to be able to copy a limited number of data records.  I see
that
 mysqldump allows data copy by providing the cooresponding INSERT
statements.
 However, I don't always want all of the records.  Some of my tables
have
 thousands of records and I may only want the first 200 or so.  I did
not see
 an option on mysqldump that would limit the number of records.  Any
ideas
 without writing a program?

 Kevin

  -Original Message-
  From: Kevin [mailto:[EMAIL PROTECTED]]
  Sent: Monday, August 06, 2001 4:58 PM
  To: [EMAIL PROTECTED]
  Subject: WANTED: Utility to reverse engineer existing database
 
 
 
  I need a utility that will probe my existing mysql database,
  analyze the 90+
  tables and spit out the data definition language (create table,
create
  index, etc.) needed to recreate the database.  Does such a utility
exist?
 
  Kevin
 
 

 -
  Before posting, please check:
 http://www.mysql.com/manual.php   (the manual)
 http://lists.mysql.com/   (the list archive)
 
  To request this thread, e-mail [EMAIL PROTECTED]
  To unsubscribe, e-mail
  [EMAIL PROTECTED]
  Trouble unsubscribing? Try:
http://lists.mysql.com/php/unsubscribe.php
 
 


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

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



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

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




Re: MySql and PHP

2001-08-07 Thread Nicholas Ritter

Speaking of Mysql and PHP, has anyone had a problem compiling PHP 4.0.6 (as
a DSO) with MySQL 3.23.40 in use with Apache 1.3.14 on a redhat 7.0 box?

The error I get occurs when I run apache, during startup it says that it can
load the php module because the libmysqlclient.so.10 file cannot be found,
even though the file is there. Any thoughts?

I figured I would ask here before asking the PHP list because they never
seem to be of much help.

Nicholas



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

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: Save object into MySQL

2001-08-07 Thread Carsten H. Pedersen

 Hi, 
 
 I want to save object into MySQL database. Since MySQL
 in not object relational database, is any problem to
 save object into it? Which attribute I should select
 to save object? Varchar BINARAY?
 
First of all, you need to serialize the object
somehow. I assume that the language in which you
define your object is capable of this.

Secondly, I would assume that the best column
type would be a BLOB or MEDIUMBLOB.

/ Carsten
--
Carsten H. Pedersen
keeper and maintainer of the bitbybit.dk MySQL FAQ
http://www.bitbybit.dk/mysqlfaq



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

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




Upgrading mysql on Win2K

2001-08-07 Thread A. Clausen

What is the process of upgrading v3.23.36 to 3.23.40 on Windows NT.  Can I just 
install over top or is there some other steps that should be taken?  I am running two 
mysql servers, one a  master and one a slave.  Does this make a difference?


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

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 multiple files into the same table at once?

2001-08-07 Thread Bing Du

Hi,

If this kind of question has been asked and answered, I'd appreciate if
somebody can point me to the right direction looking for the answers.

The question is how I should load different external text files into
different columns of the same table.  For instance, file1.txt contains
'ssn name' and file2.txt contains 'ssn grade'.  These two files are
generated by different organizations and we want to put both name and
grade info into the same table.

The table named students contains three columns: ssn name grade.
One sample record is like:

ssn   namegrade
-   
123456789 John Smith 95%

I tried: 

mysql load data local infile '/home/file1.txt' replace into table
students (ssn,name);

mysql load data local infile '/home/file2.txt' replace into table
students (ssn,grade);

But the second 'load data' replaces all the stuff that the first one
just loaded.

If I use 'ignore', the grades can not get loaded at all.

Any help would be greatly appreciated.

Bing

Bing Du [EMAIL PROTECTED], 979-845-9577
Texas AM University, CIS, Operating Systems, Unix

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

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   >