TO insert 969 rows into table

Hi all

I have a table emp with columns empno,ename,job,mgr

how do i insert 969 records into the table emp

presently i am using this way of insert

insert into emp(empno,ename,job,mgr) values (&empno,’&ename’,’&job’,&mgr);

could anyone please guide me to insert 969 rows of data to the emp table.

i am using TOAD

Thanking in advance

On 07/08/13 09:52, makdutakdu wrote:

I have a table emp with columns empno,ename,job,mgr
how do i insert 969 records into the table emp
presently i am using this way of insert
insert into emp(empno,ename,job,mgr) values (&empno,'&ename','&job',&mgr);

could anyone please guide me to insert 969 rows of data to the emp table.
Where do these new rows of data come from? You are able to use Toad to load data into a table from Excel, for example. You can also set up a SQLLoader control file, within Toad, to load the data from something like a CSV file, if that is where the data are to be found.
If yo simply have a list of names etc to insert, then you probably need a little scripting (in Windows notepad or similar) to take the list and massage it into a format that will run as an SQL command.
You are, I suspect fed up running the same command and having to fill in all the values you wish to insert?
Create a script like the following and run it using F5 rather than F9:
insert into emp (empno,ename,job,mgr)
values (1234, 'Norm', 'DBA', 'Manager name');
insert into emp (empno,ename,job,mgr)
values (1235, 'makdutakdu', 'Developer', 'Manager name');
And so on. Unfortunately you will need to build this manually - unless yo have a file that can be loaded via SQL
Loader or an excel table etc that Toad can read in for you.
HTH
-- Cheers,
Norm. [TeamT]