Oracle Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsDatabasesOracle Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
SlickEdit: Code in over 40 languages across 7 platforms. SlickEdit’s unmatched power, speed, and flexibility allows even the most accomplished developers to write better code faster. Download a free trial today!
  #1  
Old June 19th, 2004, 11:34 PM
rafi_aamiri rafi_aamiri is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2004
Posts: 5 rafi_aamiri User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Exclamation Storing Date and Time through Forms 6i

Hai,

I want to store date and time in a table through oracle forms 6i. I am able to store the date but not the time.

I tried to set the date and time in the oracle form but while commiting the form only the date part is stored in the table and not the time part.

Please help me in this regard.

Thanks and Regards,

A.Mohammed Rafi Aamiri.
E-Mail : rafi_amr@yahoo.com

Reply With Quote
  #2  
Old June 20th, 2004, 08:54 AM
jim mcnamara jim mcnamara is offline
......@.........
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Jun 2004
Posts: 1,307 jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 1 Week 3 Days 4 h 28 m 57 sec
Reputation Power: 48
Assuming:
The datatype of the field in the table is DATE, we'll call it
the table MYTABLE and the field MYDATE.

The dataype you are using in Forms is either VARCHAR2 or DATE.

What do you get when you do this?:
Code:
SELECT TO_CHAR(MYDATE,'MON-DD-YYYY HH:MM')
from MYTABLE;


What does your insert statement look like?

Reply With Quote
  #3  
Old June 20th, 2004, 10:29 PM
rafi_aamiri rafi_aamiri is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2004
Posts: 5 rafi_aamiri User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Quote:
Originally Posted by jim mcnamara
Assuming:
The datatype of the field in the table is DATE, we'll call it
the table MYTABLE and the field MYDATE.

The dataype you are using in Forms is either VARCHAR2 or DATE.

What do you get when you do this?:
Code:
SELECT TO_CHAR(MYDATE,'MON-DD-YYYY HH:MM')
from MYTABLE;


What does your insert statement look like?


In the table the datatype of the column is DATE.

I want to store both date and time in the column through Oracle Forms 6i.

I am able to store the date but the time part is not able to sotre. Also I am using Commit_Form procedure to store the values in the table.

Reply With Quote
  #4  
Old June 21st, 2004, 09:14 AM
jim mcnamara jim mcnamara is offline
......@.........
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Jun 2004
Posts: 1,307 jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 1 Week 3 Days 4 h 28 m 57 sec
Reputation Power: 48
I'm not communicating with you very well.
Get into SQLPLUS. I do not know the name of your table or the column that stores the date
Code:
SELECT TO_CHAR(MYDATE,'MON-DD-YYYY HH:MM')
from MYTABLE;


what do you see? In other words, paste the result of this so I can see it, too.

Reply With Quote
  #5  
Old June 25th, 2004, 06:47 AM
RJR RJR is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2004
Posts: 4 RJR User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
hello,
try

select to_date('24.12.2004 13:42','DD.MM.YYYY hh24:mi') from dual;

you can play whith that.
"to_date" converts the string to date.
So you cann make

insert into yourtable column1, .... values (to_date('24.12.2004 13:42','DD.MM.YYYY hh24:mi'), .....;

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesOracle Development > Storing Date and Time through Forms 6i


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway