Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-22-2021 06:58 AM
Problem is that you can list all files in workspace only via API call and than you can run every one of them using:
dbutils.notebook.run()
This is the script to list files from workspace (probably you need to add some filterning):
import requests
ctx = dbutils.notebook.entry_point.getDbutils().notebook().getContext()
host_name = ctx.tags().get("browserHostName").get()
host_token = ctx.apiToken().get()
response = requests.post(
f'https://{host_name}/api/2.0/workspace/list',
headers={'Authorization': f'Bearer {host_token}'},
data = {'path': '<your-path>'}
).json()
My blog: https://databrickster.medium.com/