← Back to team overview

maria-developers team mailing list archive

Updated (by Guest): options for CREATE TABLE (43)

 

-----------------------------------------------------------------------
                              WORKLOG TASK
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
TASK...........: options for CREATE TABLE
CREATION DATE..: Tue, 11 Aug 2009, 17:02
SUPERVISOR.....: Bothorsen
IMPLEMENTOR....: Sanja
COPIES TO......: Sergei, Monty
CATEGORY.......: Server-BackLog
TASK ID........: 43 (http://askmonty.org/worklog/?tid=43)
VERSION........: Server-5.2
STATUS.........: Complete
PRIORITY.......: 60
WORKED HOURS...: 0
ESTIMATE.......: 32 (hours remain)
ORIG. ESTIMATE.: 32

PROGRESS NOTES:

-=-=(Guest - Fri, 23 Apr 2010, 11:02)=-=-
Status updated.
--- /tmp/wklog.43.old.24328     2010-04-23 11:02:07.000000000 +0000
+++ /tmp/wklog.43.new.24328     2010-04-23 11:02:07.000000000 +0000
@@ -1 +1 @@
-Assigned
+Complete

-=-=(Serg - Sun, 11 Apr 2010, 11:58)=-=-
Low Level Design modified.
--- /tmp/wklog.43.old.24176     2010-04-11 11:58:36.000000000 +0000
+++ /tmp/wklog.43.new.24176     2010-04-11 11:58:36.000000000 +0000
@@ -2,6 +2,5 @@
 
 Handler have access to the options during creation and after opening frm.
 
-It should has C interface.
 
 

-=-=(Serg - Thu, 04 Mar 2010, 16:15)=-=-
High-Level Specification modified.
--- /tmp/wklog.43.old.32502     2010-03-04 16:15:12.000000000 +0000
+++ /tmp/wklog.43.new.32502     2010-03-04 16:15:12.000000000 +0000
@@ -1,13 +1,13 @@
-Table definition ca looks like following
+Table definition will look like the following:
 
 CREATE TABLE table
   (field int ... field_opt1=fval1 field_opt2=fval2,
    key key1(field) key_opt1=kval1 key_opt2=kval2)
    table_option1=tval1, table_option2=tval2;
 
-Exclusion should be made for old table and key options where
-'=' was not obligatory. Behaviour and way of storage for existing options will
-be left as is.
+Exceptions should be made for old table and key options where
+'=' was not obligatory. These options will behave as they did,
+no changes from the user point of view.
 
 Old key options:
 KEY_BLOCK_SIZE <num> -> KEY_BLOCK_SIZE=num
@@ -37,12 +37,11 @@
 default charset
 default collation
 DATA DIRECTORY
+INDEX DIRECTORY
 TABLESPACE
 STORAGE
 
-For fields options can go with field attributes (NOT NULL, UNIQUE and so on) can
-be separated from them by '=' sign.
-
-Incorrect option during creation/altering table lead only to worning. During
-opening unrecognised options should be ignored.
+Incorrect option during creation/altering table lead only to a warning.
+Strict mode makes them errors, as expected.
+When opening a table all unrecognised options should be ignored.
 

-=-=(Sergei - Mon, 18 Jan 2010, 22:12)=-=-
Observers changed: Monty,Sergei

-=-=(Monty - Tue, 12 Jan 2010, 17:04)=-=-
Version updated.
--- /tmp/wklog.43.old.21802     2010-01-12 17:04:31.000000000 +0200
+++ /tmp/wklog.43.new.21802     2010-01-12 17:04:31.000000000 +0200
@@ -1 +1 @@
-Server-5.1
+Server-5.2

-=-=(Guest - Fri, 18 Sep 2009, 14:24)=-=-
Low Level Design modified.
--- /tmp/wklog.43.old.31654     2009-09-18 14:24:41.000000000 +0300
+++ /tmp/wklog.43.new.31654     2009-09-18 14:24:41.000000000 +0300
@@ -2,4 +2,6 @@
 
 Handler have access to the options during creation and after opening frm.
 
+It should has C interface.
+
 

-=-=(Sanja - Fri, 18 Sep 2009, 13:32)=-=-
Low Level Design modified.
--- /tmp/wklog.43.old.29567     2009-09-18 13:32:41.000000000 +0300
+++ /tmp/wklog.43.new.29567     2009-09-18 13:32:41.000000000 +0300
@@ -1 +1,5 @@
+Options stored in a list as pairs key, value which are LEX_STRING.
+
+Handler have access to the options during creation and after opening frm.
+
 

-=-=(Sanja - Fri, 18 Sep 2009, 13:21)=-=-
High-Level Specification modified.
--- /tmp/wklog.43.old.29107     2009-09-18 13:21:19.000000000 +0300
+++ /tmp/wklog.43.new.29107     2009-09-18 13:21:19.000000000 +0300
@@ -6,7 +6,8 @@
    table_option1=tval1, table_option2=tval2;
 
 Exclusion should be made for old table and key options where
-'=' was not obligatory.
+'=' was not obligatory. Behaviour and way of storage for existing options will
+be left as is.
 
 Old key options:
 KEY_BLOCK_SIZE <num> -> KEY_BLOCK_SIZE=num
@@ -42,6 +43,6 @@
 For fields options can go with field attributes (NOT NULL, UNIQUE and so on) can
 be separated from them by '=' sign.
 
-
-
+Incorrect option during creation/altering table lead only to worning. During
+opening unrecognised options should be ignored.
 

-=-=(Guest - Tue, 11 Aug 2009, 19:57)=-=-
High-Level Specification modified.
--- /tmp/wklog.43.old.31856     2009-08-11 19:57:38.000000000 +0300
+++ /tmp/wklog.43.new.31856     2009-08-11 19:57:38.000000000 +0300
@@ -5,8 +5,43 @@
    key key1(field) key_opt1=kval1 key_opt2=kval2)
    table_option1=tval1, table_option2=tval2;
 
