"Executing queries that use periodic commit in an open transaction is not possible

This error, "Executing queries that use periodic commit in an open transaction is not possible", shows up whenever the .csv file has less than 1000 number of rows. Take out the periodic commit and it runs smoothly.

There was a similar post: Error while import