Pages

Insert values into table salesman

There are two ways in which we can insert the values in any table.

INSERT INTO SALESMAN VALUES(1001,'PIYUSH','LONDON',.12);

And the second way is

INSERT INTO SALESMAN VALUES(&SNUM,'&SNAME','&CITY',&COMMISSION);

This will generate the following output:-
Enter value for snum: 1001
Enter value for sname: PIYUSH
Enter value for city: LONDON
Enter value for commission: .11

and the insert the following value

SNUM SNAME          CITY              COMMISSION
--------------------------------------------------------  
    1001 PIYUSH        LONDON            12%
    1002 NIRAJ           SURAT                 13%
    1003 MITI              LONDON            11%
    1004 RAJESH        BARODA            15%
    1005 ANAND        NEW DELHI       10%
    1006 RAM              PATAN                  10%
    1007 LAXMAN     BOMBAY              09%

No comments:

Post a Comment