-Exclusion should be made for old table and key (KEY_BLOCK_SIZE) options where
+Exclusion should be made for old table and key options where
 '=' was not obligatory.
 
+Old key options:
+KEY_BLOCK_SIZE <num> -> KEY_BLOCK_SIZE=num
+WITH PARSER <name> -> PARSER=name
+
+Old table options:
+ENGINE name ->  ENGINE=name
+TYPE name -> TYPE=name
+MAX_ROWS num -> MAX_ROWS=num
+MIX_ROWS num -> MIX_ROWS=num
+AVG_ROW_LENGTH num -> AVG_ROW_LENGTH=num
+PASSWORD string -> PASSWORD=string
+COMMENT string -> COMMENT=string
+AUTO_INCREMENT num -> AUTO_INCREMENT=num
+PACK_KEYS num/default -> PACK_KEYS=num/default
+CHECKSUM num -> CHECKSUM=num
+TABLE_CHECKSUM num -> TABLE_CHECKSUM=num
+PAGE_CHECKSUM num -> PAGE_CHECKSUM=num
+DELAY_KEY_WRITE num -> DELAY_KEY_WRITE=num
+ROW_FORMAT name -> ROW_FORMAT=name
+INSERT_METHOD name -> INSERT_METHOD=name
+KEY_BLOCK_SIZE num -> KEY_BLOCK_SIZE=num
+TRANSACTIONAL num -> TRANSACTIONAL=num
+
+Table options which will be left hardcoded
+UNION
+default charset
+default collation
+DATA DIRECTORY
+TABLESPACE
+STORAGE
+
 For fields options can go with field attributes (NOT NULL, UNIQUE and so on) can
 be separated from them by '=' sign.
+
+
+
+

-=-=(Guest - Tue, 11 Aug 2009, 19:36)=-=-
High-Level Specification modified.
--- /tmp/wklog.43.old.30883     2009-08-11 19:36:45.000000000 +0300
+++ /tmp/wklog.43.new.30883     2009-08-11 19:36:45.000000000 +0300
@@ -1 +1,12 @@
+Table definition ca looks like following
 
+CREATE TABLE table
+  (field int ... field_opt1=fval1 field_opt2=fval2,
+   key key1(field) key_opt1=kval1 key_opt2=kval2)
+   table_option1=tval1, table_option2=tval2;
+
+Exclusion should be made for old table and key (KEY_BLOCK_SIZE) options where
+'=' was not obligatory.
+
+For fields options can go with field attributes (NOT NULL, UNIQUE and so on) can
+be separated from them by '=' sign.



DESCRIPTION:

Add ability to create table with additional option which can be passed to engine.

Also make current options such as TRANSACTIONAL working via this mechanism.


HIGH-LEVEL SPECIFICATION:



Table definition will look like the following:

CREATE TABLE table
  (field int ... field_opt1=fval1 field_opt2=fval2,
   key key1(field) key_opt1=kval1 key_opt2=kval2)
   table_option1=tval1, table_option2=tval2;

Exceptions should be made for old table and key options where
'=' was not obligatory. These options will behave as they did,
no changes from the user point of view.

Old key options:
KEY_BLOCK_SIZE <num> -> KEY_BLOCK_SIZE=num
WITH PARSER <name> -> PARSER=name

Old table options:
ENGINE name ->  ENGINE=name
TYPE name -> TYPE=name
MAX_ROWS num -> MAX_ROWS=num
MIX_ROWS num -> MIX_ROWS=num
AVG_ROW_LENGTH num -> AVG_ROW_LENGTH=num
PASSWORD string -> PASSWORD=string
COMMENT string -> COMMENT=string
AUTO_INCREMENT num -> AUTO_INCREMENT=num
PACK_KEYS num/default -> PACK_KEYS=num/default
CHECKSUM num -> CHECKSUM=num
TABLE_CHECKSUM num -> TABLE_CHECKSUM=num
PAGE_CHECKSUM num -> PAGE_CHECKSUM=num
DELAY_KEY_WRITE num -> DELAY_KEY_WRITE=num
ROW_FORMAT name -> ROW_FORMAT=name
INSERT_METHOD name -> INSERT_METHOD=name
KEY_BLOCK_SIZE num -> KEY_BLOCK_SIZE=num
TRANSACTIONAL num -> TRANSACTIONAL=num

Table options which will be left hardcoded
UNION
default charset
default collation
DATA DIRECTORY
INDEX DIRECTORY
TABLESPACE
STORAGE

Incorrect option during creation/altering table lead only to a warning.
Strict mode makes them errors, as expected.
When opening a table all unrecognised options should be ignored.


LOW-LEVEL DESIGN:



Options stored in a list as pairs key, value which are LEX_STRING.

Handler have access to the options during creation and after opening frm.




ESTIMATED WORK TIME

ESTIMATED COMPLETION DATE
-----------------------------------------------------------------------
WorkLog (v3.5.9)