I'm using activerecord-import gem to import many records in one DB insert, in the same project I'm using apartment gem to create and use multi postgres schemas and switch between many schemas realtime ...
the issue is sometimes after import records, will be conflict in unique records ids!
ActiveRecord::RecordNotUnique: PG::UniqueViolation: ERROR: duplicate key value violates unique constraint "table_name_" DETAIL: Key (id)=(43) already exists.
this conflict only happening by using active-record import gem ...