Hello,
The script in the source scripts/mysql/my_create.sql uses the the following definition
CREATE TABLE domain ( did VARCHAR(64) NOT NULL, domain VARCHAR(128) NOT NULL, flags INT UNSIGNED NOT NULL DEFAULT '0', UNIQUE KEY domain_idx (domain), KEY did_idx (did) );
The script in the source utils/kamctl/mysql/domain-create.sql uses the following definition
CREATE TABLE domain ( id INT(10) UNSIGNED AUTO_INCREMENT PRIMARY KEY NOT NULL, domain VARCHAR(64) DEFAULT '' NOT NULL, last_modified DATETIME DEFAULT '1900-01-01 00:00:01' NOT NULL, CONSTRAINT domain_idx UNIQUE (domain) ) ENGINE=MyISAM;
Which table definition is the correct definition to be used.
Thanks Stagg Shelton
On Monday 26 July 2010, Stagg Shelton wrote:
The script in the source scripts/mysql/my_create.sql uses the the following definition
CREATE TABLE domain ( did VARCHAR(64) NOT NULL, [..] );
The script in the source utils/kamctl/mysql/domain-create.sql uses the following definition
CREATE TABLE domain ( id INT(10) UNSIGNED AUTO_INCREMENT PRIMARY KEY NOT NULL, [..] ) ENGINE=MyISAM;
Which table definition is the correct definition to be used.
Hi Stagg,
the first one is the version for the domain module from sr (modules_s), the latter is the one for the kamailio (modules_k) domain module.
Cheers,
Henning
Hello,
On 7/27/10 1:22 PM, Henning Westerholt wrote:
On Monday 26 July 2010, Stagg Shelton wrote:
The script in the source scripts/mysql/my_create.sql uses the the following definition
CREATE TABLE domain ( did VARCHAR(64) NOT NULL, [..] );
The script in the source utils/kamctl/mysql/domain-create.sql uses the following definition
CREATE TABLE domain ( id INT(10) UNSIGNED AUTO_INCREMENT PRIMARY KEY NOT NULL, [..] ) ENGINE=MyISAM;
Which table definition is the correct definition to be used.
Hi Stagg,
the first one is the version for the domain module from sr (modules_s), the latter is the one for the kamailio (modules_k) domain module.
just to mention that in this particular case both structure should work as modules_k/domain uses only domain column. There is no effect if there are other columns around.
But as Henning said, the structure specified by kamailio is the one created by kamdbctl (i.e., kamdbctl create) and managed via kamctl.
Cheers, Daniel