Failed Connection to Datasource - InfoPath Dev

InfoPath Dev

Use our Google Custom Search for best site search results.

Failed Connection to Datasource

Last post 03-28-2008 07:07 AM by srikrushna. 10 replies.
Page 1 of 1 (11 items)
Sort Posts: Previous Next
  • 01-13-2008 11:27 PM

    Failed Connection to Datasource

    Hi All,

    I am using Infopath 2007. I connect to SQL Database but only to receive some values and display it on the form. The form is working fine on my computer (when I click on preview).

    But after a I publish the form on the Sharepoint 2003 document library and then open the form from sharepoint by selecting the option 'Fill Out the form', I get the error 'Failed Connection to Datasource'. And in the details it gives me the name of the same datasource which is bringing the data from SQL Database.

    The following is what I am getting when I click on 'Show Details'.

    The query cannot be run for the following DataObject: View_DowntimeAlertForm
    InfoPath cannot run the specified query.
    InfoPath cannot connect to the data source.
    Access is denied.
    Access is denied.

    Can anybody please help me out on this???





  • 01-14-2008 06:08 AM In reply to

    Re: Failed Connection to Datasource

    Hi Amad.

    Obviously check your SQL database permissions against what login you are using for SharePoint. You need a group account or indivdual access with at least select/read access to the database tables. First to check is the View_DowntimeAlertForm.

    Is the database in the same domain?  It could be a trust issue that is denying access.

    If you have Sharepoint 2003, and are working with SQL then you may want to check out the Database Accelerator package. Qdabra Database Accelerator Suite Version 2.1 - Developer

    With it you can use Web Services for your data which is more efficient and powerful and also it includes workflow and other features that are not available in SP2003.

    Filed under:
  • 01-14-2008 10:23 PM In reply to

    Re: Failed Connection to Datasource

    Hi Clay,

    Can you tell me what login Sharepoint is using to connect to the SQL Database? If its the same account which I use to login into Sharepoint, then that account is the administrator both the Server (which hosts the SQL Server) and also has System Admin permissions as well. If Sharepoint is using a separate account, kindly let me know how can I find that out?

     The database is in the same domain. Also I am able to connect to the server through remote desktop by mentioning the server name (rather than the IP) and also I am also able to connect through SQL Query Analyzer and Enterprise Manager from my computer to the SQL server.



  • 01-14-2008 10:55 PM In reply to

    Re: Failed Connection to Datasource

    What is the trust level of the form?

    Tools -> form options-> Security and Trust

    I would assume you are using Windows Authentication on the connection to SQL. You may try going through your SQL connection again in the Data Connection wizard. I would try setting up another Data source and make sure you have MS SQL and Windows Authentication.

  • 01-27-2008 09:14 AM In reply to

    Re: Failed Connection to Datasource

    Hi Clay,

    i'm having the same problem. MOSS-Logs says the User NT-AUTORITY\ANONYMOUS could not be logged in. But i have a Full-Trust-Template (global udcx and global Formtemplate)

    The sql-Server is in the same Domain. The Identity of my Web-Application-Pool-Account is a dedicated Service-Account. Double hop-issue?

    Any hints?

    Thanks in advance


  • 01-27-2008 09:40 PM In reply to

    Re: Failed Connection to Datasource

    I was under the impression that MOSS had an issue with anonymous but I could be wrong. I would maybe try a different account as a test.

    Full trust is more in regards to code and accessing local functions, it should not have an effect on the MOSS or SQL conectivity with a standard data connection.


  • 01-28-2008 04:20 PM In reply to

    Re: Failed Connection to Datasource

    Hi Clay,

    thanks for Response.

    Even if i enable the WebServiceProxy in Central Administration. - No Luck! - But difference here is that now the current user-account is mentioned in the moss log (Faild to login with domain\user). MSDN says the WebServiceProxy routes the Application-Pool-Identity to connect to the 3-rd Tier. ???

    When i change the Dataconnectionfile from NTLM to SQL and give that account read permissions on the sql-server everything works fine.


  • 01-28-2008 04:26 PM In reply to

    Re: Failed Connection to Datasource

    I am at a similar issue with SRS on a project. It is the "Double Hop" problem with IIS.  Unless you use Kerberos, you cannot get the Windows Authentication to pass to the second server.  I am going to use a SQL account for the second jump.

    You can search on double hop to see what options there are.

  • 01-28-2008 10:17 PM In reply to

    Re: Failed Connection to Datasource


     I have already resolved this issue. Kindly check where ever this applies. The message that was coming was seemingly from SQL Server so I checked in SQL profiler but found that no request is coming to SQL Server.

    So I checked the settings of Internet Explorer and changed the 'Access Data Sources across domains' to enabled and hence resolved the issue for me.

     Hope this resolves the issue for you.



  • 01-31-2008 12:06 PM In reply to

    Re: Failed Connection to Datasource

    Hi Amad,

    i already marked cross domain access. Issue still remains.

    Did you get it to work with NTLM, WebProxy enabled and cross domain access?

    Thanks for the hint


  • 03-28-2008 07:07 AM In reply to

    Re: Failed Connection to Datasource

    Hi Classgenerator ,

    I believe you are using Webservice to communicate from infopath to Database.

    The Error basically comes, when the web service produces the Data source from DB server Via set of Credentials those credentials are not valid.

    So to get rid of this, U need to Give Read Permission to UR custom Webservice, which is hosted under the IIS.

    Here is the trick :

    Right click on the Webservice folder(Where U ve published i.e. Under Virtual Dir)-->Propertie-->Security-->Add Everyone and Give Only Read Access.

    So that Everyone can access the Datasource, which ur Web service is producing.

    I believe this will work !

    Thanks & Regards,
    Srikrushna Patro.
Page 1 of 1 (11 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.