When profiling a .Net Application in SQL Server Profiler the default Application Name is taken from the Data Provider. How can I change this to my own Application Name?
Change Application Name in Sql Server Profiler
Asked Answered
Just add Application Name=My Application;
to the Connectionstring
Example:
connectionString="Server=mySqlServer;Initial Catalog=myDatabase;User id=aUser;Password=aPassword;Application Name=My Application;"
You can also use App=My Application
@MichealChoudhary I just tried this with SQL Server 2016 Developer and had no issues. The application name appeared in SQL Profiler. –
Monotone
Worked for me in SQL Server 2017 & Management studio 18 –
Alvinia
in a website asp.net webform fails The requested database does not have a valid ADO.NET provider name set in the connection string. –
Matri
If I use
Application Name=
, then I get a message from the driver (Native Client 11, and ODBC 17) telling me Invalid connection string attribute
. However, APP=
seems to work in most cases? docs –
Endorse Valid content of the connection string is highly dependent on which Data Provider you use. Please have a look at, for example, connectionstrings.com/sql-server for examples that you can use. –
Eclampsia
© 2022 - 2024 — McMap. All rights reserved.