712
701
virtual Item *idx_cond_push(uint32_t, Item *idx_cond)
713
702
{ return idx_cond; }
716
Part of old fast alter table, to be depricated
719
check_if_incompatible_data(HA_CREATE_INFO *, uint32_t)
720
{ return COMPATIBLE_DATA_NO; }
722
/* On-line ALTER Table interface */
725
Check if a storage engine supports a particular alter table on-line
727
@param altered_table A temporary table show what table is to
729
@param create_info Information from the parsing phase about new
731
@param alter_flags Bitmask that shows what will be changed
732
@param table_changes Shows if table layout has changed (for
733
backwards compatibility with
734
check_if_incompatible_data
736
@retval HA_ALTER_ERROR Unexpected error
737
@retval HA_ALTER_SUPPORTED_WAIT_LOCK Supported, but requires DDL lock
738
@retval HA_ALTER_SUPPORTED_NO_LOCK Supported
739
@retval HA_ALTER_NOT_SUPPORTED Not supported
742
The default implementation is implemented to support fast
743
alter table (storage engines that support some changes by
744
just changing the frm file) without any change in the handler
747
virtual int check_if_supported_alter(Table *, HA_CREATE_INFO *create_info,
748
HA_ALTER_FLAGS * , uint32_t table_changes)
750
if (this->check_if_incompatible_data(create_info, table_changes)
751
== COMPATIBLE_DATA_NO)
752
return(HA_ALTER_NOT_SUPPORTED);
754
return(HA_ALTER_SUPPORTED_WAIT_LOCK);
757
Tell storage engine to prepare for the on-line alter table (pre-alter)
759
@param session The thread handle
760
@param altered_table A temporary table show what table is to
762
@param alter_info Storage place for data used during phase1
764
@param alter_flags Bitmask that shows what will be changed
767
@retval error error code passed from storage engine
769
virtual int alter_table_phase1(Session *, Table *, HA_CREATE_INFO *, HA_ALTER_INFO *,
772
return HA_ERR_UNSUPPORTED;
775
Tell storage engine to perform the on-line alter table (alter)
777
@param session The thread handle
778
@param altered_table A temporary table show what table is to
780
@param alter_info Storage place for data used during phase1
782
@param alter_flags Bitmask that shows what will be changed
785
@retval error error code passed from storage engine
788
If check_if_supported_alter returns HA_ALTER_SUPPORTED_WAIT_LOCK
789
this call is to be wrapped with a DDL lock. This is currently NOT
792
virtual int alter_table_phase2(Session *, Table *, HA_CREATE_INFO *, HA_ALTER_INFO *,
795
return HA_ERR_UNSUPPORTED;
798
Tell storage engine that changed frm file is now on disk and table
799
has been re-opened (post-alter)
801
@param session The thread handle
802
@param table The altered table, re-opened
804
virtual int alter_table_phase3(Session *, Table *)
806
return HA_ERR_UNSUPPORTED;