You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: 20190829125347_populate_labware_table.rb
    path of file: ./repos/sequencescape/db/migrate
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

# Duplicated
    
  def up # rubocop:disable Metrics/AbcSize
    ActiveRecord::Base.connection.execute('SET autocommit = 0')
    ActiveRecord::Base.connection.execute('SET unique_checks = 0')
    ActiveRecord::Base.connection.execute('SET foreign_key_checks = 0')

    ActiveRecord::Base.connection.execute(<<~SQLQUERY)
      INSERT labware (
             id, name, sti_type, size, public_name, two_dimensional_barcode,
             plate_purpose_id, labware_type_id, created_at, updated_at)
      SELECT id, name, sti_type, size, public_name, two_dimensional_barcode,
             plate_purpose_id, labware_type_id,
             IFNULL(created_at,updated_at) AS created_at, updated_at
      FROM assets
      WHERE sti_type != "Well"
    SQLQUERY

    ActiveRecord::Base.connection.execute('COMMIT')
    ActiveRecord::Base.connection.execute('SET autocommit = 1')
    ActiveRecord::Base.connection.execute('SET unique_checks = 1')
    ActiveRecord::Base.connection.execute('SET foreign_key_checks = 1')
    ActiveRecord::Base.connection.execute('ANALYZE TABLE labware')
  end