ALTER TABLE "vendor_business_groups" DISABLE ROW LEVEL SECURITY;--> statement-breakpoint
ALTER TABLE "vendor_internal_partners" DISABLE ROW LEVEL SECURITY;--> statement-breakpoint
ALTER TABLE "vendor_partner_functions" DISABLE ROW LEVEL SECURITY;--> statement-breakpoint
ALTER TABLE "vendor_purchase_organizations" DISABLE ROW LEVEL SECURITY;--> statement-breakpoint
ALTER TABLE "vendor_representative_emails" DISABLE ROW LEVEL SECURITY;--> statement-breakpoint
ALTER TABLE "vendor_representative_faxes" DISABLE ROW LEVEL SECURITY;--> statement-breakpoint
ALTER TABLE "vendor_representative_telephones" DISABLE ROW LEVEL SECURITY;--> statement-breakpoint
ALTER TABLE "vendor_representative_urls" DISABLE ROW LEVEL SECURITY;--> statement-breakpoint
ALTER TABLE "vendor_tax_numbers" DISABLE ROW LEVEL SECURITY;--> statement-breakpoint
ALTER TABLE "vendor_withholding_tax" DISABLE ROW LEVEL SECURITY;--> statement-breakpoint
DROP TABLE "vendor_business_groups" CASCADE;--> statement-breakpoint
DROP TABLE "vendor_internal_partners" CASCADE;--> statement-breakpoint
DROP TABLE "vendor_partner_functions" CASCADE;--> statement-breakpoint
DROP TABLE "vendor_purchase_organizations" CASCADE;--> statement-breakpoint
DROP TABLE "vendor_representative_emails" CASCADE;--> statement-breakpoint
DROP TABLE "vendor_representative_faxes" CASCADE;--> statement-breakpoint
DROP TABLE "vendor_representative_telephones" CASCADE;--> statement-breakpoint
DROP TABLE "vendor_representative_urls" CASCADE;--> statement-breakpoint
DROP TABLE "vendor_tax_numbers" CASCADE;--> statement-breakpoint
DROP TABLE "vendor_withholding_tax" CASCADE;--> statement-breakpoint
ALTER TABLE "ocr_rows" ADD COLUMN "user_id" integer;--> statement-breakpoint
ALTER TABLE "ocr_rows" ADD CONSTRAINT "ocr_rows_user_id_users_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("id") ON DELETE set null ON UPDATE no action;--> statement-breakpoint
CREATE UNIQUE INDEX "idx_ocr_row_unique" ON "ocr_rows" USING btree ("table_id","report_no","no");--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "account_group";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "account_group_type";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "customer_code";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "posting_hold_indicator";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "purchase_hold_indicator";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "hold_reason";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "delete_indicator";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "company_id";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "business_type";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "industry_type";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "registration_date";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "registration_time";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "registrar_id";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "approval_date";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "approval_time";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "approver_id";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "change_date";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "change_time";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "changer_id";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "nation_code";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "representative_tel_number";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "representative_fax_number";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "business_registration_number";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "corporate_registration_number_oracle";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "tax_code_4";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "company_establishment_date";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "vendor_type";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "global_top_code";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "global_top_name";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "domestic_top_code";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "domestic_top_name";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "business_unit_code";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "business_unit_name";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "duns_number";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "interface_date";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "interface_time";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "interface_status";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "interface_message";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "title";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "vat_registration_number";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "giro_vendor_indicator";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "vendor_name_1";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "vendor_name_2";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "vendor_name_3";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "vendor_name_4";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "vendor_name_abbreviation_1";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "vendor_name_abbreviation_2";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "potential_vendor_code";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "address_1";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "address_2";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "quality_manager_name";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "quality_manager_tel_number";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "quality_manager_email";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "sub_workplace_sequence";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "overlap_cause_code";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "document_type";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "document_number";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "partial_document";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "document_version";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "inbound_flag";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "delete_hold_indicator";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "purchase_hold_date";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "post_box";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "international_location_check_number";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "withholding_tax_gender_key";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "vendor_contract_manager_1";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "vendor_contract_manager_2";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "representative_resident_number";--> statement-breakpoint
ALTER TABLE "vendors" DROP COLUMN "company_volume";