29 #include "dict0boot.ic"
55 block =
buf_page_get(DICT_HDR_SPACE, 0, DICT_HDR_PAGE_NO,
57 header = DICT_HDR + buf_block_get_frame(block);
59 buf_block_dbg_add_level(block, SYNC_DICT_HEADER);
116 dict_hdr_flush_row_id(
void)
119 dict_hdr_t* dict_hdr;
147 dict_hdr_t* dict_header;
155 DICT_HDR + DICT_HDR_FSEG_HEADER, mtr);
164 DICT_HDR_FIRST_ID, mtr);
167 DICT_HDR_FIRST_ID, mtr);
170 DICT_HDR_FIRST_ID, mtr);
184 DICT_HDR_SPACE, 0, DICT_TABLES_ID,
206 DICT_HDR_SPACE, 0, DICT_COLUMNS_ID,
217 DICT_HDR_SPACE, 0, DICT_INDEXES_ID,
228 DICT_HDR_SPACE, 0, DICT_FIELDS_ID,
252 dict_hdr_t* dict_hdr;
281 DICT_HDR_ROW_ID_WRITE_MARGIN);
303 table->
id = DICT_TABLES_ID;
315 index->
id = DICT_TABLES_ID;
322 ut_a(error == DB_SUCCESS);
329 index->
id = DICT_TABLE_IDS_ID;
332 + DICT_HDR_TABLE_IDS,
335 ut_a(error == DB_SUCCESS);
348 table->
id = DICT_COLUMNS_ID;
361 index->
id = DICT_COLUMNS_ID;
367 ut_a(error == DB_SUCCESS);
381 #if DICT_SYS_INDEXES_PAGE_NO_FIELD != 6 + 2
382 #error "DICT_SYS_INDEXES_PAGE_NO_FIELD != 6 + 2"
384 #if DICT_SYS_INDEXES_SPACE_NO_FIELD != 5 + 2
385 #error "DICT_SYS_INDEXES_SPACE_NO_FIELD != 5 + 2"
387 #if DICT_SYS_INDEXES_TYPE_FIELD != 4 + 2
388 #error "DICT_SYS_INDEXES_TYPE_FIELD != 4 + 2"
390 #if DICT_SYS_INDEXES_NAME_FIELD != 2 + 2
391 #error "DICT_SYS_INDEXES_NAME_FIELD != 2 + 2"
394 table->
id = DICT_INDEXES_ID;
406 index->
id = DICT_INDEXES_ID;
412 ut_a(error == DB_SUCCESS);
421 table->
id = DICT_FIELDS_ID;
433 index->
id = DICT_FIELDS_ID;
439 ut_a(error == DB_SUCCESS);
463 dict_insert_initial_data(
void)
480 dict_hdr_create(&mtr);
486 dict_insert_initial_data();
dict_table_t * sys_tables
UNIV_INTERN void dict_mem_index_add_field(dict_index_t *index, const char *name, ulint prefix_len)
UNIV_INTERN void dict_table_add_to_cache(dict_table_t *table, mem_heap_t *heap)
dict_table_t * sys_fields
UNIV_INTERN void dict_load_sys_table(dict_table_t *table)
UNIV_INTERN ibool fil_assign_new_space_id(ulint *space_id)
dict_table_t * sys_columns
UNIV_INTERN void ibuf_init_at_db_start(void)
UNIV_INTERN void mlog_write_ulint(byte *ptr, ulint val, byte type, mtr_t *mtr)
UNIV_INTERN dict_index_t * dict_mem_index_create(const char *table_name, const char *index_name, ulint space, ulint type, ulint n_fields)
UNIV_INTERN void dict_create(void)
#define mem_heap_free(heap)
UNIV_INTERN dict_hdr_t * dict_hdr_get(mtr_t *mtr)
UNIV_INTERN ulint btr_create(ulint type, ulint space, ulint zip_size, index_id_t index_id, dict_index_t *index, mtr_t *mtr)
UNIV_INLINE ulint buf_block_get_page_no(const buf_block_t *block) __attribute__((pure))
UNIV_INTERN void mtr_commit(mtr_t *mtr) __attribute__((nonnull))
UNIV_INTERN void dict_hdr_get_new_id(table_id_t *table_id, index_id_t *index_id, ulint *space_id)
dict_table_t * sys_indexes
UNIV_INTERN ulint mtr_read_ulint(const byte *ptr, ulint type, mtr_t *mtr)
UNIV_INTERN void mlog_write_ull(byte *ptr, ib_uint64_t val, mtr_t *mtr)
UNIV_INTERN dict_table_t * dict_mem_table_create(const char *name, ulint space, ulint n_cols, ulint flags)
UNIV_INLINE ib_uint64_t ut_uint64_align_up(ib_uint64_t n, ulint align_no)
#define mem_heap_create(N)
UNIV_INTERN void dict_mem_table_add_col(dict_table_t *table, mem_heap_t *heap, const char *name, ulint mtype, ulint prtype, ulint len)
UNIV_INTERN ulint dict_index_add_to_cache(dict_table_t *table, dict_index_t *index, ulint page_no, ibool strict)
UNIV_INLINE void mem_heap_empty(mem_heap_t *heap)
UNIV_INTERN buf_block_t * fseg_create(ulint space, ulint page, ulint byte_offset, mtr_t *mtr)
UNIV_INLINE void mtr_start(mtr_t *mtr) __attribute__((nonnull))
UNIV_INTERN void dict_boot(void)
UNIV_INLINE ib_uint64_t mach_read_from_8(const byte *b) __attribute__((nonnull
UNIV_INTERN void dict_init(void)
dict_index_t * dict_ind_redundant
#define buf_page_get(SP, ZS, OF, LA, MTR)