test

2003-08-20 Thread Fabrizio Tivano

sorry this is only a test.



query MySQL 

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



MySQL 3.23.54 + update

2003-08-06 Thread Fabrizio Tivano

Hello dear all, 

i have 2 table :tbl1 and tbl2

i need to make an update on tbl1 based from tbl2 records.

Ex:
update tbl1, tbl2 set tbl1.conf='1' where tbl2.name='AD' and tbl2.date=tbl1.date;

mysql: MySQL 3.23.54 


i see this kind of query works on mysql 4.0.2
How i can do this with my version?
I also tried with left joins ...but...noways!

Any ideas?

thanks in advances and regards, 

fabrizio

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: alter date

2003-08-05 Thread Fabrizio Tivano
On Tue, 5 Aug 2003 11:41:21 -0300 
Fabio Bernardo [EMAIL PROTECTED] wrote:

 Hi there, 
 Do you know a sql command which I can write to obtain the last date that I
 updated a table 
 

SHOW TABLE STATUS LIKE 'yourtable';


fabrizio

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



possible query #2

2003-07-02 Thread Fabrizio Tivano

Hello dear all,

on MySQL 3.23.54
i have a table that list the number of  user-time days like:  35 

whellbased on curdate() function 

can i able to make a select wich display  the sum (150-35)
where 150 is date_format(curdate(), '%j')
in a format like (%d/%m/%y) ?

this kind of query is possible? 
...if yes how?

...or there is only a madness? :)

thanks in advance, 
fabrizio

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



possible query?

2003-06-10 Thread Fabrizio Tivano

hello dear all, 

i need to make a select on mysql with IF funcion:

if ('stop' 'start', stop, '+++')

where start and stop are timestamps.
and [+++] is an error char.


Actually my select result are:


+--++
| data | start | stop   |
+--+---++
| 20030301 | 74621 |+++ |
| 20030302 | 74840 | 181211 |


but i have a question:

Is possible, and if yes how, 
to make so that query generate a result like:


+--++
| data | start | stop   |
+--+---++
| 20030301 | 74621 |0020 +++ |
| 20030302 | 74840 | 181211 |

where: if the stop time is  (less than) start time
i can print stop time and error char together.



Thanks in advance !

fabrizio

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



Re: possible query?

2003-06-10 Thread Fabrizio Tivano

Mikhail, Rich:

it work! 
thanks again 

fabrizio

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]



mysql replication

2003-01-30 Thread Fabrizio Tivano

You have written the following:

Hello dear all, 


i try to set-up replication,

i've configurated master and slave, 
and on the slave-side i see this log:


030130 17:22:41  Slave: Failed reading log event, reconnecting to retry, log 'FIRST' 
position 35
030130 17:22:41  Slave: reconnected to master 'test@master:3306',replication resumed 
in log 'FIRST' at position 35
030130 17:22:41  Slave: received 0 length packet from server, apparent master 
shutdown:  (0)

my sql version: MySQL 3.23.39

any ideas?

T.I.A.


fabrizio

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

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: updating tables

2003-01-24 Thread Fabrizio Tivano
Stefan, 

The problem look be solved;

i've just changed structure of the updatable table.
First this table have only 1 primary key, now my table have some indexed unique keys.

and now if i do a replace into command look's like to work fine.

I have just a question:

i need also to change structure of the master table (have only a primary key)  or 
the changes made on the updatable_table  are enough?


regards, 
fabrizio


On Fri, 24 Jan 2003 00:10:19 +0100
Stefan Hinz, iConnect \(Berlin\) [EMAIL PROTECTED] wrote:

 Fabrizio,
 
 please send the table structures of table_1 and table_2 (DESCRIBE ...)
 so we can do more for you than just guess what the problem might be.
 
 REPLACE seems good in the first place, but if it just INSERTs then
 there's a problem with the (primary) keys.
 
 Regards,
 --
   Stefan Hinz [EMAIL PROTECTED]
   Geschäftsführer / CEO iConnect GmbH http://iConnect.de
   Heesestr. 6, 12169 Berlin (Germany)
   Tel: +49 30 7970948-0  Fax: +49 30 7970948-3
 
 - Original Message -
 From: Fabrizio Tivano [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Thursday, January 23, 2003 5:22 PM
 Subject: updating tables
 
 
 
  hello dear all,
 
  i have a problem updating tables:
 
  in my queries i try to use REPLACE but  is same like INSERT command.
 
  ...i need only to refresh table_1 with  new entries from table_2.
 
  any ideas?
 
  TIA
   fabrizio
 
  -
  Before posting, please check:
 http://www.mysql.com/manual.php   (the manual)
 http://lists.mysql.com/   (the list archive)
 
  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
 


-- 
Fabrizio Tivano
WAN System Administrator
SAD Trasporto Locale S.p.a.
 Corso Italia 13/N
 39100 BOLZANO

 e-mail : [EMAIL PROTECTED]
 Tel: +390471450268
 Fax: +390471450253

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

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




updating tables

2003-01-23 Thread Fabrizio Tivano

hello dear all, 

i have a problem updating tables:

in my queries i try to use REPLACE but  is same like INSERT command.

...i need only to refresh table_1 with  new entries from table_2.

any ideas?

TIA
 fabrizio

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

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




strange or impossible query?

2002-06-07 Thread Fabrizio Tivano



Hello dear all, 


i have a table like this:

field_machine, field_date, field_time, field_function.

field_function can be =TT or +BT

well i need to perform a select query, witch display on one line

field_machine, 
(field_date, field_time where field_function =TT) AS start, 
(field_date, fiel_time where field_function =BT) AS stop from table;




is possible to do that?
...and if yes, how?

thanks in advance and Regards,

fabrizio

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

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