sql azure 语法

Microsoft supports SQL Notebooks in Azure Data Studio. It is an exciting feature that allows creating a notebook for multiple languages such as Python, SQL, PowerShell. You might have heard about the Jupyter notebook. It is a popular web-based notebook that provides rich programming language support. SQL Notebook is an inspiration for the Jupyter notebook.

Microsoft在Azure Data Studio中支持SQL Notebook。 这是一项令人兴奋的功能,它允许为多种语言(例如Python,SQL,PowerShell)创建笔记本。 您可能听说过Jupyter笔记本。 它是一种流行的基于Web的笔记本,可提供丰富的编程语言支持。 SQL Notebook是Jupyter笔记本的灵感来源。

To follow along nicely, I would recommend going through the below articles:

为了更好地遵循,我建议您阅读以下文章:

  • SQL Notebooks introduction and overview SQL Notebook简介和概述
  • A handy SQL Notebook for troubleshooting in Azure Data Studio 方便SQL笔记本,用于在Azure Data Studio中进行故障排除
  • Use Python SQL scripts in SQL Notebooks of Azure Data Studio 在Azure Data StudioSQL笔记本中使用Python SQL脚本

You should also use the latest version of Azure Data Studio.

您还应该使用最新版本的Azure Data Studio。

  • Latest version: 1.15.0 最新版本:1.15.0
  • Release date: February 15, 2020 发布日期:2020年2月15日
  • Microsoft Microsoft

Download the installer per the platform: Windows, macOS or Linux.

根据平台下载安装程序:Windows,macOS或Linux。

Markdown语言概述 (Overview of Markdown language)

SQL Notebooks uses markdown language for text formatting. If you are familiar with GitHub, it uses markdown language for all forms such as read me file. We can do text formatting with its simplified method. It helps us to write easy-to-read, easy-to-write plain text with structurally valid XHTML.

SQL Notebook使用Markdown语言进行文本格式设置。 如果您熟悉GitHub,它将对所有形式(如自述文件)使用markdown语言。 我们可以使用其简化方法进行文本格式化。 它有助于我们使用结构有效的XHTML编写易于阅读,易于编写的纯文本。

HTML is a popular programming language. We use tags in HTML for defining text into various formats. For example, for a H1 heading, we use <h1>Title</h1> tags.

HTML是一种流行的编程语言。 我们使用HTML中的标签将文本定义为各种格式。 例如,对于H1标题,我们使用<h1> Title </ h1>标签。

Launch Azure Data Studio and open a SQL notebook.

启动Azure Data Studio并打开一个SQL笔记本。

It opens a blank notebook, as shown below.

它将打开一个空白笔记本,如下所示。

Click on +Text and it opens a text block for you.

单击+文本,它将为您打开一个文本块。

Let’s do various formatting using markdown language.

让我们使用markdown语言进行各种格式化。

格式标题 (Format Headings)

The first step for a document is heading. We also require heading for different sections in the article. We want a different size for the headings and subheadings.

文档的第一步是标题。 我们还要求前往本文的不同部分。 我们希望标题和子标题的大小不同。

