Base solution for your next web application
Ends in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

Using SetTenantId insert record sets CeatorUserId =Null #2769


User avatar
0
sanped created

ASP.NET Boilerplate Framework is awesome!!!

I am implementing Multi tenant – multi databases (or database per tenant) architecture.I want to retrieve/view/insert/edit/delete records of Tenant from Host.For this I used SetTenantId() using (_unitOfWorkManager.Current.SetTenantId(tenantId)) { //insert records in Tenant Database using AppService } I am able to insert records in Tenant Database,but with 'CreatorUserId' as Null. I want LogedInUser (which is a host User )as CreatorUserId. How this can be achieved?

Thanks.


1 Answer(s)
  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    I think you can do it using "Overriding Current Session Values", see <a class="postlink" href="http://aspnetboilerplate.com/Pages/Documents/Abp-Session#overriding-current-session-values">http://aspnetboilerplate.com/Pages/Docu ... ion-values</a>.