summaryrefslogtreecommitdiff
path: root/Docs/internals.texi
diff options
context:
space:
mode:
authorunknown <monty@narttu.mysql.fi>2003-03-19 21:43:41 +0200
committerunknown <monty@narttu.mysql.fi>2003-03-19 21:43:41 +0200
commit0847c4f90e732378b6e4b37fe819c92bda870067 (patch)
treef73f6b61f529766ab03043b3abb2c0584e9b0643 /Docs/internals.texi
parentcd4d7716f8b7638c11bde9861c21f5a0517ac416 (diff)
downloadmariadb-git-0847c4f90e732378b6e4b37fe819c92bda870067.tar.gz
Print right hostname or IP in SHOW PROCESSLIST
Use SESSION TABLE_HANDLER as default table handler if given table handler doesn't exists Docs/internals.texi: Updated description for how DATE, TIME and TIMESTAMP are stored mysql-test/r/create.result: New tests mysql-test/t/create.test: New tests sql/handler.cc: Use SESSION TABLE_HANDLER as default table handler if given table handler doesn't exists. sql/sql_parse.cc: Fix that we return hostname instead of IP in SHOW PROCESSLIST sql/sql_show.cc: Print right hostname or IP in SHOW PROCESSLIST
Diffstat (limited to 'Docs/internals.texi')
-rw-r--r--Docs/internals.texi19
1 files changed, 11 insertions, 8 deletions
diff --git a/Docs/internals.texi b/Docs/internals.texi
index 1f90b8d1999..686ecd27fda 100644
--- a/Docs/internals.texi
+++ b/Docs/internals.texi
@@ -2213,11 +2213,11 @@ Storage: same as TINYINT.
@strong{DATE}
@itemize @bullet
@item
-Storage: fixed-length series of binary integers, always three bytes
-long.
+Storage: 3 byte integer, low byte first.
+Packed as: 'day + month*32 + year*16*32'
@item
-Example: a DATE column containing '0001-01-01' looks like:@*
-@code{hexadecimal 21 02 00}
+Example: a DATE column containing '1962-01-02' looks like:@*
+@code{hexadecimal 22 54 0F}
@end itemize
@strong{DATETIME}
@@ -2236,16 +2236,19 @@ Example: a DATETIME column for '0001-01-01 01:01:01' looks like:@*
@strong{TIME}
@itemize @bullet
@item
-Storage: a value offset from 8385959, always three bytes long.
+Storage: 3 bytes, low byte first.
+This is stored as seconds: days*24*3600+hours*3600+minutes*60+seconds
@item
-Example: a TIME column containing '01:01:01' looks like:@*
-@code{hexadecimal 75 27 00}
+Example: a TIME column containing '1 02:03:04' (1 day 2 hour 3 minutes and 4 seconds) looks like:@*
+@code{hexadecimal 58 6E 01}
@end itemize
@strong{TIMESTAMP}
@itemize @bullet
@item
-Storage: four bytes long (NOTE TO SELF: not figured out)
+Storage: 4 bytes, low byte first.
+Stored as unix @code{time()}, which is seconds since the Epoch
+(00:00:00 UTC, January 1, 1970).
@item
Example: a TIMESTAMP column containing '2003-01-01 01:01:01' looks like:@*
@code{hexadecimal 4D AE 12 23}