Forum Discussion

FabricGeek's avatar
FabricGeek
New Member
2 years ago
Solved

DDL support in Notebooks

What level of support is there for DDL commands when using the Notebooks with SQL endpoint in a Lakehouse? I am finding that some commands are supported and others aren't. As an example, I could add...
  • v-cboorla-msft's avatar
    v-cboorla-msft
    2 years ago

    Hi FabricGeek 

     

    Thanks for using Microsoft Fabric Community.

    Apologies for the inconvenience that you are facing here.

    Yes, you are correct that DDL support in Notebooks with the SQL endpoint for Microsoft Fabric Lakehouse is currently limited. Some commands work, while others like modifying existing column data types are not yet supported.

     

    Supported : Adding a new column to a Delta Lake table using ALTER TABLE ADD COLUMN syntax within the Notebook. Dropping a column using ALTER TABLE DROP COLUMN syntax within the Notebook.
    For further details, you may refer to the following information, which could be helpful - GuyInACube video.

    Not Supported : Modifying an existing column's data type using ALTER TABLE ALTER COLUMN syntax within the Notebook (This is the specific case you mentioned with ALTER TABLE <MYTABLE> ALTER COLUMN TEST INT).

     

    Understanding the limitations : The limited DDL support in Notebooks with the SQL endpoint is likely due to the underlying architecture. The SQL endpoint translates T-SQL queries to Spark operations, and some DDL operations might not have direct translations.

    For more details, please refer : Limitations.

                                                   

    I hope this informations helps. Please do let us know if you have any further questions.

     

    Thanks.