PetaPoco Transaction in Multithread Env

前端 未结 3 1466
旧时难觅i
旧时难觅i 2021-01-12 17:41

I just test PetaPoco Transaction in a multithread way...

I have a simple test case :

-- Simple value object call it MediaDevice -- Insert a record an update

3条回答
  •  抹茶落季
    2021-01-12 18:20

    Hi use with nolock in select query because the table may be locked. long count = db.ExecuteScalar("SELECT Count(*) with nolock FROM MediaDevices");

提交回复
热议问题