Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Database > Oracle
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Oracle General Oracle database discussions.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Oracle section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old July 31st, 2004, 03:35 AM
Authorized User
 
Join Date: Jul 2003
Location: , , .
Posts: 62
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to show 24 Hour Time?

I have a table name db,it's struct is follows:
SYS_DATE DATE
It contains a value "2004-7-31 15:41:48"

Then I want to show it,I use follow statement:
select to_char(sys_date,'YYYY-MM-DD HH:MM:SS') from db

But result is "2004-7-31 03:41:48",not "2004-7-31 15:41:48"
How to make result is "2004-7-31 15:41:48"?

Thanks in advance!

Reply With Quote
  #2 (permalink)  
Old July 31st, 2004, 04:44 AM
Registered User
 
Join Date: Apr 2004
Location: , Maharashtra, India.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to amolkataria
Default

Hi Edward,
 Try using,
   select to_char(sys_date,'YYYY-MM-DD HH24:MM:SS') from db;
 HH24 will show the time in 24 Hour format.


Amol.

Amol N. Kataria
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Hour by Hour Matrix Report Ed_Conde BOOK: Professional SQL Server 2005 Reporting Services ISBN: 0-7645-8497-9 0 August 12th, 2008 02:51 PM
8th BME International 24-hour Programming Contest! challenge24 Visual C++ 1 February 12th, 2008 01:35 PM
using format-time to extract hour pcase XSLT 2 December 18th, 2007 11:57 AM
show date/time in a datagrid. mehmetned C# 2005 0 March 23rd, 2007 08:43 AM
Add Column to Show Time KennethMungwira ADO.NET 1 December 2nd, 2003 11:30 AM



All times are GMT -4. The time now is 12:58 AM.


Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.