asp.net mvc - How to provide non-table parameters in delete procedure mvc EF database first -
i using view , stored procedures layer between code , database. of create, update, delete procedure need passed user id , transaction id manage security , history keeping.
in update procedures, have received old user id , transaction ids view, replaced record values new ones, , called sp save.
the problem delete sp. again, trying update values in record before invoking db.remove , save methods. unfortunately, delete sp called old values, not new ones.
i considering calling sp directly, little scared of changes might have make in db context keep in sync, , not have next save changes try deletion again. prefer work in existing ef mechanism if possible. perhaps need know in complexity of db context ortigianl values stored can update them.
code wise, more normal system have 1 sp parameter - id of record delete. perhaps 2 concurrency control - id , timestamp, both of these selected databse in first place. how can other parameters more complex sp?
as more general expression of problem, how can add parameters not come database, call list of ef delete sp?
Comments
Post a Comment