< Back
New-ADSWorkBookCell
Post
NAME New-ADSWorkBookCell
SYNOPSIS
Creates a cell for an Azure Data Studio Notebook
SYNTAX
New-ADSWorkBookCell [-Type] <String> [-Text] <String> [-Collapse] [<CommonParameters>]
DESCRIPTION
Creates a text (markdown) or code (T-SQL) cell for an Azure Data Studio Notebook
PARAMETERS
-Type <String>
The type of cell to create (code or text)
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Text <String>
The value for the cell (markdown for text and T-SQL for celll)
Required? true
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Collapse [<SwitchParameter>]
Should the code cell be collapsed
Required? false
Position? named
Default value False
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
NOTES
Rob Sewell 10/10/2019 - Initial
Rob Sewell 19/11/2019 - Added Collapse parameter
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>$introCelltext = "# Welcome to my Auto Generated Notebook
## Automation
Using this we can automate the creation of notebooks for our use
"
$Intro = New-ADSWorkBookCell -Type Text -Text $introCelltext
Creates an Azure Data Studio Text cell and sets it to a variable for passing to New-AdsWorkBook
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>$thirdcelltext = "SELECT Name
FROM sys.server_principals
WHERE is_disabled = 0"
$Third = New-ADSWorkBookCell -Type Code -Text $thirdcelltext
Creates an Azure Data Studio Code cell which will be collapsed and sets it to a variable for passing to
New-AdsWorkBook
RELATED LINKS
SYNOPSIS
Creates a cell for an Azure Data Studio Notebook
SYNTAX
New-ADSWorkBookCell [-Type] <String> [-Text] <String> [-Collapse] [<CommonParameters>]
DESCRIPTION
Creates a text (markdown) or code (T-SQL) cell for an Azure Data Studio Notebook
PARAMETERS
-Type <String>
The type of cell to create (code or text)
Required? true
Position? 1
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Text <String>
The value for the cell (markdown for text and T-SQL for celll)
Required? true
Position? 2
Default value
Accept pipeline input? false
Accept wildcard characters? false
-Collapse [<SwitchParameter>]
Should the code cell be collapsed
Required? false
Position? named
Default value False
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
NOTES
Rob Sewell 10/10/2019 - Initial
Rob Sewell 19/11/2019 - Added Collapse parameter
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>$introCelltext = "# Welcome to my Auto Generated Notebook
## Automation
Using this we can automate the creation of notebooks for our use
"
$Intro = New-ADSWorkBookCell -Type Text -Text $introCelltext
Creates an Azure Data Studio Text cell and sets it to a variable for passing to New-AdsWorkBook
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>$thirdcelltext = "SELECT Name
FROM sys.server_principals
WHERE is_disabled = 0"
$Third = New-ADSWorkBookCell -Type Code -Text $thirdcelltext
Creates an Azure Data Studio Code cell which will be collapsed and sets it to a variable for passing to
New-AdsWorkBook
RELATED LINKS