i have one table emp.i did range partition on that table based on the emp id.

i did 4 partitions like

p5 range 1-5
p10 range 6-10
p15 range 11-15
p20 range 16-20

now i want to insert 21st employee information.but i did partition upto 20 employee's only.

so my question is

for 21st employee it should check whether partition exist for 21st emp id or not.if not i want to create a patition with range 5.

so how to write it