RE: Remote mysqldump

2002-05-05 Thread Alexander Shaw

Paul DuBois wrote

I can think of a couple of different ways to interpret your question.
Offhand, I'd say that you want to specify -h server_host on the mysqldump
command line, but if that's not what you mean, perhaps you can be more
specific.

Sorry probably not so well explained, I'll try again.

Using another machine (running windows) elsewhere on the network, is it
possible to perform a mysqldump of the databases on the server? i.e. without
having to go physically to the server machine and typing the commands at the
command prompt.

Alex
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.346 / Virus Database: 194 - Release Date: 10/04/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: Remote mysqldump

2002-05-05 Thread Jeremy Zawodny

On Sun, May 05, 2002 at 07:42:13AM +0100, Alexander Shaw wrote:
 
 Using another machine (running windows) elsewhere on the network, is
 it possible to perform a mysqldump of the databases on the server?
 i.e. without having to go physically to the server machine and
 typing the commands at the command prompt.

Yes.  Just specify a hotsname using the -h host option to
mysqldump.

Jeremy
-- 
Jeremy D. Zawodny, [EMAIL PROTECTED]
Technical Yahoo - Yahoo Finance
Desk: (408) 349-7878   Fax: (408) 349-5454   Cell: (408) 685-5936

MySQL 3.23.47-max: up 86 days, processed 2,256,233,131 queries (301/sec. avg)

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

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




VC++ functions for mysql

2002-05-05 Thread Alexandru Coseru




Hello .
I'm a small VC++ programmer , and I have some problems with mysql c
functions.

What I wanna do , and I don't know how, it's to get an field value from a
table and put it in a char* or into an int

For instance , I have a small table , with two fileds
name char(50),
age int(40)


Another thing is to convert the number of the records into a long.

Now , using thoose routines from the documentation:




