Recently, I had to sort lists, and surprisingly, it turned out to be simple. Let's say we have a class: Creating a list: Now, to sort it by the ID field, we need to do just this: As you can see from the picture, I became curious about how quickly this all works.
Always thought that .NET in System.IO had a method that implements folder copying with contents, including all subfolders and files. It turned out I was wrong, and there is no such method. Therefore, I bring an example of implementing this action using a fairly simple function with the help of System.IO.DirectoryInfo.
Adding Records to a Table Ignoring IDENTITY: -- Enable SET IDENTITY_INSERT tableA ON -- You must specify the full list of columns for INSERT: INSERT Into tableA ([id], [c2], [c3], [c4], [c5] ) SELECT [id], [c2], [c3], [c4], [c5] FROM tableB...