New Snippet New Snippet Recent Snippets Recent Snippets My Snippets My Snippets Web Code Search Snippets Search
Sign inor Register
Format:
Recent snippets matching tags of Transaction
C#
public IQueryable<T> Query(Expression<Func<T, bool>> predicate)
{
    IQueryable<T> returnValue;
    using (ITransaction transaction = _session.BeginTransaction())
    {
        try
        {
            returnValue = _session.Linq<T>().Where(predicate);
            transaction.Commit();
        }
by Chris Brandsma   May 14, 2010 @ 2:09pm
63 Views
no comments
 
SQL
set nocount on
 
-- build a working table called x
 
if (object_id('x') is not null) 
    drop table x
create table x (col1 varchar(50))
 
declare @sql nvarchar(500)
set @sql = 'insert into x select ''test'';'
by Jerry Nixon   April 09, 2010 @ 2:47pm
74 Views
1 comments
 
brought to you by:
West Wind Techologies


If you find this site useful and use it frequently please consider making a donation to support this free service.
Donate