Want to know insert into [message #678407] |
Sat, 30 November 2019 17:37 |
|
kabina
Messages: 8 Registered: November 2019
|
Junior Member |
|
|
What I believe insert command just like append command in MS access. In access you need to create table stricture then you use append command to insert data as your need.
I got access back-end tables of oracle but have no permission to create table or temp table structure. I have following question in mind if you could solve. if we cannot create table or table structure then if we want to insert some data how can we do that ?
Let say
select t.empid, t.empname, t.dept, sum(t.sal)
from
(Select empid, empname, dept, sal from tblemployee) t
group by t.empid, t.empname, t.dept;
I have another query which added new 5 UKemployee
Select empid, empname, dept and sal from UKemplayee
I want to insert these 5 uk employees detail in my first query.
one possible solution is that
select t.empid, t.empname, t.dept, sum(t.sal)
from
(Select empid, empname, dept, sal from tblemployee) t
group by t.empid, t.empname, t.dept;
union all
Select empid, empname, dept and sal from UKemplayee
it looks stupid but I want to clear my mind if I am unable to create table, if you want to insert few more lines in my final result. what is the best solution for that.
can we you use insert into command in sql query with making table structure ?
Thanks in advance.
[Updated on: Sat, 30 November 2019 17:38] Report message to a moderator
|
|
|
|
|
Re: Want to know insert into [message #678421 is a reply to message #678408] |
Sun, 01 December 2019 20:13 |
|
kabina
Messages: 8 Registered: November 2019
|
Junior Member |
|
|
EdStevens wrote on Sat, 30 November 2019 20:01This looks like a follow-on to one of your previous threads.
I dare say that nothing you learned about databases from Access will apply to Oracle. Most heavyweight DBA's don't even consider Access to be a real rdbms, but just a toy.
If you want to know how to insert rows into an oracle database, you should start with the SQL Reference, particularly the section on the INSERT statement. It is quite normal to INSERT without a CREATE TABLE statement.
Thank you very much.
|
|
|