Gossamer Forum
Home : Products : DBMan SQL : Discussion :

Date format, DBMAN 2.0/SQL

Quote Reply
Date format, DBMAN 2.0/SQL
I have defined a date fileld i mysql. Output at the webpage looks like this:
2001-11-30

I want to skip 2001 (entierly) from the database, and display the result like this on the webpage: 30.11.

How do I do this?
..........................
Kjetil Palmquist
www.svanger.com
Quote Reply
Re: [kjetilpa] Date format, DBMAN 2.0/SQL In reply to
You can use regex

my @date = split /-/, $rec{Date_Field};
shift @date;
$rec{Date_Field} = join '.', reverse @date;

Thanks the long way I guess :)


Last edited by:

PaulW: Dec 3, 2001, 8:28 AM