Hello.


The first thing which comes to mind (I didn't dig really deep) looks like:



select convert_tz(cast(from_unixtime(cast(t as binary)) as datetime),'+00:00',

'-07:00') from tvar;



mysql> show create table tvar;

+-------+---------------------------------------------------------------------------------------------+

| Table | Create Table                                                          
                      |

+-------+---------------------------------------------------------------------------------------------+

| tvar  | CREATE TABLE `tvar` (

  `t` varchar(20) default NULL

  ) ENGINE=MyISAM DEFAULT CHARSET=latin1 |

  +-------+-------------------------------------



mysql> select * from tvar;

+------------+

| t          |

+------------+

| 1100273311 |

+------------+







Rafal Kedziorski <[EMAIL PROTECTED]> wrote:

> hi,

> 

> I store in a column (varchar(20)) milliseconds. How can I format the value 

> in a select statement to right timezone?

> 

> 

> Regards,

> Rafal

> 

> 



-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.NET http://www.ensita.net/
   __  ___     ___ ____  __
  /  |/  /_ __/ __/ __ \/ /    Gleb Paharenko
 / /|_/ / // /\ \/ /_/ / /__   [EMAIL PROTECTED]
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.NET
       <___/   www.mysql.com




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

Reply via email to