[{"data":1,"prerenderedAt":367},["ShallowReactive",2],{"article-escape-sequences-and-verbatim-strings-in-c":3},{"article":4,"tags":89,"previous":104,"next":180},{"id":5,"title":6,"author":7,"body":8,"createdAt":77,"description":78,"extension":79,"img":80,"meta":81,"navigation":82,"path":83,"seo":84,"stem":85,"tags":86,"updatedAt":77,"__hash__":88},"articles\u002Farticles\u002Fescape-sequences-and-verbatim-strings-in-c.md","Escape Sequences and Verbatim Strings in C#","[object Object]",{"type":9,"value":10,"toc":73},"minimark",[11,15,18,21,27,30,33,36,39,42,45,48,51,54,57,60,67,70],[12,13,14],"p",{},"C# uses special escape sequences within a string to signify that what follows is to be treated differently.  The special character is the backslash .  This character says to treat whatever follows it as though it were part of the string itself. ",[12,16,17],{},"string msg = \"Spot the dog said: \" get that dog bone\"\";  \u002F\u002F knowing this the following is good syntax:",[12,19,20],{},"Spot the dog said: \"get that dog bone\" \u002F\u002Foutput",[12,22,23],{},[24,25,26],"strong",{},"List of C# Escape Sequences",[12,28,29],{},"\"  Display a double quotation mark",[12,31,32],{},"'   Display a single quotation mark.",[12,34,35],{},"\\  Display a backslash.",[12,37,38],{},"\\0  Null (non-printing).",[12,40,41],{},"\\a  Alarm (beep terminal alarm).",[12,43,44],{},"\\b  Backspace (back up one character position).",[12,46,47],{},"\\f   Form feed (advance to next page).",[12,49,50],{},"\\n  Newline (advance to next line).",[12,52,53],{},"\\r  Carriage return (move to left margin).",[12,55,56],{},"\\t  Tab (advance one tab space, often eight characters).",[12,58,59],{},"\\v  Vertical tab.",[12,61,62,63,66],{},"C# provides a way to avoid 'escaping' characters in strings.  You can use the ",[24,64,65],{},"verbatim string literal","\ncharacter @ to tell VS.NET to build the string exactly as it appears.\nstring msg = @\"go to c:\\temp\"; \u002F\u002F this would work",[12,68,69],{},"The verbatim string can be used to allow a single string to span more than one line i.e.",[12,71,72],{},"string msg = @\"this is great\nto be under\nthe sun\";",{"title":74,"searchDepth":75,"depth":75,"links":76},"",2,[],"2015-04-20T08:07:17.4600000-04:00","Lots of escape sequences in c#","md","\u002Farticles\u002Fimages\u002Fescape.jpg",{},true,"\u002Farticles\u002Fescape-sequences-and-verbatim-strings-in-c",{"title":6,"description":78},"articles\u002Fescape-sequences-and-verbatim-strings-in-c",[87],"aspnet","bVBNvMdJ6cuQ53UFAK93lprV_NldOOv6yHzK6EMFW1I",[90],{"id":91,"title":92,"body":93,"description":97,"extension":79,"img":98,"meta":99,"name":87,"navigation":82,"path":100,"seo":101,"stem":102,"__hash__":103},"tags\u002Ftags\u002Faspnet.md","Aspnet",{"type":9,"value":94,"toc":95},[],{"title":74,"searchDepth":75,"depth":75,"links":96},[],"ASP.NET is an open source web framework, created by Microsoft, for building modern web apps and services with .NET.","https:\u002F\u002Fimages.unsplash.com\u002Fphoto-1598313183973-4effcded8d5e?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=crop&w=675&q=80",{},"\u002Ftags\u002Faspnet",{"description":97},"tags\u002Faspnet","SlUGLdZWQy8mYOWC6OetgJkwVulWNURoVHeuESIDleI",{"id":105,"title":106,"author":7,"body":107,"createdAt":170,"description":171,"extension":79,"img":172,"meta":173,"navigation":82,"path":174,"seo":175,"stem":176,"tags":177,"updatedAt":170,"__hash__":179},"articles\u002Farticles\u002Fenterprise-library-components-4-1-contents-of-the-download.md","Enterprise Library Components 4.1 (Contents of the download)",{"type":9,"value":108,"toc":168},[109,112,119,122,133,136,157],[12,110,111],{},"The default installation folder C:\\Program Files\\Microsoft Enterprise Library 4.1 - October 2008",[113,114,115],"ul",{},[116,117,118],"li",{},"Bin - contains the binaries you can use in the application. ",[12,120,121],{},"Also, the configuration editor EntLibConfig.exe which can be used to create and edit configuration files for EntLib",[113,123,124,127,130],{},[116,125,126],{},"Docs - documentation",[116,128,129],{},"Src - contains the installer file for the Enterprise Library source file",[116,131,132],{},"Visual Studio Integration - contains binaries that make the configuration Editor available in Visual Studio",[12,134,135],{},"The installer also puts the original source code in C:\\EntLib41Src",[113,137,138,141,148,151,154],{},[116,139,140],{},"bin - contains the same as the bin above",[116,142,143,144,147],{},"Blocks - contains a solution that houses all 42 Enterprise Library projects. There is also a second solution that additionally contains unit test projects,\nand the actual unit tests to verify correct working of Enterprise Library as you change it.",[145,146],"br",{},"This is a great value that allows you to feel comfortable editing this pile of code while being able to prove you have not broken anything",[116,149,150],{},"Lib - contains object builder and unity binaries that you can use in your application independent of EntLib",[116,152,153],{},"Quick Starts - contains sample code in both C# and VB.NET that you can use to see available functionality of EntLib and how to use it in your own applications.",[116,155,156],{},"Scripts - contains batch files to amongst others compile EntLib from the source, register assemblies and to install Northwind database for the quick starts",[12,158,159,160,164],{},"Enteprise Library 4.1 can be found ",[161,162],"a",{"title":163,"href":163},"http:\u002F\u002Fmsdn.microsoft.com\u002Fen-us\u002Flibrary\u002Fdd203099.aspx",[161,165,163],{"href":163,"rel":166},[167],"nofollow",{"title":74,"searchDepth":75,"depth":75,"links":169},[],"2015-04-20T08:07:17.5500000-04:00","Learn about Microsoft Enterprise Library","\u002Farticles\u002Fimages\u002FwnzEaKNdyZ.png",{},"\u002Farticles\u002Fenterprise-library-components-4-1-contents-of-the-download",{"title":106,"description":171},"articles\u002Fenterprise-library-components-4-1-contents-of-the-download",[178],"enterpriselibrary","VPzkUCTzFlbTNRdwVqnyU6p2PWmCgYjJgbGSKWQNA1E",{"id":181,"title":182,"author":7,"body":183,"createdAt":357,"description":358,"extension":79,"img":359,"meta":360,"navigation":82,"path":361,"seo":362,"stem":363,"tags":364,"updatedAt":357,"__hash__":366},"articles\u002Farticles\u002Fsql-server-ndash-find-field-value-in-database.md","SQL Server Find Field Value in Database",{"type":9,"value":184,"toc":355},[185,188,191,351],[12,186,187],{},"The following is a SQL Script that can be run in a database to return all tables and columns where a particular value is present. \nThis can be used for strings or values with a small modification.  This type of thing is great when moving applications\u002Fproducts between servers. ",[12,189,190],{},"This is certainly a good script to include in your master table to be used over and over.",[192,193,197],"pre",{"className":194,"code":195,"language":196,"meta":74,"style":74},"language-sql shiki shiki-themes github-light github-dark","DECLARE @value VARCHAR(64)\nDECLARE @sql VARCHAR(1024)\nDECLARE @table VARCHAR(64)\nDECLARE @column VARCHAR(64)\nSET @value = 'valuehere'\nCREATE TABLE #t (\n    tablename VARCHAR(64),\n    columnname VARCHAR(64)\n)\nDECLARE TABLES CURSOR FOR \nSELECT o.name, c.name FROM syscolumns c \nINNER JOIN sysobjects o ON c.id = o.id \nWHERE o.type = 'U' AND c.xtype IN (167, 175, 231, 239)\nORDER BY o.name, c.name\nOPEN TABLES\nFETCH NEXT FROM TABLES\nINTO @table, @column WHILE @@FETCH_STATUS = 0 BEGIN SET @sql = 'IF EXISTS(SELECT NULL FROM [' + @table + '] '  \n--SET @sql = @sql + 'WHERE RTRIM(LTRIM([' + @column + '])) = ''' + @value + ''') \n'SET @sql = @sql + 'WHERE RTRIM(LTRIM([' + @column + '])) LIKE ''%' + @value + '%'') \n'SET @sql = @sql + 'INSERT INTO #t VALUES (''' + @table + ''', '''\nSET @sql = @sql + @column + ''')'\nEXEC(@sql)\nFETCH NEXT FROM TABLES INTO @table, @column END CLOSE TABLES DEALLOCATE TABLES SELECT * \nFROM #t \nDROP TABLE #t \n","sql",[198,199,200,208,213,219,225,231,237,243,249,255,261,267,273,279,285,291,297,303,309,315,321,327,333,339,345],"code",{"__ignoreMap":74},[201,202,205],"span",{"class":203,"line":204},"line",1,[201,206,207],{},"DECLARE @value VARCHAR(64)\n",[201,209,210],{"class":203,"line":75},[201,211,212],{},"DECLARE @sql VARCHAR(1024)\n",[201,214,216],{"class":203,"line":215},3,[201,217,218],{},"DECLARE @table VARCHAR(64)\n",[201,220,222],{"class":203,"line":221},4,[201,223,224],{},"DECLARE @column VARCHAR(64)\n",[201,226,228],{"class":203,"line":227},5,[201,229,230],{},"SET @value = 'valuehere'\n",[201,232,234],{"class":203,"line":233},6,[201,235,236],{},"CREATE TABLE #t (\n",[201,238,240],{"class":203,"line":239},7,[201,241,242],{},"    tablename VARCHAR(64),\n",[201,244,246],{"class":203,"line":245},8,[201,247,248],{},"    columnname VARCHAR(64)\n",[201,250,252],{"class":203,"line":251},9,[201,253,254],{},")\n",[201,256,258],{"class":203,"line":257},10,[201,259,260],{},"DECLARE TABLES CURSOR FOR \n",[201,262,264],{"class":203,"line":263},11,[201,265,266],{},"SELECT o.name, c.name FROM syscolumns c \n",[201,268,270],{"class":203,"line":269},12,[201,271,272],{},"INNER JOIN sysobjects o ON c.id = o.id \n",[201,274,276],{"class":203,"line":275},13,[201,277,278],{},"WHERE o.type = 'U' AND c.xtype IN (167, 175, 231, 239)\n",[201,280,282],{"class":203,"line":281},14,[201,283,284],{},"ORDER BY o.name, c.name\n",[201,286,288],{"class":203,"line":287},15,[201,289,290],{},"OPEN TABLES\n",[201,292,294],{"class":203,"line":293},16,[201,295,296],{},"FETCH NEXT FROM TABLES\n",[201,298,300],{"class":203,"line":299},17,[201,301,302],{},"INTO @table, @column WHILE @@FETCH_STATUS = 0 BEGIN SET @sql = 'IF EXISTS(SELECT NULL FROM [' + @table + '] '  \n",[201,304,306],{"class":203,"line":305},18,[201,307,308],{},"--SET @sql = @sql + 'WHERE RTRIM(LTRIM([' + @column + '])) = ''' + @value + ''') \n",[201,310,312],{"class":203,"line":311},19,[201,313,314],{},"'SET @sql = @sql + 'WHERE RTRIM(LTRIM([' + @column + '])) LIKE ''%' + @value + '%'') \n",[201,316,318],{"class":203,"line":317},20,[201,319,320],{},"'SET @sql = @sql + 'INSERT INTO #t VALUES (''' + @table + ''', '''\n",[201,322,324],{"class":203,"line":323},21,[201,325,326],{},"SET @sql = @sql + @column + ''')'\n",[201,328,330],{"class":203,"line":329},22,[201,331,332],{},"EXEC(@sql)\n",[201,334,336],{"class":203,"line":335},23,[201,337,338],{},"FETCH NEXT FROM TABLES INTO @table, @column END CLOSE TABLES DEALLOCATE TABLES SELECT * \n",[201,340,342],{"class":203,"line":341},24,[201,343,344],{},"FROM #t \n",[201,346,348],{"class":203,"line":347},25,[201,349,350],{},"DROP TABLE #t\n",[352,353,354],"style",{},"html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":74,"searchDepth":75,"depth":75,"links":356},[],"2015-04-20T08:07:17.3700000-04:00","SQL Script that can be run in a database to return all tables and columns where...",null,{},"\u002Farticles\u002Fsql-server-ndash-find-field-value-in-database",{"title":182,"description":358},"articles\u002Fsql-server-ndash-find-field-value-in-database",[365],"sqlserver","9WL54maowA8aY8EDRpBT04V-F_6eINuHpi58uWVJ_i8",1781574761933]