Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

a couple of sql create problems

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
Hi these should be quite easy for you!
How can I view a table once I have created it in sql, or do i need to insert some data into it??

Also is there a time function so a time appears as 22:30 ??

Thanks for any help, andy
 
Hi,

could you just explain your sql problem a bit more in detail? maybe you'd better add the code...

about your time problem - don't we all have one - : try

format(time,"hh:mm")

the kid



 
basically I have created some tables and i want to view them (ie the layout of the headers.
 
I have tried that time format and it comes up with this error message

SQL> create table repair_request
2 (RequestRef char(7) not null,
3 CustNo number(6) not null,
4 ContractNo number(6) not null,
5 CallTakenBy char(2) not null,
6 RequestDate date not null,
7 EquipmentType char(15) not null,
8 Fault char (30) not null,
9 Engineer char(20),
10 Model char(20) not null,
11 Make char(20) not null,
12 ArrivalDate date,
13 ArrivalTime format(time,"hh:mm"),
14 Hours number(2),
15 Labour number(4),
16 primary key (RequestRef),
17 foreign key (CustNo) references customer (CustNo));
ArrivalTime format(time,"hh:mm"),
*
ERROR at line 13:
ORA-00907: missing right parenthesis
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top