Info Path cant retrieve SQL data after publishing the form - sharepoint-2013

I created a form in info path which will connect to SQL DB and all connectivity are fine. I preview the form and all SQL data retrieved fine without any issue.
I published the form but when end-users try to load the form, it was shown an error like (An error occurred querying a data source. An error occurred while using the form. For more information, contact the site administrator).
Means I can only retrieve the data while I am at info path and previewing the form but not after the publish.
Is there any things which need to be allowed at SharePoint level to connect to connect to SQL DB which I used in the info path.
Please help and advice .. what could be the issue ??

I would think about permissions on the database.
Have you tried to access the form from the browser with the same user you used in InfoPath designer?

Related

InfoPath cannot call web service when uploaded to Office 365 Sharepoint

Not my normal line of questions, sometimes we've got to be flexible!
I've designed an InfoPath form that I'd like to upload to a Sharepoint site.
On my form I've got a data source that is consuming the following SOAP service
https://SharepointServer/Site/_vti_bin/UserProfileService.asmx?WSDL
I call the Operations "GetUserProfileByName" and get various information about the account looking at the form. In preview this works very well. I've got the header saying "Hello Pete" and I'm able to filter lists based on the user's data. However. When it comes to uploading the form to the server, I'm greeted with the following exception:
Warning
An error occurred querying a data source.
Click OK to resume filling out the form. You may want to check your form data for errors.
HIDE ERROR DETAILS
An error occurred while trying to connect to a Web service.
An entry has been added to the Windows event log of the server.
Log ID:5566
Correlation ID:19df2c9d-a036-2000-3929-0bce8940cf2a
Any ideas what I'm doing wrong? Is there limitations due to the way that my account details are being used on SharePoint? If so what's the work around? I'm not a full admin on the server, so I've only got access to a Sandbox site.
Any help greatly appreciated,
Pete
The issue is loopback protection. In o365, it cannot be disabled. Stupid though, there are a lot of useful web services available for information. See this link: Error message when you connect an infopath form to a sharepoint online web service

Invalid object name 'Student' while running IIS webservice using SQL Server 2005 database

I created a web-service using asp.NET and the database is created using SQL Server 2005. Then I published it to be able to use it from an Android device. I used the IIS Manager to publish it as local IIS. the publishing is done well but when I try to Browse my web-service, the home page of the web-service appears in the browser. But when I try to test one of the methods that uses the database to retrieve some data, (Select * from Student) where Student is a table in my SQL Server 2005 database, an error page appears stating that: System.Data.SqlClient.SqlException: Invalid object name 'Student'.
I searched and found some people said that I should add (dbo.) in the query (Select * from dbo.Student) but it doesn't work too. the same error occured: Invalid object name 'dbo.Student'.
The result of the query returned correctly from Visual Studio when right-clicking the file *.asmx and choose to View in Browser. But it's not returned from the published web-service.
This is my connectionString
Should I give permissions somewhere?! I do't know how to do permissions on the database tables.
Any help will be appreciated.
THanks..

Sitecore: We experienced a technical difficulty while processing your request. Your data may not have been correctly saved

It is throwing the following exception after submitting the data using Web form created after it is upgraded from Web Form for Marketers 2.1.0 to 2.3.0. Followed the step by step upgrade instructions.
Exception in the Log file:
6772 22:24:13 WARN Web Forms for Marketers: an exception: has occured while trying to execute an action.
Error/Warning on the UI:
Sitecore: We experienced a technical difficulty while processing your request. Your data may not have been correctly saved
However, it is saving the data to database, and when I view the report for the same form using Web Form Reports, nothing is shown.
Action Method : Save to Database
The reading/creating counters warning is covered by adding the 'Performance log users' role to the account used by the application pool as previously answered here. It seems unlikely that this is causing the WFFM error, but it's worthing getting rid of the warning, restart IIS, and try again.
This is related to smtp setup on Send Email Message action which is used on webforms for marketers.
Refer:
http://blog.arkesystems.com/post/2010/05/18/SiteCoreWeb-Forms-for-Marketers-Send-Email.aspx

Liferay web service

I use Liferay 6.1.1-ce-ga2 bundled with Tomcat server and Oracle 10g database.
My goal is to insert some content, as Journal Article, and display them in an Asset Publisher (with a structure and template, already working).
I used JournalArticleServiceSoap.addArticle(...) with the right fields (groupid, structureid, templateid, ...). The contents are "correctly" inserted in the database and I can see them inside web contents from administrator content panel. The contents have also "Approved" as status. This is done by setting:
serviceContext.setWorkflowAction(WorkflowConstants.ACTION_PUBLISH)
However, I can't see the inserted contents displayed with the other contents in the Asset Publisher, until I open it again for edition and click on publish button (even without changing nothing). Then the content is published as expected. The problem is the number of contents. It is about 600 so I can't to this action for each one.
I do not understand what is the matter and how to figure it out? In other words, what do I have to do to make the web-content inserted by web service display automatically in Asset Publisher?
Or, what does the "Publish" do exactly so I can try to reproduce programmatically with SOAP service (or SQL after insertion)?
Thank you in advance for your help.
I've also posted the same question in Liferay' forum: Problem to display JournalArticle inserted by SOAP web service
you can try to log the database accessing from Liferay and see what will be changed after you save article manualy. Herefor set the logging level of hibernate to info or debug.
are you setting serviceContext like this?
ServiceContext serviceContext = new ServiceContext();
serviceContext.setAddGuestPermissions(true);
serviceContext.setAddGroupPermissions(true);
serviceContext.setScopeGroupId(groupId);
serviceContext.setWorkflowAction(WorkflowConstants.ACTION_PUBLISH);
You must setting serviceContext Like This:
ServiceContext serviceContext = new ServiceContext();
//serviceContext.setAddGuestPermissions(true);
//serviceContext.setAddGroupPermissions(true);
serviceContext.setScopeGroupId(groupId);
serviceContext.setWorkflowAction(1);
serviceContext.setIndexingEnabled(true);
serviceContext.setIndexingEnabled(true); is Very Important.
The following code is not must requeired.
serviceContext.setAddGuestPermissions(true);
serviceContext.setAddGroupPermissions(true);

how to connect webservice with infopath2007 to submit and recive data in repeating table cotrol?

I have situation to create the infopath 2007 form that must have the repeating table control. and user can view and submit the data to web service. I have built the webservice for that , which having the 2 methods. as saveData(parameters) and getData(). I know i have to create the data connections through Tool->data connection. but i still unable to get and submit data. what i have to do ?
Can you try this - http://social.msdn.microsoft.com/Forums/hu-HU/sharepointinfopath/thread/48c3a7fa-1119-4d0f-ba1e-947490786ffa
If its not helping, please explain in detail, where you are facing the issue?