plsql_function_insert1.htm |
Objectives :
PL/pgSQL : |
A screen shot showing the list of tables before adding the new table. |
A table , named "emp2", was created as shown below. |
Creating and compiling a function :
|
SQL-Scripts to insert values in the table named "emp2": |
pgsdemo1=#
select * from MyInsert(1,'John','Doe','Manager',20,'1995-04-14','2013-04-04',30000,1500); Querying the table "emp2" : |
Querying the table "emp2", using PHP script over a
web-browser: |
Inserting data using PHP Query Tool: select * from MyInsert(2,'Peter','Pan','Manger',20,'2013-01-24','2019-01-04',30000,1500) |
Now Update Salary UPDATE EMP2 SET salary = 95000 where salary = 30000 |