The ML_MODEL_UNLOAD routine
        unloads a model from MySQL HeatWave AutoML. For
        ML_MODEL_UNLOAD parameter
        descriptions, see
        ML_MODEL_UNLOAD.
      
- 
Review the following 
          If you are on MySQL 9.0.0 or higher, you can verify what
          models are currently loaded with the
          ML_MODEL_ACTIVE routine before
          and after unloading the model.
        
- 
If you are on MySQL 9.0.0 or higher, verify what models are currently loaded with the ML_MODEL_ACTIVEroutine.mysql> CALL sys.ML_MODEL_ACTIVE('all', @model_info);
- 
Select the session variable created to view all loaded models. mysql> SELECT JSON_PRETTY(@model_info); +-----------------------------------------------------------+ | JSON_PRETTY(@model_info) | +-----------------------------------------------------------+ | [ { "total model size(bytes)": 50209 }, { "user1": [ { "recommendation_use_case": { "format": "HWMLv2.0", "model_size(byte)": 15609 } }, { "recommendation_use_case2": { "format": "HWMLv2.0", "model_size(byte)": 8766 } }, { "recommendation_use_case3": { "format": "HWMLv2.0", "model_size(byte)": 8402 } }, { "recommendation_use_case4": { "format": "HWMLv2.0", "model_size(byte)": 17432 } } ] } ] | +-----------------------------------------------------------+ 1 row in set (0.0411 sec)
- 
Refer to the appropriate model handle to unload. Alternatively, use the session variable for the model handle. The following example unloads a model by using the model handle: mysql> CALL sys.ML_MODEL_UNLOAD('recommendation_use_case');Where: - recommendation_use_caseis the model handle.
 The following example unloads a model by using the session variable for the model handle: mysql> CALL sys.ML_MODEL_UNLOAD(@recommendation_model);Where: - @recommendation_modelis the assigned session variable for the model handle.
 
- 
If you are on MySQL 9.0.0, run ML_MODEL_ACTIVEagain to confirm the model is successfully unloadedmysql> CALL sys.ML_MODEL_ACTIVE('all', @model_info); mysql> SELECT JSON_PRETTY(@model_info); +-----------------------------------------------------------+ | JSON_PRETTY(@model_info) | +-----------------------------------------------------------+ | [ { "total model size(bytes)": 34600 }, { "user1": [ { "recommendation_use_case2": { "format": "HWMLv2.0", "model_size(byte)": 8766 } }, { "recommendation_use_case3": { "format": "HWMLv2.0", "model_size(byte)": 8402 } }, { "recommendation_use_case4": { "format": "HWMLv2.0", "model_size(byte)": 17432 } } ] } ] | +-----------------------------------------------------------+ 1 row in set (0.0411 sec)The list of loaded models shows the model is unloaded. 
- Review how to Create a Machine Learning Model. 
- Review Machine Learning Use Cases to create machine learning models with sample datasets.