Пример #1
0
 private void InsertItem(SqlSessionId sessionId, byte[] data)
 {
     SqlProcedure.Create(_connectionString, SqlSession.IsShortData(data) ?
                         "TempInsertStateItemShort" :
                         "TempInsertStateItemLong").
     Execute(x => x.In("id", sessionId.ToString()),
             x => x.In(SqlSession.IsShortData(data) ? "itemShort" : "itemLong", data),
             x => x.In("timeout", _timeout));
 }
Пример #2
0
 private void UpdateItem(SqlSessionId sessionId, byte[] data, int lockCookie)
 {
     SqlProcedure.Create(_connectionString, SqlSession.IsShortData(data) ?
                         "TempUpdateStateItemShortNullLong" :
                         "TempUpdateStateItemLongNullShort").
     Execute(x => x.In("id", sessionId.ToString()),
             x => x.In(SqlSession.IsShortData(data) ? "itemShort" : "itemLong", data),
             x => x.In("timeout", _timeout),
             x => x.In("lockCookie", lockCookie));
 }