cancel
Showing results forย 
Search instead forย 
Did you mean:ย 
Data Engineering
cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

Drop array in a struct field

William_Scardua
Valued Contributor

Hi guys,

look my table definition

Screenshot 2024-04-02 at 19.03.38.png

well, I need to remove 'med array' inside that 'equip' field.

have any idea ?

Thank you

2 REPLIES 2

Sampath_Kumar
New Contributor II

Hi William,

There is array_remove method that can help to remove the elements from an array. Here med array is an element in equip array.

If it not helpful, please share some sample data so that we can solve it together.

Reference: array_remove

Thanks

Hi Sampath,

In fact, I need to change this field in the table structure ... so, I need to apply an 'alter table' to remove the 'med' array from the 'equip' field.

Welcome to Databricks Community: Lets learn, network and celebrate together

Join our fast-growing data practitioner and expert community of 80K+ members, ready to discover, help and collaborate together while making meaningful connections. 

Click here to register and join today! 

Engage in exciting technical discussions, join a group with your peers and meet our Featured Members.