notebook
Creates, updates, deletes, gets or lists a notebook resource.
Overview
| Name | notebook |
| Type | Resource |
| Id | azure.synapse_artifacts.notebook |
Fields
The following fields are returned by SELECT queries:
- get_notebook
- get_notebooks_by_workspace
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. # pylint: disable=line-too-long |
name | string | The name of the resource. Required. |
| object | Unmatched properties from the message are deserialized to this collection. |
bigDataPool | object | Big data pool reference. |
cells | array | Array of cells of the current notebook. Required. |
description | string | The description of the notebook. |
etag | string | Resource Etag. |
folder | object | The folder that this notebook is in. If not specified, this notebook will appear at the root level. |
metadata | object | Notebook root-level metadata. Required. |
nbformat | integer | Notebook format (major number). Incremented between backwards incompatible changes to the notebook format. Required. |
nbformat_minor | integer | Notebook format (minor number). Incremented for backward compatible changes to the notebook format. Required. |
sessionProperties | object | Session properties. |
targetSparkConfiguration | object | The spark configuration of the spark job. |
type | string | The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. # pylint: disable=line-too-long |
name | string | The name of the resource. Required. |
| object | Unmatched properties from the message are deserialized to this collection. |
bigDataPool | object | Big data pool reference. |
cells | array | Array of cells of the current notebook. Required. |
description | string | The description of the notebook. |
etag | string | Resource Etag. |
folder | object | The folder that this notebook is in. If not specified, this notebook will appear at the root level. |
metadata | object | Notebook root-level metadata. Required. |
nbformat | integer | Notebook format (major number). Incremented between backwards incompatible changes to the notebook format. Required. |
nbformat_minor | integer | Notebook format (minor number). Incremented for backward compatible changes to the notebook format. Required. |
sessionProperties | object | Session properties. |
targetSparkConfiguration | object | The spark configuration of the spark job. |
type | string | The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_notebook | select | notebook_name, endpoint | If-None-Match | Gets a Note Book. |
get_notebooks_by_workspace | select | endpoint | Lists Notebooks. | |
create_or_update_notebook | insert | notebook_name, endpoint, name, properties | If-Match | Creates or updates a Note Book. |
create_or_update_notebook | replace | notebook_name, endpoint, name, properties | If-Match | Creates or updates a Note Book. |
delete_notebook | delete | notebook_name, endpoint | Deletes a Note book. | |
get_notebook_summary_by_work_space | exec | endpoint | Lists a summary of Notebooks. | |
rename_notebook | exec | notebook_name, endpoint | Renames a notebook. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
endpoint | string | The service endpoint host (no scheme). (default: ) |
notebook_name | string | The notebook name. Required. |
If-Match | string | ETag of the Note book entity. Should only be specified for update, for which it should match existing entity or can be * for unconditional update. Default value is None. |
If-None-Match | string | ETag of the Notebook entity. Should only be specified for get. If the ETag matches the existing entity tag, or if * was provided, then no content will be returned. Default value is None. |
SELECT examples
- get_notebook
- get_notebooks_by_workspace
Gets a Note Book.
SELECT
id,
name,
,
bigDataPool,
cells,
description,
etag,
folder,
metadata,
nbformat,
nbformat_minor,
sessionProperties,
targetSparkConfiguration,
type
FROM azure.synapse_artifacts.notebook
WHERE notebook_name = '{{ notebook_name }}' -- required
AND endpoint = '{{ endpoint }}' -- required
AND If-None-Match = '{{ If-None-Match }}'
;
Lists Notebooks.
SELECT
id,
name,
,
bigDataPool,
cells,
description,
etag,
folder,
metadata,
nbformat,
nbformat_minor,
sessionProperties,
targetSparkConfiguration,
type
FROM azure.synapse_artifacts.notebook
WHERE endpoint = '{{ endpoint }}' -- required
;
INSERT examples
- create_or_update_notebook
- Manifest
Creates or updates a Note Book.
INSERT INTO azure.synapse_artifacts.notebook (
name,
properties,
notebook_name,
endpoint,
If-Match
)
SELECT
'{{ name }}' /* required */,
'{{ properties }}' /* required */,
'{{ notebook_name }}',
'{{ endpoint }}',
'{{ If-Match }}'
RETURNING
id,
name,
etag,
properties,
type
;
# Description fields are for documentation purposes
- name: notebook
props:
- name: notebook_name
value: "{{ notebook_name }}"
description: Required parameter for the notebook resource.
- name: endpoint
value: "{{ endpoint }}"
description: Required parameter for the notebook resource.
- name: name
value: "{{ name }}"
description: |
The name of the resource. Required.
- name: properties
description: |
Properties of Notebook. Required.
value:
: "{{ }}"
description: "{{ description }}"
bigDataPool:
type: "{{ type }}"
referenceName: "{{ referenceName }}"
targetSparkConfiguration:
type: "{{ type }}"
referenceName: "{{ referenceName }}"
sessionProperties:
driverMemory: "{{ driverMemory }}"
driverCores: {{ driverCores }}
executorMemory: "{{ executorMemory }}"
executorCores: {{ executorCores }}
numExecutors: {{ numExecutors }}
metadata:
: "{{ }}"
kernelspec:
: "{{ }}"
name: "{{ name }}"
display_name: "{{ display_name }}"
language_info:
: "{{ }}"
name: "{{ name }}"
codemirror_mode: "{{ codemirror_mode }}"
nbformat: {{ nbformat }}
nbformat_minor: {{ nbformat_minor }}
cells:
- : "{{ }}"
cell_type: "{{ cell_type }}"
metadata: "{{ metadata }}"
source: "{{ source }}"
attachments: "{{ attachments }}"
outputs: "{{ outputs }}"
folder:
name: "{{ name }}"
- name: If-Match
value: "{{ If-Match }}"
description: ETag of the Note book entity. Should only be specified for update, for which it should match existing entity or can be * for unconditional update. Default value is None.
description: ETag of the Note book entity. Should only be specified for update, for which it should match existing entity or can be * for unconditional update. Default value is None.
REPLACE examples
- create_or_update_notebook
Creates or updates a Note Book.
REPLACE azure.synapse_artifacts.notebook
SET
name = '{{ name }}',
properties = '{{ properties }}'
WHERE
notebook_name = '{{ notebook_name }}' --required
AND endpoint = '{{ endpoint }}' --required
AND name = '{{ name }}' --required
AND properties = '{{ properties }}' --required
AND If-Match = '{{ If-Match}}'
RETURNING
id,
name,
etag,
properties,
type;
DELETE examples
- delete_notebook
Deletes a Note book.
DELETE FROM azure.synapse_artifacts.notebook
WHERE notebook_name = '{{ notebook_name }}' --required
AND endpoint = '{{ endpoint }}' --required
;
Lifecycle Methods
- get_notebook_summary_by_work_space
- rename_notebook
Lists a summary of Notebooks.
EXEC azure.synapse_artifacts.notebook.get_notebook_summary_by_work_space
@endpoint='{{ endpoint }}' --required
;
Renames a notebook.
EXEC azure.synapse_artifacts.notebook.rename_notebook
@notebook_name='{{ notebook_name }}' --required,
@endpoint='{{ endpoint }}' --required
;