Question

use SQL to answer the question. Create two tables and insert atleast 7 or 8 values(whatever...

use SQL to answer the question.

Create two tables and insert atleast 7 or 8 values(whatever you want) into each of these two tables

1) Person
2) Favorite food

I need every step-codes such as :
SQL> connect admin/admin as sysdba;
SQL> create table products_tb1
2 (prod_id integer primary key,
3 prod_desc char(30),
4 cost real);
SQL> insert into products_tb1 values(11235, 'WITCH COSTUME', 29.99);
SQL> insert into products_tb1 values(222, 'PLASTIC PUMKIN 18 INCH', 7.75);
SQL> insert into products_tb1 values(13, 'FALSE PARAFFIN TEETH', 1.1);
SQL> insert into products_tb1 values(90, 'LIGHTED LANTERNS', 14.5);
SQL> select*from products_tb1;
0 0
Add a comment Improve this question Transcribed image text
Answer #1

Code

create table Person
(name varchar2(10) primary key,
age number(2),
weight number(3),
city varchar2(15))

insert into Person values('Jay',29,65,'Bhuj');
insert into Person values('Ajay',22,100,'Bhuj');
insert into Person values('Viay',24,52,'Gandhidham');
insert into Person values('Srujay',29,77,'NY');
insert into Person values('Sanay',55,41,'London');
insert into Person values('Dhanjay',24,89,'Perth');
insert into Person values('Mrunt',66,55,'Mumbai');
insert into Person values('Viral',29,80,'Kampala');


create table Favorite_food
(fid varchar2(5) primary key,
fname varchar2(15),
price number(3));

insert into Favorite_food values ('F101','Chocolate',10);
insert into Favorite_food values('F102','Icecream',10);
insert into Favorite_food values('F103','Nuts',20);
insert into Favorite_food values('F104','Pani puri',10);
insert into Favorite_food values('F105','Apple',55);
insert into Favorite_food values('F106','Weffer',50);
insert into Favorite_food values('F107','Chiken',100);
insert into Favorite_food values('F108','Egg',10);

output

Run SQL Command Line Copyright (c) 1982 214, Oracle All rights reserved SQL> connect Enter user-name: cystem/admin ERROR: ORARun SQL Command Line SQL> insert into Person values(Viral,29,8e, Kampala) 1 row created SQL> insert into Person values(MrRun SQL Command Line SQL> create table Favorite food 2 (fid varchar2(5) primary key 3 fname varchar2(15), 4 price number(3))Run SQL Command Line SQL> selectfrom person; NAME AGE 29 24 WEIGHT CITY 65 Bhuj Day Ajay Viay Srujay Sanay Dhanjay Viral MrunIf you have any query regarding the code please ask me in the comment i am here for help you. Please do not direct thumbs down just ask if you have any query. And if you like my work then please appreciates with up vote. Thank You.

Add a comment
Know the answer?
Add Answer to:
use SQL to answer the question. Create two tables and insert atleast 7 or 8 values(whatever...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT