Hi,
I have to connect to an SQL server from AEM. I have a bundle created with the SQL jdbc driver and installed on OSGi. and I have the connection uri configured on the felix console with datassource name mysqlserver.
when I use the below code
@Reference
private DataSourcePool dspService;
DataSource dataSource = (DataSource) dspService.getDataSource("mysqlserver");
I get this error:
No data source found with name '' (after asking 0 providers)
could I get some assistance in identifying what went wrong.
Regards
Solved! Go to Solution.
There is also a video - which is hosted on the Community YouTube Channel - that you can watch that shows you everything you need to do.
Refer to this article - looks like you are missing the configuration side -- Scott's Digital Community: Injecting a DataSourcePool Service into an Adobe Experience Manager OSGi ...
There is also a video - which is hosted on the Community YouTube Channel - that you can watch that shows you everything you need to do.
balarama rajur68938704 This may be old thread. But did you find the issue? I am getting the same error after setting up the configuration and installing the SQL server JDBC as OSGi bundle. Currently using AEM 6.3.
smacdonald2008, I went through the video and tried to do the same. Unfortunately, it is not working. Could you please provide a link for SQL Server as well. I found the link for HSQL and mySQL. Your help is appreciated.
Views
Replies
Total Likes
We just did a new one here -- it works for MySQL - Adobe Experience Manager Help | Querying MySQL data using an Adobe Experience Manager 6.4 DataSource...
Views
Replies
Total Likes
Hi smacdonald2008, Thanks for the response. However, there seems to be an issue with SQL Server JDBC. I am getting Caused by: java.lang.UnsupportedClassVersionError: com/microsoft/sqlserver/jdbc/SQLServerDriver has been compiled by a more recent version of the Java Runtime (class file version 54.0), this version of the Java Runtime only recognizes class file versions up to 52.0 while saving the configuration. I have JRE 8 in my eclipse and even tried the jar from Database drivers as an OSGi bundle for Forms Data Integration, getting the same error even for this.
Not sure how to proceed further.
Views
Replies
Total Likes
Yeah - it certainly does look like a Data Base Driver file issue. I use MySQL Driver file for testing and there are no issues.
I am asking internal ppl to see if this issue is known.