Is it possible to enter only time value into a column of a
table in sql?
Answer Posted / nannesaheb c
There is no such data type is existed in Oracle to store the time in a column directly.
However we can insert the time value in a column using the sql functions as below.
SELECT substr(to_char(sysdate,'DD-MON-YYYY HH:MM:SS'),12,20) FROM dual;
create table time1
(
today_time varchar2(10)
);
insert into time1 values(substr(to_char(sysdate,'DD-MON-YYYY HH:MM:SS'),12,20));
Regards,
Nanne
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How to create a new view in oracle?
How to update values on multiple rows in oracle?
How to create a new user account in oracle?
Explain how you would restore a database using RMAN to Point in Time?
What are the ways tablespaces can be managed and how do they differ?
An automatic job running via DBMS_JOB has failedKnowing only that its failed, how do you approach troubleshooting this issue?
How to rebuild an index in oracle?
What is the difference between hot backup and cold backup in oracle? Tell about their benefits also.
What is bulk load in oracle?
What is program global area (pga) in oracle?
How to connect the oracle server as sysdba?
What is connection pool in oracle?
How many categories of data types in oracle?
Can we store images in oracle database?
What is SQL access advisor in Oracle?