Hello everyone,
I am new to ASP.NET development. I created a web service and deployed into IIS 7.0 environment. My web service works fine within VS 2012, I am using below connection string to query my SQL database without issue from VS 2012. The connection string is:
<connectionStrings>
<add name="MYDB" connectionString="data source=MYCOMPUTER\MYDATADB; Integrated Security=SSPI; Database=my_Inventory"
providerName="System.Data.SqlClient"/>
</connectionStrings>
However, my web service does not return data from SQL when it is running in IIS. Any idea? What permission do I need to setup?
<?xml version="1.0" encoding="utf-8" ?>
<Inventory xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:nil="true" xmlns="http://localhost/MyWebservices/" />
BTW - I found below error from SQL error log.
Login failed for user 'IIS APPPOOL\DefaultAppPool'. Reason: Could not find a login matching the name provided. [CLIENT: <local machine>]
Please advise,
Thanks,
Brian.