Giả sử chúng ta có table data_temp (id, data, date_time)
create table data_temp(id number, data varchar2(100), date_time date);
-- insert row bulk DECLARE -- khai bao bien la cac gia tri can chen vao bang v_value1 NUMBER; v_value2 VARCHAR2(100); v_value3 DATE; BEGIN -- lap lai so luong lan FOR i IN 1..1000000 LOOP -- gan gia tri cho bien v_value1 := i; v_value2 := 'Value ' || TO_CHAR(i); v_value3 := to_date(SYSDATE,'yyyy-mm-dd hh24:mi:ss'); -- Thuc hien lenh INSERT INSERT INTO data_temp (id, data, date_time) VALUES (v_value1, v_value2, v_value3); END LOOP; -- Commit gia tri COMMIT; END; /