{"id":9874,"date":"2017-03-21T07:55:15","date_gmt":"2017-03-21T06:55:15","guid":{"rendered":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/"},"modified":"2017-03-21T07:55:15","modified_gmt":"2017-03-21T06:55:15","slug":"sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands","status":"publish","type":"post","link":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/","title":{"rendered":"SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?"},"content":{"rendered":"<p>I wonder how works Dynamic Data Masking (DDM) with these two commands INSERT INTO\u00a0 and SELECT INTO.<\/p>\n<p>First, I create a table and add some \u201csensitive data\u201d:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1\">USE [DDM_TEST]\nGO\n\nCREATE TABLE [dbo].[Confidential](\n[ID] [int] IDENTITY(1,1) NOT NULL PRIMARY KEY CLUSTERED,\n[Name] [nvarchar](70)NULL,\n[CreditCard] [nvarchar](16)NULL,\n[Salary] [int] NULL,\n[Email] [nvarchar](60)NULL)  \n\n\ninsert into [dbo].[Confidential]([Name],[CreditCard],[Salary],[Email]) values (N'Stephane',N'3546748598467584',113459,N'sts@dbi-services.com')\ninsert into [dbo].[Confidential]([Name],[CreditCard],[Salary],[Email]) values (N'David',N'3546746598450989',143576,'dab@dbi-services.com')\ninsert into [dbo].[Confidential]([Name],[CreditCard],[Salary],[Email])  values (N'Nathan',N'3890098321457893',118900,'nac@dbi-services.com')\ninsert into [dbo].[Confidential]([Name],[CreditCard],[Salary],[Email])  values (N'Olivier',N'3564890234785612',98000,'olt@dbi-services.com')\ninsert into [dbo].[Confidential]([Name],[CreditCard],[Salary],[Email])  values (N'Alain',N'9897436900989342',85900,'ala@dbi-services.com')\ninsert into [dbo].[Confidential]([Name],[CreditCard],[Salary],[Email])  values (N'Fabrice',N'908323468902134',102345,'fad@dbi-services.com')\n\nselect * from [dbo].[Confidential]<\/pre>\n<p><a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into01.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-medium wp-image-15347 aligncenter\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into01.png\" alt=\"DDM_Into01\" width=\"300\" height=\"160\" \/><\/a><\/p>\n<p>After, I create all masking rules and add a user:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1\">Use DDM_TEST\nALTER Table Confidential\nALTER COLUMN NAME ADD MASKED WITH (FUNCTION='default()')\nALTER Table Confidential\nALTER COLUMN SALARY ADD MASKED WITH (FUNCTION='default()')\nALTER Table Confidential\nALTER COLUMN creditcard ADD MASKED WITH (FUNCTION='partial(1,\"XXXX\",2)')\nALTER Table Confidential\nALTER COLUMN email ADD MASKED WITH (FUNCTION='email()')\n\nCREATE USER TestDemo WITHOUT LOGIN\nGRANT SELECT ON Confidential TO TestDemo\n\n-- Execute a select statement as TestDemo \nEXECUTE AS USER='TestDemo'\nSELECT * FROM [dbo].[Confidential] \nREVERT<\/pre>\n<p><a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into02.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-medium wp-image-15346 aligncenter\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into02.png\" alt=\"DDM_Into02\" width=\"300\" height=\"164\" \/><\/a><\/p>\n<h3>INSERT INTO<\/h3>\n<p>This command is used to copy a table.<br \/>\nWhat\u2019s happens when I copy data from a table with masked columns to a table without mask?<br \/>\nFirst, I create a second table [dbo].[Confidential2] and give permissions SELECT and INSERT to the user &#8220;TestDemo&#8221;<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1\">USE [DDM_TEST]\nGO\n\nCREATE TABLE [dbo].[Confidential2](\n[ID] [int] IDENTITY(1,1) NOT NULL PRIMARY KEY CLUSTERED,\n[Name] [nvarchar](70)NULL,\n[CreditCard] [nvarchar](16)NULL,\n[Salary] [int] NULL,\n[Email] [nvarchar](60)NULL)  \n\nGRANT SELECT ON Confidential2 TO TestDemo\nGRANT INSERT ON Confidential2 TO TestDemo<\/pre>\n<p>I execute the query to insert data from [dbo].[Confidential] to [dbo].[Confidential2] with the INSERT INTO command:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1\">USE [DDM_TEST]\nGO\nEXECUTE AS USER='TestDemo'\nSELECT * FROM [dbo].[Confidential]\nINSERT INTO [dbo].[Confidential2]([Name],[CreditCard],[Salary],[Email])\n\tSELECT [Name],[CreditCard],[Salary],[Email] FROM [dbo].[Confidential]\nSELECT * FROM [dbo].[Confidential]\nREVERT\n<\/pre>\n<p><a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into03.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-medium wp-image-15345 aligncenter\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into03.png\" alt=\"DDM_Into03\" width=\"300\" height=\"263\" \/><\/a><br \/>\nAs you can see data are also masked in the second table [dbo].[Confidential2].<br \/>\nBut are they really?<br \/>\nI execute the query with the activation on the query plan.<br \/>\n<a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into04.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-medium wp-image-15344 aligncenter\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into04.png\" alt=\"DDM_Into04\" width=\"300\" height=\"148\" \/><\/a><br \/>\nAs you can see the masking step is missing in the query plan from the select on [dbo].[Confidential2].<br \/>\nIf I Select data from [dbo].[Confidential2] with my admin account, data are \u201cmasked data\u201d and not real data&#8230;<br \/>\n<a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into05.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-medium wp-image-15343 aligncenter\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into05.png\" alt=\"DDM_Into05\" width=\"300\" height=\"150\" \/><\/a><br \/>\nFinally, the goal is reached, you cannot read sensitive data if you copy data from a table to another.<br \/>\nKeep in mind that the copied data are not masked for the user.<br \/>\nThese data are copied as &#8220;masked data&#8221; and guarantee the anonymization and a good security for your sensitive data.<br \/>\nBut on the other side, if you use the same WHERE clause in [dbo].[Confidential2], you don\u2019t have the same result\u2026 \ud83d\ude41<br \/>\n<a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into05a.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-medium wp-image-15349 aligncenter\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into05a.png\" alt=\"DDM_Into05a\" width=\"300\" height=\"275\" \/><\/a><\/p>\n<h3>SELECT INTO<\/h3>\n<p>With this command, I test also the copy to a temporary table.<br \/>\nThese two cases will be interesting\u2026<br \/>\nI recreate the same table [dbo].[Confidential] with the same masking rules, the user with create table and alter any schema permissions to do the select into:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1\">EXECUTE AS USER='TestDemo'\nSELECT * FROM [dbo].[Confidential] \nSELECT * INTO [dbo].[Confidential2] FROM [dbo].[Confidential] ;\nREVERT<\/pre>\n<p><a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into06.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-medium wp-image-15342 aligncenter\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into06.png\" alt=\"DDM_Into06\" width=\"300\" height=\"148\" \/><\/a><br \/>\nIn the query plan, you can see that the masking is between the select and the insert.<br \/>\nWe are in the same case as previously: copied data are &#8220;masked data&#8221;.<br \/>\nTo see it, I read data from the table [dbo].[Confidential2] with my sysadmin login:<br \/>\n<a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into07.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-medium wp-image-15341 aligncenter\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into07.png\" alt=\"DDM_Into07\" width=\"300\" height=\"202\" \/><\/a><br \/>\nAnd the result is that all copied data are masked. The data remain anonymous.<\/p>\n<p>Finally, let\u2019s test it with a temporary table and let\u2019s see what happens:<\/p>\n<pre class=\"brush: sql; gutter: true; first-line: 1\">USE [DDM_TEST]\nGO\nEXECUTE AS USER='TestDemo'\nSELECT * FROM [dbo].[Confidential] \nSELECT * INTO #Confidential2 FROM [dbo].[Confidential] ;\nREVERT\nEXECUTE AS USER='TestDemo'\nSELECT * FROM #Confidential2 \nREVERT<\/pre>\n<p><a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into08.png\"><img loading=\"lazy\" decoding=\"async\" class=\" size-medium wp-image-15340 aligncenter\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into08.png\" alt=\"DDM_Into08\" width=\"300\" height=\"251\" \/><\/a><\/p>\n<p>The same query plan is applied and masked data are copied and remained anonymous.<\/p>\n<p>Finally, these two commands INSERT INTO and SELECT INTO keep your data anonymous in the case of a Table copy.<\/p>\n<p>Sorry but cheat mode is disabled \u2026 \ud83d\udc7f<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I wonder how works Dynamic Data Masking (DDM) with these two commands INSERT INTO\u00a0 and SELECT INTO. First, I create a table and add some \u201csensitive data\u201d: USE [DDM_TEST] GO CREATE TABLE [dbo].[Confidential]( [ID] [int] IDENTITY(1,1) NOT NULL PRIMARY KEY CLUSTERED, [Name] [nvarchar](70)NULL, [CreditCard] [nvarchar](16)NULL, [Salary] [int] NULL, [Email] [nvarchar](60)NULL) insert into [dbo].[Confidential]([Name],[CreditCard],[Salary],[Email]) values (N&#8217;Stephane&#8217;,N&#8217;3546748598467584&#8242;,113459,N&#8217;sts@dbi-services.com&#8217;) [&hellip;]<\/p>\n","protected":false},"author":15,"featured_media":9883,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[229],"tags":[49,25,51,566],"type_dbi":[],"class_list":["post-9874","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-database-administration-monitoring","tag-microsoft","tag-security","tag-sql-server","tag-sql-server-2016"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.2 (Yoast SEO v27.4) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?<\/title>\n<meta name=\"description\" content=\"See how Dynamic Data Masking works with INSERT INTO and SELECT INTO commands. in SQL Server 2016\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?\" \/>\n<meta property=\"og:description\" content=\"See how Dynamic Data Masking works with INSERT INTO and SELECT INTO commands. in SQL Server 2016\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/\" \/>\n<meta property=\"og:site_name\" content=\"dbi Blog\" \/>\n<meta property=\"article:published_time\" content=\"2017-03-21T06:55:15+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into08.png\" \/>\n\t<meta property=\"og:image:width\" content=\"680\" \/>\n\t<meta property=\"og:image:height\" content=\"568\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"St\u00e9phane Haby\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"St\u00e9phane Haby\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/\"},\"author\":{\"name\":\"St\u00e9phane Haby\",\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/#\\\/schema\\\/person\\\/d0bfb7484ae81c8980fc2b11334f803b\"},\"headline\":\"SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?\",\"datePublished\":\"2017-03-21T06:55:15+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/\"},\"wordCount\":418,\"commentCount\":0,\"image\":{\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/wp-content\\\/uploads\\\/sites\\\/2\\\/2022\\\/04\\\/DDM_Into08.png\",\"keywords\":[\"Microsoft\",\"Security\",\"SQL Server\",\"SQL Server 2016\"],\"articleSection\":[\"Database Administration &amp; Monitoring\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/\",\"url\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/\",\"name\":\"SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/wp-content\\\/uploads\\\/sites\\\/2\\\/2022\\\/04\\\/DDM_Into08.png\",\"datePublished\":\"2017-03-21T06:55:15+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/#\\\/schema\\\/person\\\/d0bfb7484ae81c8980fc2b11334f803b\"},\"description\":\"See how Dynamic Data Masking works with INSERT INTO and SELECT INTO commands. in SQL Server 2016\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/wp-content\\\/uploads\\\/sites\\\/2\\\/2022\\\/04\\\/DDM_Into08.png\",\"contentUrl\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/wp-content\\\/uploads\\\/sites\\\/2\\\/2022\\\/04\\\/DDM_Into08.png\",\"width\":680,\"height\":568},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Accueil\",\"item\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/\",\"name\":\"dbi Blog\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/#\\\/schema\\\/person\\\/d0bfb7484ae81c8980fc2b11334f803b\",\"name\":\"St\u00e9phane Haby\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1123227ca39a5dca608c0f72d23cd1904fee29979749bbb3a485b9438436c553?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1123227ca39a5dca608c0f72d23cd1904fee29979749bbb3a485b9438436c553?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1123227ca39a5dca608c0f72d23cd1904fee29979749bbb3a485b9438436c553?s=96&d=mm&r=g\",\"caption\":\"St\u00e9phane Haby\"},\"description\":\"St\u00e9phane Haby has more than ten years of experience in Microsoft solutions. He is specialized in SQL Server technologies such as installation, migration, best practices, and performance analysis etc. He is also an expert in Microsoft Business Intelligence solutions such as SharePoint, SQL Server and Office. Futhermore, he has many years of .NET development experience in the banking sector and other industries. In France, he was one of the first people to have worked with Microsoft Team System. He has written several technical articles on this subject. St\u00e9phane Haby is Microsoft Most Valuable Professional (MVP) as well as Microsoft Certified Solutions Associate (MCSA) and\u00a0Microsoft Certified Solutions Expert (MCSE) for SQL Server 2012. He is also Microsoft Certified Technology Specialist (MCTS) and Microsoft Certified IT Professional (MCITP) for SQL Server 2008 as well as ITIL Foundation V3 certified. He holds a Engineer diploma in industrial computing and automation from France. His branch-related experience covers Chemicals &amp; Pharmaceuticals, Banking \\\/ Financial Services, and many other industries.\",\"url\":\"https:\\\/\\\/www.dbi-services.com\\\/blog\\\/author\\\/stephane-haby\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?","description":"See how Dynamic Data Masking works with INSERT INTO and SELECT INTO commands. in SQL Server 2016","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/","og_locale":"en_US","og_type":"article","og_title":"SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?","og_description":"See how Dynamic Data Masking works with INSERT INTO and SELECT INTO commands. in SQL Server 2016","og_url":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/","og_site_name":"dbi Blog","article_published_time":"2017-03-21T06:55:15+00:00","og_image":[{"width":680,"height":568,"url":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into08.png","type":"image\/png"}],"author":"St\u00e9phane Haby","twitter_card":"summary_large_image","twitter_misc":{"Written by":"St\u00e9phane Haby","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/#article","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/"},"author":{"name":"St\u00e9phane Haby","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/d0bfb7484ae81c8980fc2b11334f803b"},"headline":"SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?","datePublished":"2017-03-21T06:55:15+00:00","mainEntityOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/"},"wordCount":418,"commentCount":0,"image":{"@id":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into08.png","keywords":["Microsoft","Security","SQL Server","SQL Server 2016"],"articleSection":["Database Administration &amp; Monitoring"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/","url":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/","name":"SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/#primaryimage"},"image":{"@id":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into08.png","datePublished":"2017-03-21T06:55:15+00:00","author":{"@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/d0bfb7484ae81c8980fc2b11334f803b"},"description":"See how Dynamic Data Masking works with INSERT INTO and SELECT INTO commands. in SQL Server 2016","breadcrumb":{"@id":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/#primaryimage","url":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into08.png","contentUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/DDM_Into08.png","width":680,"height":568},{"@type":"BreadcrumbList","@id":"https:\/\/www.dbi-services.com\/blog\/sql-server-2016-does-dynamic-data-masking-works-with-insert-into-and-select-into-commands\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Accueil","item":"https:\/\/www.dbi-services.com\/blog\/"},{"@type":"ListItem","position":2,"name":"SQL Server 2016: Does Dynamic Data Masking works with INSERT INTO and SELECT INTO commands?"}]},{"@type":"WebSite","@id":"https:\/\/www.dbi-services.com\/blog\/#website","url":"https:\/\/www.dbi-services.com\/blog\/","name":"dbi Blog","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/d0bfb7484ae81c8980fc2b11334f803b","name":"St\u00e9phane Haby","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/1123227ca39a5dca608c0f72d23cd1904fee29979749bbb3a485b9438436c553?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/1123227ca39a5dca608c0f72d23cd1904fee29979749bbb3a485b9438436c553?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/1123227ca39a5dca608c0f72d23cd1904fee29979749bbb3a485b9438436c553?s=96&d=mm&r=g","caption":"St\u00e9phane Haby"},"description":"St\u00e9phane Haby has more than ten years of experience in Microsoft solutions. He is specialized in SQL Server technologies such as installation, migration, best practices, and performance analysis etc. He is also an expert in Microsoft Business Intelligence solutions such as SharePoint, SQL Server and Office. Futhermore, he has many years of .NET development experience in the banking sector and other industries. In France, he was one of the first people to have worked with Microsoft Team System. He has written several technical articles on this subject. St\u00e9phane Haby is Microsoft Most Valuable Professional (MVP) as well as Microsoft Certified Solutions Associate (MCSA) and\u00a0Microsoft Certified Solutions Expert (MCSE) for SQL Server 2012. He is also Microsoft Certified Technology Specialist (MCTS) and Microsoft Certified IT Professional (MCITP) for SQL Server 2008 as well as ITIL Foundation V3 certified. He holds a Engineer diploma in industrial computing and automation from France. His branch-related experience covers Chemicals &amp; Pharmaceuticals, Banking \/ Financial Services, and many other industries.","url":"https:\/\/www.dbi-services.com\/blog\/author\/stephane-haby\/"}]}},"_links":{"self":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/9874","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/users\/15"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/comments?post=9874"}],"version-history":[{"count":0,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/9874\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/media\/9883"}],"wp:attachment":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/media?parent=9874"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/categories?post=9874"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/tags?post=9874"},{"taxonomy":"type","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/type_dbi?post=9874"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}