-- Create Table Statement for 'Contract'
DROP TABLE IF EXISTS `CONTRACT`;
CREATE TABLE `CONTRACT` (
	ID bigint(20) NOT NULL,
	REF_CODE varchar,
	MERCHANT_ACCOUNT_CODE int(11) NOT NULL,
	COLLECTOR_ACCOUNT_CODE int(11),
	CREATE_DATE datetime,
	NAME varchar,
	CONTRACT_CL varchar,
	STATUS_CL varchar,
	REF_CREATOR_CODE varchar,
	REF_SELLER_CODE varchar,
	IMPORT_CODE varchar,
	EFFECTIVE_DATE datetime,
	EXPIRATION_DATE datetime,
	LEVEL int(11),
	LENGTH int(11),
	VALUE int(11),
	FREEZE_BEGIN_DATE datetime,
	FREEZE_END_DATE datetime,
	INDUSTRY_TYPE varchar,
	IS_VISIBLE_EXTERNALLY tinyint(1),
	DEFAULT_PAYMENT_PLAN_FK bigint(20),
	DEFAULT_CONTRACT_FK bigint(20),
	INVOICE_FK bigint(20),
	DOCUMENT_FK bigint(20),
	FREEZE_ADJUSTMENT_FK bigint(20),
	CANCELLATION_ADJUSTMENT_FK bigint(20),
	IS_MARKETING_CALL_ALLOWED tinyint(1),
	CANCELLATION_DATE datetime,
	CUSTOMER_ACCOUNT_FK bigint(20),
	DOCUMENT_FK bigint(20),
	PRIMARY KEY (ID)
) ENGINE=InnoDB;