Pergunta

I need to have users that update/insert information logged correctly. Currently the connection string is used as my user and a trigger on the database takes that and logs that as the person who updated the record. Obviously, everone that uses the app will have the same connection string information, but different HttpContext.User.Identity.Names. I want the connection to the database to remain the same, but I want the users HttpContext.User.Identity.Name to be logged, not the connection. Is there anyway that I can make that distinction? Such as setting the client_Identifier?

Foi útil?

Solução

possible Answer

Just found this Link and it looks like it could be a possible answer. Set the ClientId of the connection. Seems simple enough.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top