Expand my Community achievements bar.

SOLVED

No data source found with name '' (after asking 0 providers)

Avatar

Level 4

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

1 Accepted Solution

Avatar

Correct answer by
Level 10

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.

View solution in original post

6 Replies

Avatar

Correct answer by
Level 10

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.

Avatar

Level 1

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.

Avatar

Level 1

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.

Avatar

Level 10

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.