Skip to content

Instantly share code, notes, and snippets.

@MNF
MNF / ImportAppleReviews.cs
Created Dec 2, 2017
Import Apple Reviews
View ImportAppleReviews.cs
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Diagnostics;
using System.Diagnostics.Contracts;
using System.Globalization;
using System.Linq;
using System.Linq.Expressions;
using System.Threading.Tasks;
@MNF
MNF / Util_CopyTable.SQL
Last active May 23, 2019
Copy table With Schema And Data
View Util_CopyTable.SQL
- --from http://dba.stackexchange.com/questions/18059/copy-complete-structure-of-a-table
IF TYPE_ID(N'TestTableType') IS NULL
create type TestTableType as table (ObjectID int)
go
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
-- Drop stored procedure if it already exists
@MNF
MNF / PropertyNameExtension.cs
Last active Dec 15, 2015 — forked from StevePy/PropertyNameExtension.cs
Added Converted to MS Test from NUnit PropertyNameUnitTests
View PropertyNameExtension.cs
using System;
using System.Linq.Expressions;
public static class PropertyNameExtensions
{
/// <summary>
/// Extension method for exposing the name of properties without resorting to
/// magic strings.
/// Use: objectReference.PropertyName( x => x.{property} ) to retrieve the name.
/// I.e. objectReference.PropertyName( x => x.IsActive ); //will return "IsActive".
You can’t perform that action at this time.