int main() {
  Connection con(my);
char * name=new char[50];
int age;
  Query query = con.query();

  query  select * from mytable;
  Result res = query.store();


//  cout  Records Found:   res.size()  endl  endl;
long records=res.size() : ?

  Row row;
  Result::iterator i;
  // The Result class has a read-only Random Access Iterator
  for (i = res.begin(); i != res.end(); i++) {
row = *i;
strcpy(name,row[name];
age=row[age];

// do something with name and age here

  }
delete name;
  return 0;
}



By running this example , my program crashes.

Why ?
And how can I do it right ?






Thanks
Alex
Coseru


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

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: VC++ functions for mysql

2002-05-05 Thread domi

If You're using VC++ so I recommend You to test run
Your app within VC++ IDE.
Then You can step through your code , line by line and
check for variables if they are what You think they are.
A very easy and effective way to find errors !!

---
=d0Mi= , DCS.net
[EMAIL PROTECTED]



 Original Message -
Date:  5-May-2002 14:44:47 +0200
From: Alexandru Coseru [EMAIL PROTECTED]
To:  [EMAIL PROTECTED]
Subject: VC++ functions for mysql

 
 
 
 Hello .
 I'm a small VC++ programmer , and I have some problems with mysql c
 functions.
 
 What I wanna do , and I don't know how, it's to get an field value from a
 table and put it in a char* or into an int
 
 For instance , I have a small table , with two fileds
 name char(50),
 age int(40)
 
 
 Another thing is to convert the number of the records into a long.
 
 Now , using thoose routines from the documentation:
 
 
 
 
 int main() {
   Connection con(my);
 char * name=new char[50];
 int age;
   Query query = con.query();
 
   query  select * from mytable;
   Result res = query.store();
 
 
 //  cout  Records Found:   res.size()  endl  endl;
 long records=res.size() : ?
 
   Row row;
   Result::iterator i;
   // The Result class has a read-only Random Access Iterator
   for (i = res.begin(); i != res.end(); i++) {
 row = *i;
 strcpy(name,row[name];
 age=row[age];
 
 // do something with name and age here
 
   }
 delete name;
   return 0;
 }
 
 
 
 By running this example , my program crashes.
 
 Why ?
 And how can I do it right ?
 
 
 
 
 
 
 Thanks
 Alex
 Coseru
 
 
 -
 Before posting, please check:
http://www.mysql.com/manual.php   (the manual)
http://lists.mysql.com/   (the list archive)
 
 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




AIX 5L binaries?

2002-05-05 Thread Viraj Alankar

Hello,

Are there any plans for releasing AIX 5L pre-compiled binaries? I notice there
are some MySQL RPMs available from other locations but they are not the latest
version.

If not, are there any pointers to AIX 5L compilation steps?

Viraj.

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

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: Get the next AUTO INCREMENT value for a column

2002-05-05 Thread Arthur Fuller

IMO the desire to know this answer suggests that something is wrong with the
design. Again IMO, a PK must be absolutely meaningless. Any attempt to
impost meaning on it is by definition wrong.

By my lights, the only PK you want to know is the one just added. That's
enough information to let you start adding rows to child tables. And that
value you can easily obtain.

Arthur

- Original Message -
From: Paul DuBois [EMAIL PROTECTED]
To: Harrison C. Fisk [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Saturday, May 04, 2002 12:34 PM
Subject: Re: Get the next AUTO INCREMENT value for a column


 At 12:29 -0400 5/4/02, Harrison C. Fisk wrote:
 Actually I think the  SHOW TABLE STATUS like 'TABLENAME' command can show
 you the next auto_increment value.

 There is no guarantee that this value will actually be used for the
 next AUTO_INCREMENT value.  Suppose another client issues the following
 query:

 ALTER TABLE tbl_name AUTO_INCREMENT = 123456;

 If you were relying on what SHOW TABLE STATUS said, you'd be hosed. :-)


 Although I can say I wouldn't really ever use it except for personal use,
 not in an actual application.
 
 Harrison
 - Original Message -
 From: Paul DuBois [EMAIL PROTECTED]
 To: Son Nguyen [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Sent: Saturday, May 04, 2002 12:16 PM
 Subject: Re: Get the next AUTO INCREMENT value for a column
 
 
   At 9:01 -0700 5/4/02, Son Nguyen wrote:
  CREATE table test1 (ID int NOT NULL AUTO INCREMENT, name text,
value
   text, Primary Key (ID));
   
  INSERT into test1 (name, value) values (test1, value1);
   
  INSERT into test1 (name, value) values (test2, value2);
   
  DELETE from test1 where ID=2;
   
  How can obtain the CURRENT value of next ID AUTO INCREMENT value
   (which is 3 right now)
   
   
   
   
Son Nguyen
   mysql, query
 
   You can't.  AUTO_INCREMENT values are not available until you generate
them.


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

 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: Simple Question relating to Indexing

2002-05-05 Thread Svensson, B.A.T. (HKG)

Why do you want to restrict the names to be unique? 


  //Anders - SQL, QUERY

-Original Message-
From: Shaun Bramley
To: Svensson, B.A.T. (HKG); [EMAIL PROTECTED]
Sent: 3-5-02 20:16
Subject: Re: Simple Question relating to Indexing

I'd like to first thank Carl and Anders for your quick and very
informative
answers.  I really appreciate it.

To get this staightened out, for a table specified by:

CREATE TABLE Player (
   PlayerID INT  NOT NULL PRIMARY KEY AUTO_INCREMENT,
   TeamID INT  NOT NULL,
   TrophyFlag TINYINT,
   RecordFlag TINYINT,
   LetterID TINYINT  NOT NULL,
   NameFirst char(15) NOT NULL,
   NameLast char(20) NOT NULL)


My primary key is obviously: playerid.

letterID, trophyflag, recordflag, and teamid can be foreign keys.  They
are
not configured so right now.
An index could be created based upon NameFirst and NameLast.  Which
would be
ok so long as there are not two people with the name John Smith (or
whatever)


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

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: Trouble with indexing

2002-05-05 Thread Donna Robinson

Hi Jeremy,

On Sunday 05 May 2002 5:52 am, Jeremy Zawodny wrote:
 REGEXP queries don't use indexes.  Change the:
  REGEXP ^A
 to
   LIKE A%
 and it'll use the index and give you a nice speed boost.

which indeed it did! I checked the manual (yet again) and it doesn't actually 
say anything about regexp not using indices (grr).  So I went thru the db fns 
and stripped out regexp and replaced with like.

BUT I have hit a snag on the last query to fix:
select dances.danceid as id, dancetitles.title from dances, dancetitles where 
dances.danceid=dancetitles.danceid and dances.has_crib='T' and 
dancetitles.title regexp ^[T-Z];

Despite multiple offerings of every perm and comb I can think of (and even 
rtfm) I can't persuade mysql to eat a like query which will return the same 
ans as the regexp one.  Am beginning to think am flogging a dead horse here?

Donna

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

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: installation problems on freebsd

2002-05-05 Thread Defryn NZ



Is /tmp/mysql.sock missing after you start the MySQL server using
`bin/safe_mysqld'?
  When I run bin/safe_mysqld I get the message that it is unable
to connect to 'hostname' through /tmp/mysql.sock and that it is missing

Cheers





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

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: installation problems on freebsd

2002-05-05 Thread Jeremy Zawodny

On Mon, May 06, 2002 at 08:12:30AM +1200, Defryn NZ wrote:
 
 
 Is /tmp/mysql.sock missing after you start the MySQL server using
 `bin/safe_mysqld'?

 When I run bin/safe_mysqld I get the message that it is unable to
 connect to 'hostname' through /tmp/mysql.sock and that it is missing

That's really strange.  Starting a MySQL server shouldn't ever result
in it attempting to contact itself via /tmp/mysql.sock.  It sounds
like something is rather messed up in your configuration.

Jeremy
-- 
Jeremy D. Zawodny, [EMAIL PROTECTED]
Technical Yahoo - Yahoo Finance
Desk: (408) 349-7878   Fax: (408) 349-5454   Cell: (408) 685-5936

MySQL 3.23.47-max: up 87 days, processed 2,267,702,000 queries (300/sec. avg)

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

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




Setup Initialisation Error

2002-05-05 Thread RACLBE

I am trying to install mysql on my home computer.  I teach Web Design at 
DeVry University and plan to use this database in my class.  The error 
message I get is Setup Initialisation Error Setup is unable to find 
installation languages in C:\mysql\setup.lid file and Error 105.  My next 
class is tomorrow night.  
Please Help!
Ray Bell (ValueWeb site ucantranscend.com)
DeVry University

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

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: Trouble with indexing

2002-05-05 Thread Jeremy Zawodny

On Sun, May 05, 2002 at 04:54:41PM +0100, Donna Robinson wrote:
 Hi Jeremy,
 
 On Sunday 05 May 2002 5:52 am, Jeremy Zawodny wrote:
  REGEXP queries don't use indexes.  Change the:
   REGEXP ^A
  to
LIKE A%
  and it'll use the index and give you a nice speed boost.
 
 which indeed it did! I checked the manual (yet again) and it doesn't
 actually say anything about regexp not using indices (grr).  So I
 went thru the db fns and stripped out regexp and replaced with like.

Great.

 BUT I have hit a snag on the last query to fix:

 select dances.danceid as id, dancetitles.title from dances,
 dancetitles where dances.danceid=dancetitles.danceid and
 dances.has_crib='T' and dancetitles.title regexp ^[T-Z];
 
 Despite multiple offerings of every perm and comb I can think of
 (and even rtfm) I can't persuade mysql to eat a like query which
 will return the same ans as the regexp one.  Am beginning to think
 am flogging a dead horse here?

That one isn't fixed as easily.  Since you've got multiple starting
places for the string, you can't use a simply LIKE query.  You might
be able to use a BETWEEN query:

  http://www.mysql.com/doc/C/o/Comparison_Operators.html

to help out.

dancetitles.title BETWEEN T AND  may be faster.  Give it a try
and see.

Jeremy
-- 
Jeremy D. Zawodny, [EMAIL PROTECTED]
Technical Yahoo - Yahoo Finance
Desk: (408) 349-7878   Fax: (408) 349-5454   Cell: (408) 685-5936

MySQL 3.23.47-max: up 87 days, processed 2,267,703,816 queries (300/sec. avg)

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

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




Re: Optimization

2002-05-05 Thread Rodrigo Pérez

Thanks Jay,
Actually what i want to do is much more simple. I want to have on the same
query result, the first 10 rows with this word and the total of rows from
the table with this specific word.

The result should be like a search engine page result. Has the total of
pages with that word and the first 10 results. I want to put it together in
only one query. Is it possible ?

SELECT COUNT(*) from TABLE where name=JOHN
SELECT * from TABLE where name=JOHN limit 10

Thanks,
Rodrigo
- Original Message -
From: Jay Blanchard [EMAIL PROTECTED]
To: 'Rodrigo Pérez' [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Friday, May 03, 2002 2:23 PM
Subject: RE: Optimization


 [snip]
 I want to optimize one of my php scripts to acess mysql only once. Is
there
 anyway to put these two queries together:

 SELECT COUNT(*) from TABLE where name=JOHN
 SELECT * from TABLE where name=JOHN limit 10
 [/snip]

 try

 select *,
 sum(if(name = 'JOHN', 1, 0)) AS COUNT
 from table
 where name = 'JOHN'
 group by name

 HTH!

 Jay



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

 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




3.23.50???

2002-05-05 Thread balteo

What's going on at Mysql??
When can we expect 3.23.50???
Balteo.

- Original Message -
From: Rodrigo Pérez [EMAIL PROTECTED]
To: 
Sent: Sunday, May 05, 2002 11:32 PM
Subject: Re: Optimization


 Thanks Jay,
 Actually what i want to do is much more simple. I want to have on the same
 query result, the first 10 rows with this word and the total of rows from
 the table with this specific word.

 The result should be like a search engine page result. Has the total of
 pages with that word and the first 10 results. I want to put it together
in
 only one query. Is it possible ?

 SELECT COUNT(*) from TABLE where name=JOHN
 SELECT * from TABLE where name=JOHN limit 10

 Thanks,
 Rodrigo
 - Original Message -
 From: Jay Blanchard [EMAIL PROTECTED]
 To: 'Rodrigo Pérez' [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Sent: Friday, May 03, 2002 2:23 PM
 Subject: RE: Optimization


  [snip]
  I want to optimize one of my php scripts to acess mysql only once. Is
 there
  anyway to put these two queries together:
 
  SELECT COUNT(*) from TABLE where name=JOHN
  SELECT * from TABLE where name=JOHN limit 10
  [/snip]
 
  try
 
  select *,
  sum(if(name = 'JOHN', 1, 0)) AS COUNT
  from table
  where name = 'JOHN'
  group by name
 
  HTH!
 
  Jay
 
 
 
  -
  Before posting, please check:
 http://www.mysql.com/manual.php   (the manual)
 http://lists.mysql.com/   (the list archive)
 
  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: Trouble with indexing

2002-05-05 Thread Donna Robinson

FilterFodder: sql, query

Yo Jeremy,

On Sunday 05 May 2002 9:31 pm, Jeremy Zawodny wrote:
 That one isn't fixed as easily.  ...
 You might be able to use a BETWEEN query:

(eyes raised to heaven, hands clasped in prayer)
o jeremy you are my hero!
(grin)

seriously, thanks a lot, i really appreciate your efforts on my behalf - all 
yr suggestions worked a treat.

stay well, stay cool

Donna

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

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




General error: Got error 12 from table handler on Linux.

2002-05-05 Thread Doron

Hi,

I got the above error when inserting a row into a heap table on linux
mySQL version 3.23.49a from the Java JDBC driver. This is not reproduceable
on a win32 DB. This does not appear to be space related as it failed after
only about 200 rows. Just wondering if anyone has seen this before?

  -Doron


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

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

2002-05-05 Thread support

Hello,

A real SQL-query works well
SELECT MAX(date_value) AS date_value FROM dates WHERE version_id='2'

But the problem is, that I can't get a value of another column, i.e.

the row in a table consists of three columns - id, date_value and
version_id

The task - to get a value of id column where date_value is the biggest
while version_id is preset

Thank you





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

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 on Load Data!

2002-05-05 Thread Jack

Dear all

Two Question :
1.
I know that the 'LOAD DATA' command loads a bulk of data into a table, but
what happen if i only want to load the data into specifc fields on a table
instead of whole table.

eg.
Let say i had a file with 3 column of data, and i want to load these data
into a 'ABC' table's field 3 to 5 and leave field 1  2 as it was!

2.
I copied a file into server's root directory, and i was trying to load that
file's data to table which i had failed using the following command in
MYSQL:
LOAD DATA infile 'c:\hkd_rate.csv' into table hkd_deposit1 fields
terminated by ',' 
It said couldn't find the file!
but if i put the file into the data directory of mysql, then it can find it!
So what should i do if i want mysql will able to find that file from root
directory?


--
Thx a lot!
Jack
[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




Cross server select into

2002-05-05 Thread Ewan Sadie

I have installed MySQL on two of my MS-Proxy servers. I am logging all
web browser logs to MySQL.
I want to replicate the database to a central server where I can do
queries on the data.  I do not want to run select statement agains the
proxy server itself.
How can I replicate the data to a different server (like with slave
master replication) and then delete the data on the proxy server,
without deleting it on the central server.
What I actually want to do is something like a selecy into but between
different server/databases.

I am evaluation MySQL and if I can get this right I will chuck out my
MS-SQL databases.

Ewan Sadie
_
 lose weight now! http://www.slimandtrim.biz

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

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




Problems with Time field

2002-05-05 Thread p j j

hi all,
 I am using mysql on Win98 platoform. Am facing problems 
using the Time field in SQL queries being executed from a VB 
program. Would it be possible for someone to help me out with 
this

At mysql prompt
1. CREATE TABLE TEST(field Time)    success
2. INSERT INTO TEST(field) VALUES ('11:00:00')-- 
success
3. SELECT * FROMTEST  --- success
11:00:00

But from a VB program - the first two queries get executed 
successfully ;
  the values were checked from mysql prompt  has 
been entered successfully

But the 3rd query (SELECT) when executed from the VB program 
returns a result set of Null.

kindly help

Praveen
_
Click below to visit monsterindia.com and review jobs in India or 
Abroad
http://monsterindia.rediff.com/jobs


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

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

2002-05-05 Thread Harrison C. Fisk

If you only want to get the Max or min of a single row, then you should try
something like:
SELECT date_value, version_id FROM dates WHERE version_id=2 ORDER BY
date_value DESC LIMIT 1;

However if there might be two of the rows with the highest you will need to
use either a max-concat trick or table locking to accomplish this in MySQL.
This is detailed at:
www.mysql.com/doc/e/x/example-Maximum-column-group-row.html

Hope that helps some.

Harrison

- Original Message -
From: support [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, May 06, 2002 12:25 AM
Subject: SQL-query


 Hello,

 A real SQL-query works well
 SELECT MAX(date_value) AS date_value FROM dates WHERE version_id='2'

 But the problem is, that I can't get a value of another column, i.e.

 the row in a table consists of three columns - id, date_value and
 version_id

 The task - to get a value of id column where date_value is the biggest
 while version_id is preset

 Thank you





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

 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: Cross server select into

2002-05-05 Thread Sven Bentlage

I am not sure on this one, since I am new to mysql myself.
But how about just entering the appropriate information on the other 
host before the database name
i.e. hostname.databasename.tablename
  Don't know how or where to privide the user name/pw for tthe 2nd. 
server though.

It's just an idea from a newbie, so do not put too much trust in it :)

Sven

On Monday, May 6, 2002, at 02:44 PM, Ewan Sadie wrote:

 I have installed MySQL on two of my MS-Proxy servers. I am logging all
 web browser logs to MySQL.
 I want to replicate the database to a central server where I can do
 queries on the data.  I do not want to run select statement agains the
 proxy server itself.
 How can I replicate the data to a different server (like with slave
 master replication) and then delete the data on the proxy server,
 without deleting it on the central server.
 What I actually want to do is something like a selecy into but between
 different server/databases.

 I am evaluation MySQL and if I can get this right I will chuck out my
 MS-SQL databases.

 Ewan Sadie
 _
  lose weight now! http://www.slimandtrim.biz

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

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




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

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




Re: Cross server select into

2002-05-05 Thread Dicky Wahyu Purnomo

On Mon, 6 May 2002 07:44:04 +0200
Ewan Sadie [EMAIL PROTECTED] wrote:

 I have installed MySQL on two of my MS-Proxy servers. I am logging all
 web browser logs to MySQL.
 I want to replicate the database to a central server where I can do
 queries on the data.  I do not want to run select statement agains the
 proxy server itself.
 How can I replicate the data to a different server (like with slave
 master replication) and then delete the data on the proxy server,
 without deleting it on the central server.
 What I actually want to do is something like a selecy into but between
 different server/databases.
 
 I am evaluation MySQL and if I can get this right I will chuck out my
 MS-SQL databases.

From my experience, I can tell you this :

Master -- Slave
Replication

Every query that change the data on master will be replicated on slave.

But I think you can try this :
binlog-db : DB_A
biglog-ignore-db : DB_B

DB_A is the database which will be replicated.

you can do the delete query with using DB_B database,
e.g. : use DB_B; delete from table DB_A.Table_A;

Correct me if i'm wrong ... ;-) 

-- 
We are using Linux daily to UP our productivity - so UP yours!
-- Adapted from Pat Paulsen by Joe Sloan

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

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