Open cesarliws opened 10 years ago
I have set default values for several columns, but nordrassil is not importing it:
This is the original table:
CREATE TABLE comx_cadastro_contato ( contatoid BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT, empresaid BIGINT(20) UNSIGNED NULL DEFAULT NULL, nome VARCHAR(120) NOT NULL, natureza CHAR(1) NOT NULL DEFAULT 'P', cpf VARCHAR(20) NULL DEFAULT NULL, rg VARCHAR(20) NULL DEFAULT NULL, cnpj VARCHAR(20) NULL DEFAULT NULL, inscricaoestadual VARCHAR(30) NULL DEFAULT NULL, incricaomunicipal VARCHAR(30) NULL DEFAULT NULL, cliente TINYINT(1) NOT NULL DEFAULT '0', fornecedor TINYINT(1) NOT NULL DEFAULT '0', colaborador TINYINT(1) NOT NULL DEFAULT '0', status CHAR(1) NOT NULL DEFAULT 'A', editdate TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (contatoid), ) COLLATE='utf8_general_ci' ENGINE=InnoDB;
comx_cadastro_contato
contatoid
empresaid
nome
natureza
cpf
rg
cnpj
inscricaoestadual
incricaomunicipal
cliente
fornecedor
colaborador
status
editdate
This is how nordrassil generates it, without the default values:
CREATE TABLE cms_comx_cadastro_contato ( contatoid INT(20) NOT NULL AUTO_INCREMENT, empresaid BIGINT(20) NULL DEFAULT NULL, nome VARCHAR(120) NULL DEFAULT NULL, natureza CHAR(1) NULL DEFAULT NULL, cpf VARCHAR(20) NULL DEFAULT NULL, rg VARCHAR(20) NULL DEFAULT NULL, cnpj VARCHAR(20) NULL DEFAULT NULL, inscricaoestadual VARCHAR(30) NULL DEFAULT NULL, incricaomunicipal VARCHAR(30) NULL DEFAULT NULL, cliente TINYINT(3) NULL DEFAULT NULL, fornecedor TINYINT(3) NULL DEFAULT NULL, colaborador TINYINT(3) NULL DEFAULT NULL, status CHAR(1) NULL DEFAULT NULL, editdate TIMESTAMP NULL DEFAULT NULL, telefones VARCHAR(255) NULL DEFAULT NULL, enderecos VARCHAR(255) NULL DEFAULT NULL, emails VARCHAR(255) NULL DEFAULT NULL, anexos VARCHAR(255) NULL DEFAULT NULL, PRIMARY KEY (contatoid) ) COLLATE='utf8_general_ci' ENGINE=InnoDB;
cms_comx_cadastro_contato
telefones
enderecos
emails
anexos
I have set default values for several columns, but nordrassil is not importing it:
This is the original table:
CREATE TABLE
comx_cadastro_contato
(contatoid
BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT,empresaid
BIGINT(20) UNSIGNED NULL DEFAULT NULL,nome
VARCHAR(120) NOT NULL,natureza
CHAR(1) NOT NULL DEFAULT 'P',cpf
VARCHAR(20) NULL DEFAULT NULL,rg
VARCHAR(20) NULL DEFAULT NULL,cnpj
VARCHAR(20) NULL DEFAULT NULL,inscricaoestadual
VARCHAR(30) NULL DEFAULT NULL,incricaomunicipal
VARCHAR(30) NULL DEFAULT NULL,cliente
TINYINT(1) NOT NULL DEFAULT '0',fornecedor
TINYINT(1) NOT NULL DEFAULT '0',colaborador
TINYINT(1) NOT NULL DEFAULT '0',status
CHAR(1) NOT NULL DEFAULT 'A',editdate
TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (contatoid
), ) COLLATE='utf8_general_ci' ENGINE=InnoDB;This is how nordrassil generates it, without the default values:
CREATE TABLE
cms_comx_cadastro_contato
(contatoid
INT(20) NOT NULL AUTO_INCREMENT,empresaid
BIGINT(20) NULL DEFAULT NULL,nome
VARCHAR(120) NULL DEFAULT NULL,natureza
CHAR(1) NULL DEFAULT NULL,cpf
VARCHAR(20) NULL DEFAULT NULL,rg
VARCHAR(20) NULL DEFAULT NULL,cnpj
VARCHAR(20) NULL DEFAULT NULL,inscricaoestadual
VARCHAR(30) NULL DEFAULT NULL,incricaomunicipal
VARCHAR(30) NULL DEFAULT NULL,cliente
TINYINT(3) NULL DEFAULT NULL,fornecedor
TINYINT(3) NULL DEFAULT NULL,colaborador
TINYINT(3) NULL DEFAULT NULL,status
CHAR(1) NULL DEFAULT NULL,editdate
TIMESTAMP NULL DEFAULT NULL,telefones
VARCHAR(255) NULL DEFAULT NULL,enderecos
VARCHAR(255) NULL DEFAULT NULL,emails
VARCHAR(255) NULL DEFAULT NULL,anexos
VARCHAR(255) NULL DEFAULT NULL, PRIMARY KEY (contatoid
) ) COLLATE='utf8_general_ci' ENGINE=InnoDB;