Shannon-Data / ShannonBase

A MySQL HTAP Database, Open Source version of MySQL Heatwave, Powered by AI.
https://www.shannonbase.org
Other
16 stars 6 forks source link

Feature: sync MYSQL_TYPE_DB_TRX_ID to stored_program_bits.h #172

Open db-lover opened 6 months ago

db-lover commented 6 months ago

Summary When defined a new column type in include/field_types.h, Keep include/mysql/components/services/bits/stored_program_bits.h in sync with it.

As described in include/field_types.h:

/**
  Column types for MySQL
  Note: Keep include/mysql/components/services/bits/stored_program_bits.h in
  sync with this
*/
enum enum_field_types {
  MYSQL_TYPE_DECIMAL,
  MYSQL_TYPE_TINY,
  MYSQL_TYPE_SHORT,
  MYSQL_TYPE_LONG,
  MYSQL_TYPE_FLOAT,
...
...

Description for this feature.

Add types in include/mysql/components/services/bits/stored_program_bits.h

...
#define MYSQL_SP_ARG_TYPE_DB_TRX_ID (1ULL << 21)
#define MYSQL_SP_ARG_TYPE_INVALID (1ULL << 22)
#define MYSQL_SP_ARG_TYPE_BOOL (1ULL << 23)
#define MYSQL_SP_ARG_TYPE_JSON (1ULL << 24)
#define MYSQL_SP_ARG_TYPE_NEWDECIMAL (1ULL << 25)
#define MYSQL_SP_ARG_TYPE_ENUM (1ULL << 26)
#define MYSQL_SP_ARG_TYPE_SET (1ULL << 27)
#define MYSQL_SP_ARG_TYPE_TINY_BLOB (1ULL << 28)
#define MYSQL_SP_ARG_TYPE_MEDIUM_BLOB (1ULL << 29)
#define MYSQL_SP_ARG_TYPE_LONG_BLOB (1ULL << 30)
#define MYSQL_SP_ARG_TYPE_BLOB (1ULL << 31)
#define MYSQL_SP_ARG_TYPE_VAR_STRING (1ULL << 32)
#define MYSQL_SP_ARG_TYPE_STRING (1ULL << 33)
#define MYSQL_SP_ARG_TYPE_GEOMETRY (1ULL << 34)