We use hash sign (#) preceding with the text and the number of # defines the heading font level. It supports up to six levels of headings.

我们在文本之前使用井号(#),并且#的数目定义了标题字体级别。 它最多支持六个级别的标题。

You can view difference in these heading font size in the following image.

您可以在下图中查看这些标题字体大小的差异。

# SQL Notebook 

#SQL笔记本

## SQL Notebook

## SQL笔记本

### SQL Notebook

### SQL笔记本

#### SQL Notebook

#### SQL笔记本

##### SQL Notebook

##### SQL笔记本

###### SQL Notebook

###### SQL笔记本

We can also use the following markdown code for first and second-level headings.

我们还可以将以下markdown代码用于第一和第二级标题。

SQL Notebooks

SQL笔记本

=======

=======

SQL Notebooks

SQL笔记本

———-

————

添加段落 (Add Paragraphs )

We write documents in many paragraphs. To specify a paragraph in the markdown language, leave an empty line. In the following example, we give an empty line after Hello but did not give any empty line after team. In the output, markdown language understands an empty line at the end of the paragraph. It treats the last two lines as a single paragraph.

我们在许多段落中编写文档。 要使用降价语言指定段落,请留空行。 在以下示例中,我们在Hello后面给出一个空行,但在team之后不给出任何空行。 在输出中,降价语言可以理解段落末尾的空行。 它将最后两行视为一个段落。

格式化粗体文字 (Format Bold text)

We can enclose the text in double star( **), and it highlights text in bold format.

我们可以将文本括在双星号(**)中,并以粗体突出显示文本。

格式化斜体文字 (Format Italic text)

Enclose the text in single star(*) and it changes the format for text in italic.

将文本括在单星号(*)中,它将更改斜体文本的格式。

设置粗体和斜体文本 (Format Bold and Italic text)

We can combine both bold and italic format for text by enclosing text with three starts ***

我们可以通过用三个开始将文本括起来来将文本的粗体和斜体格式组合在一起** *

在笔记本中创建项目符号列表 (Create bullet lists in the notebook)

You might be familiar with creating bullet lists in Microsoft Word document. We can create similar lists using markdown language.

您可能熟悉在Microsoft Word文档中创建项目符号列表。 我们可以使用markdown语言创建类似的列表。

无序列表 (Unordered lists)

Use prefix * followed by a space for the unordered lists. We can also create a nested list using this prefix.

使用前缀*,后跟一个空格表示无序列表。 我们还可以使用此前缀创建嵌套列表。

In the above image, feature 1 and feature 2 are at the same level. Due to this, in markdown, we get a similar bullet for both.

在上图中,特征1和特征2处于同一级别。 因此,在降价促销中,我们为两者获得了类似的项目符号。

We can create a further nested list by changing the position of the text, as shown below.

我们可以通过更改文本的位置来创建另一个嵌套列表,如下所示。

订购清单 (Ordered list)

The ordered list shows the sequence number for each line. We specify a number for each line, and it creates an ordered list.

有序列表显示每行的序列号。 我们为每行指定一个数字,并创建一个有序列表。

We can easily configure both ordered and unordered list combining both stars (*) and numbers as shown below

我们可以轻松地配置星号(*)和数字相结合的有序列表和无序列表,如下所示

码 (Code)

We can add a word as a code format by enclosing it in backticks (`).

我们可以通过将单词括在反引号(`)中来将其添加为代码格式。

块引用 (Blockquotes)

We can add a greater than(>) symbol in beginning of a paragraph, and it turns into a blockquote element.

我们可以在段落的开头添加一个大于(>)符号,它变成一个blockquote元素。

To add multiple lines in the same blockquote, add > in each line.

要在同一blockquote中添加多行,请在每行中添加>。

嵌套块引用 (Nested Blockquotes)

Sometimes you require nested blockquotes as well. We can add >> for the nested blockquotes as shown below.

有时您也需要嵌套的blockquotes。 我们可以添加>>作为嵌套块引用,如下所示。

指定URL超链接 (Specifying URL hyperlink)

Sometimes, we include hyperlinks in a document as well so that users can click on the hyperlink and go to the reference website.

有时,我们还会在文档中包含超链接,以便用户可以单击超链接并转到参考网站。

We can create both inline and reference style links using the markdown language.

我们可以使用markdown语言创建内联和参考样式链接。

内联超链接 (Inline hyperlink)

Inline hyperlinks are similar to a word document hyperlink. We specify it in the following format.

内联超链接类似于Word文档超链接。 我们以以下格式指定它。

[Text to display] (URL)

[显示的文字](URL)

参考样式链接 (Reference Style Links)

We can also create a referenced style links in markdown language. Suppose we want to use the same URL hyperlink in multiple places like reference articles from Microsoft Word. We can either create an inline hyperlink each time or use a reference style hyperlink.

我们还可以使用markdown语言创建引用的样式链接。 假设我们想在多个地方使用相同的URL超链接,例如Microsoft Word的参考文章。 我们可以每次创建一个内联超链接,也可以使用引用样式超链接。

In the following example, we specify [Link 1] text multiple time and later referenced that text for the URL. It saves efforts for us to specify inline hyperlink and users can also know that all these references are from a single URL. You can see these reference style hyperlink on a website like Wikipedia.

在以下示例中,我们多次指定[Link 1]文本,然后在URL中引用该文本。 它为我们节省了指定内联超链接的工作,用户还可以知道所有这些引用均来自单个URL。 您可以在类似Wikipedia的网站上看到这些参考样式超链接。

图片参考 (Image reference)

We can reference an image using an exclamation mark (!) symbol and add an alt-text in the square brackets along with the image URL. In the following example, we can see the Wikipedia logo in SQL Notebook using markdown language.

我们可以使用感叹号(!)符号引用图像,并在方括号中添加替代文本以及图像URL。 在下面的示例中,我们可以使用markdown语言在SQL Notebook中看到Wikipedia徽标。

![Wikipedia](https://upload.wikimedia.org/wikipedia/en/8/80/Wikipedia-logo-v2.svg “Wikipedia”)

![Wikipedia](https://upload.wikimedia.org/wikipedia/en/8/80/Wikipedia-logo-v2.svg“ Wikipedia”)

We can also create a reference style image reference in the markdown similar to the reference URL. For this, we can use the below format.

我们还可以在markdown中创建类似于参考网址的参考样式图片参考。 为此,我们可以使用以下格式。

[logo]: https://upload.wikimedia.org/wikipedia/en/8/80/Wikipedia-logo-v2.svg “Wikipedia”
![wikipedia][logo]

[徽标]:https://upload.wikimedia.org/wikipedia/en/8/80/Wikipedia-logo-v2.svg“ Wikipedia”
![wikipedia] [徽标]

添加水平尺 (Add Horizontal Rule)

We can create a horizontal rule by enclosing text *** symbol(three or more) followed by a line break. You can see a horizontal rule in the below image.

我们可以通过将文字***符号(三个或更多个)后接换行符来创建水平尺。 您可以在下图中看到水平尺。

在文本中指定电子邮件 (Specify email in the text)

We can enclose email address in <> symbol so that it appears as a hyperlink in the output.

我们可以将电子邮件地址括在<>符号中,以便其在输出中显示为超链接。

转义字符 (Escape characters)

As I explained earlier, we use * for an unordered list. Suppose we want to print this character as well in the output. In this case, add a backslash to skip the behavior of * in markdown language.

如前所述,我们将*用于无序列表。 假设我们还要在输出中打印此字符。 在这种情况下,请添加反斜杠以跳过Markdown语言中*的行为。

在笔记本中添加表格 (Add Tables in a notebook)

Markdown does not specify code for tables, but still, we can create them.

Markdown并没有为表指定代码,但是我们仍然可以创建它们。

  • We use colons to align the columns 我们使用冒号对齐列
  • We require at least three dashes to separate column headers 我们需要至少三个破折号来分隔列标题
  • We can use outer pips for separating columns 我们可以使用外部点来分隔列

Here is the markup code for an employee table with three columns- EmployeeName, Location and designation.

这是一个雇员表的标记代码,该表具有三列-EmployeeName,Location和designation。

| EmployeeName        | Location           | Designation  |

| 员工姓名| 位置| 名称

| ————- |:————-:| —–:|

| ————- | |:————-:| -:|

| Rajendra Gupta      | India | Sr. Consultant |

| Rajendra Gupta | 印度| 高级顾问|

| Kusum Agarwal      | India     |   Physiotherapist |

| Kusum Agarwal | 印度| 物理治疗师|

| Akshita Gupta | India    |    Intern |

| Akshita Gupta | 印度| 实习生|

在笔记本中添加视频 (Add Videos in the notebook)

We do not have a direct method to add a video link in the markdown language. But, there is always a workaround.

我们没有直接方法以降价语言添加视频链接。 但是,总有一种解决方法。

Follow the below steps to add a video reference in SQL notebook.

请按照以下步骤在SQL Notebook中添加视频参考。

  • Extract a thumbnail of the video you wish to create a reference. You can either take a screenshot of the video or use third-party tools for the thumbnail of it 提取要创建参考的视频的缩略图。 您可以拍摄视频的屏幕截图,也可以使用第三方工具制作视频缩略图
  • Create a reference link for the video 为视频创建参考链接

For this demonstration, I am using the YouTube video link and using an image for thumbnail purposes.

对于此演示,我使用YouTube视频链接并将图像用于缩略图。

[![SQL Server 2019](C:\Users\rajen_000\Pictures\SQL2019.JPG)](http://www.youtube.com/watch?v=mKlAyvvR70I “SQL 2019”)

[![SQL Server 2019](C:\ Users \ rajen_000 \ Pictures \ SQL2019.JPG)](http://www.youtube.com/watch?v=mKlAyvvR70I“ SQL 2019”)

It renders an image, as shown below.

它将渲染图像,如下所示。

Click on the image, and it asks your permission to open the external Website.

单击图像,它会征求您的许可以打开外部网站。

Click open, and it plays the YouTube video in the browser.

单击打开,它将在浏览器中播放YouTube视频。

结论 (Conclusion)

In this article, we explored markdown language to do formatting in a SQL Notebook of Azure Data Studio. I have covered most of the formatting options, and you can combine those for preparing a handbook with better visualization and useful pieces of information.

在本文中,我们探索了降价语言以在Azure Data StudioSQL Notebook中进行格式化。 我已经介绍了大多数格式设置选项,您可以将它们与更好的可视化效果和有用信息结合起来,以编写手册。

翻译自: https://www.sqlshack.com/learn-markdown-language-for-sql-notebooks-in-azure-data-studio/

sql azure 语法

sql azure 语法_在Azure Data Studio中学习用于SQL Notebook的Markdown语言相关推荐

  1. sql azure 语法_在Azure Data Studio中计划SQL笔记本

    sql azure 语法 SQL Notebooks are an interactive way of creating documents, executing T-SQL queries alo ...

  2. sql azure 语法_使用Azure Data Studio从SQL Server数据创建图表

    sql azure 语法 In this article, we will explore charts in an Azure Data Studio using data stored in SQ ...

  3. sql azure 语法_使用Azure Data Studio开发SQL Server数据库

    sql azure 语法 In the previous article, Starting your journey with Azure Data Studio, we put the first ...

  4. sql azure 语法_在Azure中使用SQL Server 2016 CTP3

    sql azure 语法 As the time of the release of the next version of SQL Server is closing in, the cycle o ...

  5. sql azure 语法_使用Azure门户监视安装了SQL Server的Azure计算机

    sql azure 语法 介绍 (Introduction) In this new chapter, we will show how to use the Microsoft Portal to ...

  6. sql azure 语法_Azure Data Studio中SQL代码段

    sql azure 语法 This article will fully cover the code snippet SQL developer productivity feature in Az ...

  7. sql azure 语法_方便SQL笔记本,用于在Azure Data Studio中进行故障排除

    sql azure 语法 This article prepares a handy SQL Notebook for DBAs. You can use this notebook to troub ...

  8. sql azure 语法_深入了解Azure Data Studio:扩展和Azure SQL DB开发

    sql azure 语法 In the previous articles listed below, we went through the Azure Data Studio tool, star ...

  9. sql azure 语法_Azure Data Studio中SQL Server Profiler

    sql azure 语法 In this article, we will explore SQL Server Profiler in Azure Data Studio in detail inc ...

最新文章

  1. DataAccessResourceFailureException异常解决方法
  2. iphone6 iphone6 plus 放大显示模式高分辨率模式问题
  3. numpy matplotlib
  4. 《系统集成项目管理工程师》必背100个知识点-98大数据的特点
  5. 在C ++应用程序中使用Designer UI文件
  6. svn服务器搭建和使用_简单使用nodejs搭建一个静态服务器
  7. 重启php-fpm的方法
  8. python语言基本认识_Python基础语法合集——了解python
  9. [转载] boost python numpy_boost.python 与 boost.numpy安装的一些注意事项
  10. (PPT)Linux服务器基础
  11. 随身WiFi刷OPENWRT作为旁路由
  12. Mac VM 虚拟机固定IP
  13. 如何在word中安装grammarly
  14. SpringBoot+SpringSecurity+Thymeleaf 演示CSRF攻击
  15. html 实现自动填表
  16. 【数据结构】广义表的存储结构及基本运算(C语言)
  17. xds510 usb2.0驱动
  18. SQL server windows 和 sql server 身份验证设置问题
  19. 通信算法之148: Log-likelihood Ratio (LLR) Demodulation
  20. 播放量比平时高10倍,建议收藏!在这4个黄金时间段上传视频

热门文章

  1. vue 自学笔记(七) 组件细节问题
  2. [IDDFS+背包] 洛谷P2744 [USACO5.3]量取牛奶Milk Measuring
  3. MyBatis(3):SQL映射
  4. Winform DataGridView中利用WebClient异步加载显示网络地址的图片
  5. 如何在C# 中使用WMI 实现远程查询和共享
  6. 为什么考研的都不是班里最优秀的?
  7. 芯片5nm和7nm有什么差别?CPU已经很小了,可以做大点吗?
  8. 吃核桃仁有什么好处?
  9. 国内三巨头为什么那么成功
  10. 很多人花一大笔钱做APP、小程序