I need to split the content of a pandas column that contain some 'structured' data in many other columns based on content.
The strucure is "column_name1"/"value1"/"column_name2"/"value2"/...
For instance, the word "subscriptions" will become the name of column, and the "sub-id", "sub-id2" will be the values.
Transform this:
| ResourceID |
|---|
| /subscriptions/sub-id/resourceGroups/rg-name/providers/Microsoft.MachineLearningServices/workspaces/work-ml/providers/Microsoft.EventGrid/extensionTopics/default |
| /subscriptions/sub-id2/resourceGroups/rg-name2/providers/Microsoft.Sql/servers/name-sqlserver/databases/name-BD |
Into this:
| subscriptions | resourceGroups | providers | workspaces | servers | providers | extensionTopics | databases |
|---|---|---|---|---|---|---|---|
| sub-id | rg-name | Microsoft.MachineLearningServices | work-ml | NaN | Microsoft.EventGrid | default | NaN |
| sub-id2 | rg-name2 | Microsoft.Sql | NaN | name-sqlserver | NaN | NaN | name-BD |
Any help would be very apreciate.