Hi
I have a table emp as the following:-
SQL> desc emp
Name Null? Type
----------------------------------------- -------- ----------------------------
EMPLOYEE_ID NUMBER(6)
SALARY NUMBER(8,2)
STARS VARCHAR2(50)
I want to create a PL/SQL block that inserts an asterisk in the stars coulmn for every
employee's salary that more than $1,000 .
So I have written this code
SQL> declare
2 sal emp.salary%type;
3 begin
4 while sal > 1000 loop
5 insert into emp(stars) values('*');
6 end loop;
7 end ;
8 /
PL/SQL procedure successfully completed.
But no asterisk entered
SQL> select * from emp where stars is not null;
no rows selected
Any help please.