I have one table name abc which has the records above 100 crores data. I am using this table in the procedure pqr where I am performing following operation in this table:
1) select count
2) Delete
3) Insert
When I execute this procedure from my UI, ideally only one record should get inserted. But 4 records get inserted. I dont know why is this happening. As well as lot of time is taken to run the procedure. According to me time is taken because of select count, Delete operation, but because of these the insert is perform many times in stored procedure.