Details
Description
Issues to solve:
- read/write: that's easy, the plugin provides some kind of a "store" method that serializes the data into something that can be memcmp-ed. And "val" methods as appropriate.
- indexing: not at issue, the engine thinks the column type is BINARY and indexes is accordingly
- don't forget that field definition may use parameters, like in VARCHAR(10)
- protocol
- text protocol - what to send as field metadata? variant: MYSQL_TYPE_PLUGIN and a string with the type name
- binary protocol - how to send the value to the client: variant: as a string. how the client send the value to the server? either way, the server converts it from number/string/etc just as for INSERTs
- replication, RBR
- similar, use MYSQL_TYPE_PLUGIN, and as additional metadata - field type as a string, parameters, whatever
So, a plugin would need to provide
- store() method from at least some of the basic types
- val() methods to at least some of the basic types
- description of whatever parameters a field definition takes
- informational methods, like store_length(), etc
This task doesn't cover everything! It is assumed that we can expand this API later to add more features. In particular, the following is not solved:
- data types that cannot be efficiently memcmp()'ed. For example, this proposal doesn't allow to implement a string type with charset support.
- data types that require special indexes, such as XML, spatial data, etc.
see also the original issue description in the history
Gliffy Diagrams
Attachments
Issue Links
- blocks
-
MDEV-8092 Change Create_field::field from "const char *" to LEX_CSTRING
-
- Open
-
-
MDEV-4913 External ENUM Field definition
-
- Open
-
- duplicates
-
MDEV-7931 Custom types support through extensions
-
- Closed
-
- is blocked by
-
MDEV-8095 Split Create_field
-
- Open
-
- relates to
-
MDEV-4958 Adding datatype UUID
-
- Open
-
-
MDEV-4405 Dynamic Columns compression
-
- Open
-
-
MDEV-4631 CassandraSE: Encrypted column data type
-
- Open
-
-
MDEV-274 The data type for IPv6/IPv4 addresses in MariaDB
-
- Stalled
-
-
MDEV-5593 Feature request native support for UUID's as a column type
-
- Closed
-
- links to
Activity
- All
- Comments
- Work Log
- History
- Activity
- Transitions
We have some nice field type in PostgreSQL
THE MAIN PROBLEM ABOUT THIS PLUGIN IS A NOT STANDARD ABOUT FIELD TYPES...
for example XML functions of MYSQL 5.7 want a VARCHAR/CHAR/TEXT/BLOB as parameter, and a XML type could make some incompatibility...
well more definition is need before add more considerations...