(111.2ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (0.3ms) select sqlite_version(*)  (97.5ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version") ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to CreateBillingAccounts (20140717180443)  (0.2ms) begin transaction  (0.9ms) CREATE TABLE "billing_accounts" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "billable_id" integer, "billable_type" varchar(255), "created_at" datetime, "updated_at" datetime)  (0.3ms) CREATE INDEX "index_billing_accounts_on_billable_id_and_billable_type" ON "billing_accounts" ("billable_id", "billable_type") SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140717180443"]]  (129.4ms) commit transaction Migrating to CreateBillingCharges (20140717181134)  (0.2ms) begin transaction  (0.8ms) CREATE TABLE "billing_charges" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "account_id" integer, "chargable_id" integer, "chargable_type" varchar(255), "price_cents" integer DEFAULT 0 NOT NULL, "price_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.4ms) CREATE INDEX "index_billing_charges_on_account_id" ON "billing_charges" ("account_id")  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'   (0.5ms) CREATE INDEX "index_billing_charges_on_chargable_id_and_chargable_type" ON "billing_charges" ("chargable_id", "chargable_type") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140717181134"]]  (121.9ms) commit transaction Migrating to CreateBillingDiscounts (20140717181406)  (0.2ms) begin transaction  (0.8ms) CREATE TABLE "billing_discounts" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "account_id" integer, "charge_id" integer, "percent_ratio" decimal(6,3), "created_at" datetime, "updated_at" datetime)  (0.5ms) CREATE INDEX "index_billing_discounts_on_account_id" ON "billing_discounts" ("account_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140717181406"]]  (100.2ms) commit transaction Migrating to CreateBillingPayments (20140717183129)  (0.2ms) begin transaction  (0.9ms) CREATE TABLE "billing_payments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "account_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime)   (0.4ms) CREATE INDEX "index_billing_payments_on_account_id" ON "billing_payments" ("account_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140717183129"]]  (100.1ms) commit transaction Migrating to CreateBillingOrigins (20140717202527)  (0.2ms) begin transaction  (0.8ms) CREATE TABLE "billing_origins" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140717202527"]]  (103.3ms) commit transaction Migrating to CreateProfiles (20140718104656)  (0.2ms) begin transaction  (0.7ms) CREATE TABLE "profiles" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "created_at" datetime, "updated_at" datetime) SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140718104656"]]  (86.1ms) commit transaction Migrating to AddSumariesToBillingAccount (20140718164841)  (0.2ms) begin transaction  (0.9ms) ALTER TABLE "billing_accounts" ADD "charges_sum_cents" integer DEFAULT 0 NOT NULL  (0.5ms) ALTER TABLE "billing_accounts" ADD "charges_sum_currency" varchar(255) DEFAULT 'USD' NOT NULL  (0.5ms) ALTER TABLE "billing_accounts" ADD "discounts_sum_cents" integer DEFAULT 0 NOT NULL  (0.6ms) ALTER TABLE "billing_accounts" ADD "discounts_sum_currency" varchar(255) DEFAULT 'USD' NOT NULL  (0.7ms) ALTER TABLE "billing_accounts" ADD "payments_sum_cents" integer DEFAULT 0 NOT NULL  (0.6ms) ALTER TABLE "billing_accounts" ADD "payments_sum_currency" varchar(255) DEFAULT 'USD' NOT NULL  (0.6ms) ALTER TABLE "billing_accounts" ADD "total_cents" integer DEFAULT 0 NOT NULL  (0.6ms) ALTER TABLE "billing_accounts" ADD "total_currency" varchar(255) DEFAULT 'USD' NOT NULL  (0.5ms) ALTER TABLE "billing_accounts" ADD "balance_cents" integer DEFAULT 0 NOT NULL  (0.5ms) ALTER TABLE "billing_accounts" ADD "balance_currency" varchar(255) DEFAULT 'USD' NOT NULL SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140718164841"]]  (100.6ms) commit transaction Migrating to AddFixedValueToBillingDiscount (20140718210349)  (0.1ms) begin transaction  (0.5ms) ALTER TABLE "billing_discounts" ADD "fixed_value_cents" integer DEFAULT 0 NOT NULL  (0.3ms) ALTER TABLE "billing_discounts" ADD "fixed_value_currency" varchar(255) DEFAULT 'USD' NOT NULL SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140718210349"]]  (73.4ms) commit transaction Migrating to CreateBillingPaymentTypes (20140718212116)  (0.1ms) begin transaction  (0.5ms) CREATE TABLE "billing_payment_types" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "cash" boolean, "fiscal" boolean, "created_at" datetime, "updated_at" datetime) SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140718212116"]]  (92.5ms) commit transaction Migrating to CreateBillingTaxGroups (20140719094023)  (0.2ms) begin transaction  (0.7ms) CREATE TABLE "billing_tax_groups" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140719094023"]]  (101.2ms) commit transaction Migrating to CreateBillingPlus (20140719094033)  (0.1ms) begin transaction  (0.5ms) CREATE TABLE "billing_plus" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140719094033"]]  (112.1ms) commit transaction Migrating to CreateBillingProfiles (20140719094418)  (0.2ms) begin transaction  (1.1ms) CREATE TABLE "billing_profiles" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "created_at" datetime, "updated_at" datetime) SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140719094418"]]  (117.7ms) commit transaction Migrating to RenameBillingDiscountsToModifiers (20140719103621)  (0.2ms) begin transaction  (0.9ms) ALTER TABLE "billing_discounts" RENAME TO "billing_modifiers"  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_discounts_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_discounts_on_account_id' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_discounts_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_discounts_on_account_id' AND type='index'  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_discounts_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_discounts_on_account_id' AND type='index'   (0.6ms) CREATE INDEX "index_billing_modifiers_on_account_id" ON "billing_modifiers" ("account_id")  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_account_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_discounts_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_discounts_on_account_id' AND type='index'  (0.7ms) DROP INDEX "index_billing_discounts_on_account_id" SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140719103621"]]  (111.5ms) commit transaction Migrating to AddSurchargesSumToBillingAccount (20140719110412)  (0.2ms) begin transaction  (1.1ms) ALTER TABLE "billing_accounts" ADD "surcharges_sum_cents" integer DEFAULT 0 NOT NULL  (0.6ms) ALTER TABLE "billing_accounts" ADD "surcharges_sum_currency" varchar(255) DEFAULT 'USD' NOT NULL SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140719110412"]]  (75.6ms) commit transaction Migrating to AddTypeToBillingPayment (20140720110811)  (0.1ms) begin transaction  (0.6ms) ALTER TABLE "billing_payments" ADD "type" varchar(255)  (0.4ms) ALTER TABLE "billing_payments" ADD "payment_type_id" integer SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140720110811"]]  (69.5ms) commit transaction Migrating to AddTypeToBillingPaymentType (20140720132559)  (0.1ms) begin transaction  (0.7ms) ALTER TABLE "billing_payment_types" ADD "type" varchar(255) SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140720132559"]]  (68.3ms) commit transaction Migrating to CreateBillingOperators (20140721172932)  (0.2ms) begin transaction  (0.8ms) CREATE TABLE "billing_operators" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "master_id" integer, "name" varchar(255), "type" varchar(255), "created_at" datetime, "updated_at" datetime)  SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140721172932"]]  (79.3ms) commit transaction Migrating to CreateBillingDepartments (20140721173106)  (0.2ms) begin transaction  (0.7ms) CREATE TABLE "billing_departments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "master_id" integer, "name" varchar(255), "tax_group_id" integer, "type" varchar(255), "created_at" datetime, "updated_at" datetime)  SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140721173106"]]  (110.8ms) commit transaction Migrating to ChangeTableBaseBillingTaxGroup (20140722160242)  (0.2ms) begin transaction  (0.9ms) ALTER TABLE "billing_tax_groups" ADD "master_id" integer  (0.5ms) ALTER TABLE "billing_tax_groups" ADD "number" integer  (0.5ms) ALTER TABLE "billing_tax_groups" ADD "percent_ratio" decimal(6,3)  (0.6ms) ALTER TABLE "billing_tax_groups" ADD "banned" boolean  (0.5ms) ALTER TABLE "billing_tax_groups" ADD "type" varchar(255)  (0.4ms) ALTER TABLE "billing_tax_groups" ADD "deleted_at" datetime SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140722160242"]]  (97.6ms) commit transaction Migrating to ChangeTableBaseBillingOperator (20140722160258)  (0.3ms) begin transaction  (1.0ms) ALTER TABLE "billing_operators" ADD "number" integer  (0.4ms) ALTER TABLE "billing_operators" ADD "banned" boolean  (0.5ms) ALTER TABLE "billing_operators" ADD "deleted_at" datetime SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140722160258"]]  (70.7ms) commit transaction Migrating to ChangeTableBaseBillingPaymentType (20140722160529)  (0.1ms) begin transaction  (0.5ms) ALTER TABLE "billing_payment_types" ADD "master_id" integer  (0.3ms) ALTER TABLE "billing_payment_types" ADD "number" integer  (0.3ms) ALTER TABLE "billing_payment_types" ADD "banned" boolean  (0.3ms) ALTER TABLE "billing_payment_types" ADD "deleted_at" datetime SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140722160529"]]  (85.2ms) commit transaction Migrating to ChangeTableBaseBillingDepartments (20140722160902)  (0.1ms) begin transaction  (0.5ms) ALTER TABLE "billing_departments" ADD "number" integer  (0.4ms) ALTER TABLE "billing_departments" ADD "banned" boolean  (0.3ms) ALTER TABLE "billing_departments" ADD "deleted_at" datetime  (0.3ms) CREATE INDEX "index_billing_departments_on_tax_group_id" ON "billing_departments" ("tax_group_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140722160902"]]  (97.2ms) commit transaction Migrating to ChangeTableBaseBillingPlus (20140722161743)  (0.1ms) begin transaction  (0.5ms) ALTER TABLE "billing_plus" ADD "master_id" integer  (0.2ms) ALTER TABLE "billing_plus" ADD "tax_group_id" integer  (0.2ms) CREATE INDEX "index_billing_plus_on_tax_group_id" ON "billing_plus" ("tax_group_id")  (0.2ms) ALTER TABLE "billing_plus" ADD "department_id" integer  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index'  (0.2ms) CREATE INDEX "index_billing_plus_on_department_id" ON "billing_plus" ("department_id")  (0.2ms) ALTER TABLE "billing_plus" ADD "number" integer  (0.3ms) ALTER TABLE "billing_plus" ADD "price_cents" integer DEFAULT 0 NOT NULL  (0.4ms) ALTER TABLE "billing_plus" ADD "price_currency" varchar(255) DEFAULT 'USD' NOT NULL  (0.4ms) ALTER TABLE "billing_plus" ADD "code" varchar(255)  (0.3ms) ALTER TABLE "billing_plus" ADD "type" varchar(255)  (0.3ms) ALTER TABLE "billing_plus" ADD "banned" boolean  (0.3ms) ALTER TABLE "billing_plus" ADD "deleted_at" datetime SQL (0.1ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140722161743"]]  (107.9ms) commit transaction Migrating to ChangeTableBaseBillingOrigins (20140722162315)  (0.2ms) begin transaction  (0.7ms) ALTER TABLE "billing_origins" ADD "master_id" integer  (0.3ms) ALTER TABLE "billing_origins" ADD "fiscal_device_id" integer  (0.3ms) ALTER TABLE "billing_origins" ADD "banned" boolean  (0.3ms) ALTER TABLE "billing_origins" ADD "deleted_at" datetime  (0.3ms) ALTER TABLE "billing_origins" ADD "type" varchar(255)  (0.3ms) ALTER TABLE "billing_origins" ADD "payment_model" varchar(255) DEFAULT 'Billing::PaymentWithType'  (0.3ms) CREATE INDEX "index_billing_origins_on_fiscal_device_id" ON "billing_origins" ("fiscal_device_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140722162315"]]  (138.5ms) commit transaction Migrating to AddOriginToBillingAccount (20140724173527)  (0.3ms) begin transaction  (1.3ms) ALTER TABLE "billing_accounts" ADD "origin_id" integer  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'   (0.5ms) CREATE INDEX "index_billing_accounts_on_origin_id" ON "billing_accounts" ("origin_id") SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140724173527"]]  (130.1ms) commit transaction Migrating to RemoveOriginAndFiscalDeficeFromBillingPayment (20140724173917)  (0.2ms) begin transaction  (1.0ms) CREATE TEMPORARY TABLE "abilling_payments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "account_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime, "type" varchar(255), "payment_type_id" integer)  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'   (0.4ms) CREATE INDEX "tindex_abilling_payments_on_account_id" ON "abilling_payments" ("account_id")  (0.2ms) SELECT * FROM "billing_payments"  (0.5ms) DROP TABLE "billing_payments"  (0.7ms) CREATE TABLE "billing_payments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "account_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime, "type" varchar(255), "payment_type_id" integer)   (0.2ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_payments_on_account_id' AND type='index'  (0.4ms) CREATE INDEX "index_billing_payments_on_account_id" ON "billing_payments" ("account_id")  (0.2ms) SELECT * FROM "abilling_payments"  (0.5ms) DROP TABLE "abilling_payments"  (0.4ms) CREATE TEMPORARY TABLE "abilling_payments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "account_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime, "type" varchar(255), "payment_type_id" integer)  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'   (0.3ms) CREATE INDEX "tindex_abilling_payments_on_account_id" ON "abilling_payments" ("account_id")  (0.2ms) SELECT * FROM "billing_payments"  (0.6ms) DROP TABLE "billing_payments"  (0.4ms) CREATE TABLE "billing_payments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "account_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime, "type" varchar(255), "payment_type_id" integer)   (0.2ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_payments_on_account_id' AND type='index'  (0.3ms) CREATE INDEX "index_billing_payments_on_account_id" ON "billing_payments" ("account_id")  (0.1ms) SELECT * FROM "abilling_payments"  (0.3ms) DROP TABLE "abilling_payments" SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140724173917"]]  (115.6ms) commit transaction Migrating to AddStatusToBillingPayment (20140725122914)  (0.2ms) begin transaction  (0.9ms) ALTER TABLE "billing_payments" ADD "status" varchar(255) SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725122914"]]  (84.8ms) commit transaction Migrating to EqalizeSchemasBillingCharge (20140725142525)  (0.1ms) begin transaction  (0.6ms) ALTER TABLE "billing_charges" ADD "name" varchar(255)  (0.4ms) ALTER TABLE "billing_charges" ADD "description" varchar(255)  (0.4ms) ALTER TABLE "billing_charges" ADD "origin_id" integer  (0.5ms) ALTER TABLE "billing_charges" ADD "value_cents" integer DEFAULT 0 NOT NULL  (0.4ms) ALTER TABLE "billing_charges" ADD "value_currency" varchar(255) DEFAULT 'USD' NOT NULL  (0.5ms) ALTER TABLE "billing_charges" ADD "deleted_at" datetime  (0.6ms) ALTER TABLE "billing_charges" ADD "revenue_at" datetime  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'   (0.2ms) CREATE INDEX "index_billing_charges_on_origin_id" ON "billing_charges" ("origin_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'   (0.3ms) CREATE INDEX "index_billing_charges_on_deleted_at" ON "billing_charges" ("deleted_at")  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'  (0.3ms) CREATE INDEX "index_billing_charges_on_revenue_at" ON "billing_charges" ("revenue_at") SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725142525"]]  (101.1ms) commit transaction Migrating to EqalizeSchemasBillingDepartment (20140725143734)  (0.1ms) begin transaction  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index'   (0.3ms) CREATE INDEX "index_billing_departments_on_deleted_at" ON "billing_departments" ("deleted_at") SQL (0.1ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725143734"]]  (96.6ms) commit transaction Migrating to EqalizeSchemasBillingClosure (20140725145640)  (0.1ms) begin transaction  (0.7ms) CREATE TABLE "billing_closures" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "master_id" integer, "origin_id" integer, "payments_sum_cents" integer DEFAULT 0 NOT NULL, "payments_sum_currency" varchar(255) DEFAULT 'USD' NOT NULL, "payments_cash_cents" integer DEFAULT 0 NOT NULL, "payments_cash_currency" varchar(255) DEFAULT 'USD' NOT NULL, "payments_fiscal_cents" integer DEFAULT 0 NOT NULL, "payments_fiscal_currency" varchar(255) DEFAULT 'USD' NOT NULL, "note" text, "type" varchar(255), "created_at" datetime, "updated_at" datetime, "extface_job_id" integer, "f_period_from" date, "f_period_to" date, "zeroing" boolean, "f_operation" varchar(255))  (0.3ms) CREATE INDEX "index_billing_closures_on_origin_id" ON "billing_closures" ("origin_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725145640"]]  (101.2ms) commit transaction Migrating to EqalizeSchemasBillingOperators (20140725145953)  (0.2ms) begin transaction  (0.8ms) CREATE INDEX "index_billing_operators_on_deleted_at" ON "billing_operators" ("deleted_at") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725145953"]]  (102.0ms) commit transaction Migrating to EqalizeSchemasBillingOrigin (20140725150329)  (0.2ms) begin transaction  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index'   (0.6ms) CREATE INDEX "index_billing_origins_on_deleted_at" ON "billing_origins" ("deleted_at") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725150329"]]  (109.0ms) commit transaction Migrating to EqalizeSchemasBillingPaymentType (20140725151522)  (0.2ms) begin transaction  (0.9ms) ALTER TABLE "billing_payment_types" ADD "print_copy" boolean  (0.5ms) CREATE INDEX "index_billing_payment_types_on_deleted_at" ON "billing_payment_types" ("deleted_at") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725151522"]]  (100.7ms) commit transaction Migrating to EqalizeSchemasBillingPayment (20140725152125)  (0.2ms) begin transaction  (0.9ms) ALTER TABLE "billing_payments" ADD "name" varchar(255)  (0.7ms) ALTER TABLE "billing_payments" ADD "description" varchar(255)  (0.5ms) ALTER TABLE "billing_payments" ADD "external_token" varchar(255)  (0.6ms) ALTER TABLE "billing_payments" ADD "note" varchar(255)  (0.5ms) ALTER TABLE "billing_payments" ADD "closure_id" integer  (0.5ms) ALTER TABLE "billing_payments" ADD "deleted_at" datetime  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'   (0.4ms) CREATE INDEX "index_billing_payments_on_deleted_at" ON "billing_payments" ("deleted_at")  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'  (0.4ms) CREATE INDEX "index_billing_payments_on_closure_id" ON "billing_payments" ("closure_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725152125"]]  (109.1ms) commit transaction Migrating to EqalizeSchemasBillingVersion (20140725153215)  (0.2ms) begin transaction  (0.8ms) CREATE TABLE "billing_versions" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "item_type" varchar(255) NOT NULL, "item_id" integer NOT NULL, "event" varchar(255) NOT NULL, "whodunnit" varchar(255), "object" text, "created_at" datetime, "ip" varchar(255), "user_agent" varchar(255))   (0.5ms) CREATE INDEX "index_billing_versions_on_item_type_and_item_id" ON "billing_versions" ("item_type", "item_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725153215"]]  (106.9ms) commit transaction Migrating to EqalizeSchemasBillingPtFpMapping (20140725153658)  (0.2ms) begin transaction  (0.7ms) CREATE TABLE "billing_pt_fp_mappings" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "payment_type_id" integer, "extface_driver_id" integer, "mapping" integer, "created_at" datetime, "updated_at" datetime)  (0.6ms) CREATE INDEX "index_billing_pt_fp_mappings_on_extface_driver_id" ON "billing_pt_fp_mappings" ("extface_driver_id")  (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index'  (0.4ms) CREATE INDEX "index_billing_pt_fp_mappings_on_payment_type_id" ON "billing_pt_fp_mappings" ("payment_type_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725153658"]]  (105.6ms) commit transaction Migrating to AddExtfaceJobToBillingAccount (20140725164847)  (0.2ms) begin transaction  (1.0ms) ALTER TABLE "billing_accounts" ADD "extface_job_id" integer  (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'   (0.5ms) CREATE INDEX "index_billing_accounts_on_extface_job_id" ON "billing_accounts" ("extface_job_id") SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140725164847"]]  (99.1ms) commit transaction Migrating to RenameClosureToBillingReport (20140726163220)  (0.3ms) begin transaction  (1.0ms) ALTER TABLE "billing_closures" RENAME TO "billing_reports"  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_closures_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_closures_on_origin_id' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_closures_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_closures_on_origin_id' AND type='index'  (0.4ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_closures_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_closures_on_origin_id' AND type='index'   (0.6ms) CREATE INDEX "index_billing_reports_on_origin_id" ON "billing_reports" ("origin_id")  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_reports_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_reports_on_origin_id' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_closures_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_closures_on_origin_id' AND type='index'  (0.6ms) DROP INDEX "index_billing_closures_on_origin_id" SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140726163220"]]  (104.1ms) commit transaction Migrating to RemoveClosureFromBillingAccount (20140726165718)  (0.2ms) begin transaction  (0.4ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_closure_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_closure_id' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'   (0.6ms) DROP INDEX "index_billing_payments_on_closure_id"  (0.7ms) CREATE TEMPORARY TABLE "abilling_payments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "account_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime, "type" varchar(255), "payment_type_id" integer, "status" varchar(255), "name" varchar(255), "description" varchar(255), "external_token" varchar(255), "note" varchar(255), "closure_id" integer, "deleted_at" datetime)   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'   (0.3ms) CREATE INDEX "tindex_abilling_payments_on_deleted_at" ON "abilling_payments" ("deleted_at")  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_payments_on_deleted_at' AND type='index'   (0.3ms) CREATE INDEX "tindex_abilling_payments_on_account_id" ON "abilling_payments" ("account_id")  (0.2ms) SELECT * FROM "billing_payments"  (0.6ms) DROP TABLE "billing_payments"  (0.5ms) CREATE TABLE "billing_payments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "account_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime, "type" varchar(255), "payment_type_id" integer, "status" varchar(255), "name" varchar(255), "description" varchar(255), "external_token" varchar(255), "note" varchar(255), "deleted_at" datetime)   (0.2ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_payments_on_account_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_payments_on_deleted_at' AND type='index'   (0.3ms) CREATE INDEX "index_billing_payments_on_account_id" ON "billing_payments" ("account_id")  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'   (0.3ms) CREATE INDEX "index_billing_payments_on_deleted_at" ON "billing_payments" ("deleted_at")  (0.2ms) SELECT * FROM "abilling_payments"  (0.3ms) DROP TABLE "abilling_payments" SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140726165718"]]  (71.4ms) commit transaction Migrating to AddReportToBillingAccount (20140726170002)  (0.2ms) begin transaction  (1.2ms) ALTER TABLE "billing_accounts" ADD "report_id" integer  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'   (0.5ms) CREATE INDEX "index_billing_accounts_on_report_id" ON "billing_accounts" ("report_id") SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140726170002"]]  (72.6ms) commit transaction Migrating to AddAutofinAndFinalizedAtToBillingAccount (20140728110230)  (0.2ms) begin transaction  (0.8ms) ALTER TABLE "billing_accounts" ADD "autofin" boolean DEFAULT 't'  (0.5ms) ALTER TABLE "billing_accounts" ADD "finalized_at" datetime SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140728110230"]]  (68.1ms) commit transaction Migrating to AddNameToBillingAccount (20140729083050)  (0.1ms) begin transaction  (0.8ms) ALTER TABLE "billing_accounts" ADD "name" varchar(255) SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140729083050"]]  (70.5ms) commit transaction Migrating to AddNumberToBillingAccount (20140729083408)  (0.2ms) begin transaction  (1.1ms) ALTER TABLE "billing_accounts" ADD "number" varchar(255) SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140729083408"]]  (101.0ms) commit transaction Migrating to AddDeletedAtToBillingModifier (20140729180849)  (0.2ms) begin transaction  (0.9ms) ALTER TABLE "billing_modifiers" ADD "deleted_at" datetime SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140729180849"]]  (59.8ms) commit transaction Migrating to AddDeletedAtToBillingAccount (20140729182146)  (0.2ms) begin transaction  (1.2ms) ALTER TABLE "billing_accounts" ADD "deleted_at" datetime SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140729182146"]]  (76.8ms) commit transaction Migrating to RenameBillingAccountToBill (20140803073707)  (0.2ms) begin transaction  (1.4ms) ALTER TABLE "billing_accounts" RENAME TO "billing_bills"  (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_report_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_report_id' AND type='index'  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_report_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'   (0.3ms) CREATE INDEX "index_billing_bills_on_report_id" ON "billing_bills" ("report_id")  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_report_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'   (0.4ms) DROP INDEX "index_billing_accounts_on_report_id"  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'  (0.3ms) CREATE INDEX "index_billing_bills_on_extface_job_id" ON "billing_bills" ("extface_job_id")  (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_extface_job_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'  (0.2ms) DROP INDEX "index_billing_accounts_on_extface_job_id"  (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'   (0.2ms) CREATE INDEX "index_billing_bills_on_origin_id" ON "billing_bills" ("origin_id")  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'   (0.2ms) DROP INDEX "index_billing_accounts_on_origin_id"  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_origin_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_origin_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'  (0.2ms) CREATE INDEX "index_billing_bills_on_billable_id_and_billable_type" ON "billing_bills" ("billable_id", "billable_type")  (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_accounts_on_billable_id_and_billable_type' AND type='index'  (0.2ms) DROP INDEX "index_billing_accounts_on_billable_id_and_billable_type"  (0.3ms) CREATE TEMPORARY TABLE "abilling_charges" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "bill_id" integer, "chargable_id" integer, "chargable_type" varchar(255), "price_cents" integer DEFAULT 0 NOT NULL, "price_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime, "name" varchar(255), "description" varchar(255), "origin_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "deleted_at" datetime, "revenue_at" datetime)  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'   (0.2ms) CREATE INDEX "tindex_abilling_charges_on_revenue_at" ON "abilling_charges" ("revenue_at")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_revenue_at' AND type='index'   (0.2ms) CREATE INDEX "tindex_abilling_charges_on_deleted_at" ON "abilling_charges" ("deleted_at")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_revenue_at' AND type='index'  (0.2ms) CREATE INDEX "tindex_abilling_charges_on_origin_id" ON "abilling_charges" ("origin_id")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_revenue_at' AND type='index'  (0.2ms) CREATE INDEX "tindex_abilling_charges_on_chargable_id_and_chargable_type" ON "abilling_charges" ("chargable_id", "chargable_type")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_origin_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_deleted_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_revenue_at' AND type='index'   (0.1ms) CREATE INDEX "tindex_abilling_charges_on_account_id" ON "abilling_charges" ("bill_id")  (0.1ms) SELECT * FROM "billing_charges"  (0.5ms) DROP TABLE "billing_charges"  (0.3ms) CREATE TABLE "billing_charges" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "bill_id" integer, "chargable_id" integer, "chargable_type" varchar(255), "price_cents" integer DEFAULT 0 NOT NULL, "price_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime, "name" varchar(255), "description" varchar(255), "origin_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "deleted_at" datetime, "revenue_at" datetime)   (0.1ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_account_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_chargable_id_and_chargable_type' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_charges_on_revenue_at' AND type='index'  (0.2ms) CREATE INDEX "index_billing_charges_on_account_id" ON "billing_charges" ("bill_id")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'  (0.2ms) CREATE INDEX "index_billing_charges_on_chargable_id_and_chargable_type" ON "billing_charges" ("chargable_id", "chargable_type")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'   (0.2ms) CREATE INDEX "index_billing_charges_on_origin_id" ON "billing_charges" ("origin_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'   (0.1ms) CREATE INDEX "index_billing_charges_on_deleted_at" ON "billing_charges" ("deleted_at")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'  (0.1ms) CREATE INDEX "index_billing_charges_on_revenue_at" ON "billing_charges" ("revenue_at")  (0.1ms) SELECT * FROM "abilling_charges"  (0.2ms) DROP TABLE "abilling_charges"  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'  (0.1ms) CREATE INDEX "index_billing_charges_on_bill_id" ON "billing_charges" ("bill_id")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_bill_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_account_id' AND type='index'   (0.1ms) DROP INDEX "index_billing_charges_on_account_id"  (0.2ms) CREATE TEMPORARY TABLE "abilling_modifiers" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "bill_id" integer, "charge_id" integer, "percent_ratio" decimal(6,3), "created_at" datetime, "updated_at" datetime, "fixed_value_cents" integer DEFAULT 0 NOT NULL, "fixed_value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "deleted_at" datetime)   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_account_id' AND type='index'  (0.1ms) CREATE INDEX "tindex_abilling_modifiers_on_account_id" ON "abilling_modifiers" ("bill_id")  (0.1ms) SELECT * FROM "billing_modifiers"  (0.2ms) DROP TABLE "billing_modifiers"  (0.2ms) CREATE TABLE "billing_modifiers" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "bill_id" integer, "charge_id" integer, "percent_ratio" decimal(6,3), "created_at" datetime, "updated_at" datetime, "fixed_value_cents" integer DEFAULT 0 NOT NULL, "fixed_value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "deleted_at" datetime)  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_modifiers_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_modifiers_on_account_id' AND type='index'   (0.1ms) CREATE INDEX "index_billing_modifiers_on_account_id" ON "billing_modifiers" ("bill_id")  (0.1ms) SELECT * FROM "abilling_modifiers"  (0.1ms) DROP TABLE "abilling_modifiers"  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_account_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_account_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_account_id' AND type='index'   (0.1ms) CREATE INDEX "index_billing_modifiers_on_bill_id" ON "billing_modifiers" ("bill_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_account_id' AND type='index'  (0.1ms) DROP INDEX "index_billing_modifiers_on_account_id"  (0.2ms) CREATE TEMPORARY TABLE "abilling_payments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "bill_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime, "type" varchar(255), "payment_type_id" integer, "status" varchar(255), "name" varchar(255), "description" varchar(255), "external_token" varchar(255), "note" varchar(255), "deleted_at" datetime)  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'  (0.1ms) CREATE INDEX "tindex_abilling_payments_on_deleted_at" ON "abilling_payments" ("deleted_at")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_payments_on_deleted_at' AND type='index'  (0.1ms) CREATE INDEX "tindex_abilling_payments_on_account_id" ON "abilling_payments" ("bill_id")  (0.1ms) SELECT * FROM "billing_payments"  (0.2ms) DROP TABLE "billing_payments"  (0.2ms) CREATE TABLE "billing_payments" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "bill_id" integer, "value_cents" integer DEFAULT 0 NOT NULL, "value_currency" varchar(255) DEFAULT 'USD' NOT NULL, "created_at" datetime, "updated_at" datetime, "type" varchar(255), "payment_type_id" integer, "status" varchar(255), "name" varchar(255), "description" varchar(255), "external_token" varchar(255), "note" varchar(255), "deleted_at" datetime)  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='tindex_abilling_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_payments_on_account_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='tindex_abilling_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='tindex_abilling_payments_on_deleted_at' AND type='index'  (0.1ms) CREATE INDEX "index_billing_payments_on_account_id" ON "billing_payments" ("bill_id")  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'  (0.1ms) CREATE INDEX "index_billing_payments_on_deleted_at" ON "billing_payments" ("deleted_at")  (0.1ms) SELECT * FROM "abilling_payments"  (0.2ms) DROP TABLE "abilling_payments"  (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'   (0.2ms) CREATE INDEX "index_billing_payments_on_bill_id" ON "billing_payments" ("bill_id")  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_bill_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_account_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_account_id' AND type='index'   (0.1ms) DROP INDEX "index_billing_payments_on_account_id" SQL (0.1ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140803073707"]]  (103.5ms) commit transaction Migrating to AddQtyToBillingCharge (20140804065726)  (0.2ms) begin transaction  (1.0ms) ALTER TABLE "billing_charges" ADD "qty" decimal(6,3) SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140804065726"]]  (240.4ms) commit transaction Migrating to AddTaxRatioToBillingCharge (20140804070517)  (0.2ms) begin transaction  (1.1ms) ALTER TABLE "billing_charges" ADD "tax_ratio" decimal(6,3) SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20140804070517"]]  (68.1ms) commit transaction Migrating to AddTransferDeviceToBillingOrigin (20141001185321)  (0.2ms) begin transaction  (0.9ms) ALTER TABLE "billing_origins" ADD "transfer_device_id" integer  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index'  (0.4ms) CREATE INDEX "index_billing_origins_on_transfer_device_id" ON "billing_origins" ("transfer_device_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20141001185321"]]  (73.7ms) commit transaction Migrating to AddFAmountToBillingReport (20141027235427)  (0.2ms) begin transaction  (1.0ms) ALTER TABLE "billing_reports" ADD "f_amount_cents" integer DEFAULT 0 NOT NULL  (0.7ms) ALTER TABLE "billing_reports" ADD "f_amount_currency" varchar(255) DEFAULT 'USD' NOT NULL SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20141027235427"]]  (75.0ms) commit transaction Migrating to BillingTgFpMapping (20141221201539)  (0.2ms) begin transaction  (0.6ms) CREATE TABLE "billing_tg_fp_mappings" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "tax_group_id" integer, "extface_driver_id" integer, "mapping" integer, "created_at" datetime, "updated_at" datetime)  (0.4ms) CREATE INDEX "index_billing_tg_fp_mappings_on_extface_driver_id" ON "billing_tg_fp_mappings" ("extface_driver_id")  (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index'  (0.5ms) CREATE INDEX "index_billing_tg_fp_mappings_on_tax_group_id" ON "billing_tg_fp_mappings" ("tax_group_id") SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20141221201539"]]  (108.3ms) commit transaction Migrating to BillingOpFpMapping (20141221233912)  (0.1ms) begin transaction  (0.4ms) CREATE TABLE "billing_op_fp_mappings" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "operator_id" integer, "extface_driver_id" integer, "mapping" integer, "created_at" datetime, "updated_at" datetime)   (0.3ms) CREATE INDEX "index_billing_op_fp_mappings_on_extface_driver_id" ON "billing_op_fp_mappings" ("extface_driver_id")  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index'   (0.2ms) CREATE INDEX "index_billing_op_fp_mappings_on_operator_id" ON "billing_op_fp_mappings" ("operator_id") SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20141221233912"]]  (85.3ms) commit transaction Migrating to CreateBillingResources (20141229234928)  (0.2ms) begin transaction  (0.8ms) CREATE TABLE "billing_resources" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "master_id" integer, "name" varchar(255), "properties" text, "banned" boolean, "type" varchar(255), "created_at" datetime, "updated_at" datetime, "deleted_at" datetime) SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20141229234928"]]  (84.8ms) commit transaction Migrating to AddPwdToBillingOperatorMapping (20150311013019)  (0.2ms) begin transaction  (0.6ms) ALTER TABLE "billing_op_fp_mappings" ADD "pwd" varchar(255) SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20150311013019"]]  (64.4ms) commit transaction ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_bill_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_operators_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_operators_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_bill_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_department_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_department_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_reports_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_reports_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index' ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to AddObjectChangesToBillingVersions (20150510142229)  (0.2ms) begin transaction  (0.7ms) ALTER TABLE "billing_versions" ADD "object_changes" text SQL (11.7ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20150510142229"]]  (153.6ms) commit transaction ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_bill_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_operators_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_operators_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_bill_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_department_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_department_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_reports_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_reports_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index'  ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to AddMasterToBillingVersion (20150510235441)  (0.1ms) begin transaction  (0.5ms) ALTER TABLE "billing_versions" ADD "master_id" integer  (0.3ms) ALTER TABLE "billing_versions" ADD "master_type" varchar SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20150510235441"]]  (82.0ms) commit transaction ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_bill_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_operators_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_operators_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_bill_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_department_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_department_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_reports_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_reports_on_origin_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index' ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to AddDeletedAtToBillingReport (20150512040421)  (0.1ms) begin transaction  (0.6ms) ALTER TABLE "billing_reports" ADD "deleted_at" datetime SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20150512040421"]]  (114.6ms) commit transaction ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_bill_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_operators_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_operators_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_bill_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_department_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_department_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_reports_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_reports_on_origin_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index'  ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to AddPrintDeviceToBillingOrigin (20160723160908)  (0.1ms) begin transaction  (0.4ms) ALTER TABLE "billing_origins" ADD "print_device_id" integer SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20160723160908"]]  (115.6ms) commit transaction Migrating to AddPrintJobToBillingBill (20160723234233)  (0.3ms) begin transaction  (1.8ms) ALTER TABLE "billing_bills" ADD "print_job_id" integer SQL (0.5ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20160723234233"]]  (140.1ms) commit transaction Migrating to AddPrintHeadersToBillingOrigin (20160824235224)  (0.2ms) begin transaction  (0.8ms) ALTER TABLE "billing_origins" ADD "print_header" varchar  (0.4ms) ALTER TABLE "billing_origins" ADD "print_footer" varchar SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20160824235224"]]  (116.1ms) commit transaction ActiveRecord::SchemaMigration Load (0.7ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.5ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index'  (0.3ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_origin_id' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_bill_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'   (0.3ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_deleted_at' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_operators_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_operators_on_deleted_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_bill_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_department_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_department_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_reports_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_reports_on_origin_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index'  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index' ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations" ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_billable_id_and_billable_type' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_extface_job_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_bills_on_report_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_bills_on_report_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_bill_id' AND type='index'   (0.2ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_revenue_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_revenue_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_charges_on_chargable_id_and_chargable_type' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_deleted_at' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_departments_on_tax_group_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_modifiers_on_bill_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_operator_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_op_fp_mappings_on_extface_driver_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_operators_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_operators_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_transfer_device_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_origins_on_fiscal_device_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payment_types_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_bill_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_bill_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_payments_on_deleted_at' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_payments_on_deleted_at' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_department_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_department_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_plus_on_tax_group_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_payment_type_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_pt_fp_mappings_on_extface_driver_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_reports_on_origin_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_reports_on_origin_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_tax_group_id' AND type='index'   (0.1ms) SELECT sql FROM sqlite_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_tg_fp_mappings_on_extface_driver_id' AND type='index'  (0.1ms)  SELECT sql FROM sqlite_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index' UNION ALL SELECT sql FROM sqlite_temp_master WHERE name='index_billing_versions_on_item_type_and_item_id' AND type='index'