uzair_zaman Posted February 15, 2012 Share Posted February 15, 2012 I am trying to connect to my local database using Jasperserver pro Evalutiona version. But when I click on Test Connection it give "Connection failed". Please see the screenshot attached:Thanks Link to comment Share on other sites More sharing options...
norcenmarco Posted February 15, 2012 Share Posted February 15, 2012 Hi!! I think there is something wrong in your string connection!Are you sure about your number port? Try with: jdbc:sqlserver://PC5\SQLExpress:1433/EMR Let me know! Link to comment Share on other sites More sharing options...
uzair_zaman Posted February 15, 2012 Author Share Posted February 15, 2012 Thanks for the suggestion. I have tried it but still "Connection Failed". I have double checked the port and it seems to be fine as well. I will attach a screetshot soon. Any other advise please? Thanks Link to comment Share on other sites More sharing options...
mgeise Posted February 15, 2012 Share Posted February 15, 2012 What error do you see in the WEB_INF/logs/jasperserver.log file? My guess is that maybe you failed to copy the database driver into the application. You will need to put the JDBC driver into the WEB_INF/lib folder. You will find the sqljdbc-1.6.jar file int the buildomatic/conf_source/db/sqlserver/jdbc folder. Link to comment Share on other sites More sharing options...
uzair_zaman Posted February 16, 2012 Author Share Posted February 16, 2012 Thanks for the suggestions. I have tried copying the sqljdbc-1.6.jar file at this location; please correct me if I am wrong. C:\Program Files\jasperreports-server-4.5\apache-tomcat\webapps\jasperserver-pro\WEB-INF\. I have also copied sqljdbc4.jar as well as I am assuming that this is the file we need to connect jaspersoft to sql server. But the result is same "Connection failed". I have checked the log file and it says this for this specific event: ------------------------------------------------------------------------------2012-02-16 13:31:13,858 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.name]. Using default validation on input=[MyConn2].2012-02-16 13:31:13,859 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.label]. Using default validation on input=[MyConn2].2012-02-16 13:31:13,860 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.parentFolder]. Using default validation on input=[/datasources].2012-02-16 13:31:13,860 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [_eventId_testDataSource]. Using default validation on input=[].2012-02-16 13:31:13,860 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.username]. Using default validation on input=[emr].2012-02-16 13:31:13,861 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.driverClass]. Using default validation on input=[com.microsoft.sqlserver.jdbc.SQLServerDriver].2012-02-16 13:31:13,861 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.description]. Using default validation on input=[MyConn2 Des].2012-02-16 13:31:13,861 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.password]. Using default validation on input=[emr].2012-02-16 13:31:13,862 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.timezone]. Using default validation on input=[Europe/London].2012-02-16 13:31:13,863 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.connectionUrl]. Using default validation on input=[jdbc:sqlserver://PC5\SQLEXPRESS:1433;databaseName=EMR].------------------------------------------------------------------------------ Kindly suggest. Thanks Link to comment Share on other sites More sharing options...
datakeyword Posted February 20, 2012 Share Posted February 20, 2012 Have you try a clear database environment?I mean a simple jsp/java console app connecting to the database, without any jasper report code/jar/class.It seemed independent of jasper report. Link to comment Share on other sites More sharing options...
norcenmarco Posted February 20, 2012 Share Posted February 20, 2012 You must copy the file in ../jasperserver-pro/WEB-INF/lib!!Cheers! Link to comment Share on other sites More sharing options...
uzair_zaman Posted February 20, 2012 Author Share Posted February 20, 2012 I have tried it with an empty database and it worked like charm :). Then I tried it with my old database which has data in to and it worked with it as well. Thanks for the help. Link to comment Share on other sites More sharing options...
chicolinux Posted February 22, 2012 Share Posted February 22, 2012 Same problem here with Informix!!Best Regards, M Guirao Link to comment Share on other sites More sharing options...
yobiwoo Posted February 23, 2012 Share Posted February 23, 2012 Hi uzair_zaman, I have folow your post in solving this problem but I still having the same problem & it said as normal "Connection fail".Hope you can quide in this.Anyone also can.thanks in advance.Its quite urgent my friends.thank u again. Link to comment Share on other sites More sharing options...
mgeise Posted February 23, 2012 Share Posted February 23, 2012 Did you put your JDBC driver for Informix into ../jasperserver-pro/WEB-INF/lib and restart the server? What error is in your logs?Answering the questions asked to previous people will help you to get your answers much faster. We need to know what you tried, what your settings are, etc. before we can even guess at what your problem is. Link to comment Share on other sites More sharing options...
yobiwoo Posted February 23, 2012 Share Posted February 23, 2012 Hi mgeise,This is my Logs; 2012-02-23 17:26:49,234 WARN LoggerListener,http-8080-2:60 - Authentication event AuthenticationSuccessEvent: superuser; details: com.jaspersoft.jasperserver.multipleTenancy.MTWebAuthenticationDetails@fffc7f0c: RemoteIpAddress: 127.0.0.1; SessionId: 9F92FC28AD4CD296B279AA47BD7FEA7C2012-02-23 17:26:49,234 WARN LoggerListener,http-8080-2:60 - Authentication event InteractiveAuthenticationSuccessEvent: superuser; details: com.jaspersoft.jasperserver.multipleTenancy.MTWebAuthenticationDetails@fffc7f0c: RemoteIpAddress: 127.0.0.1; SessionId: 9F92FC28AD4CD296B279AA47BD7FEA7C2012-02-23 17:27:57,250 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.name]. Using default validation on input=[success_connection].2012-02-23 17:27:57,250 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.label]. Using default validation on input=[success connection].2012-02-23 17:27:57,250 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.parentFolder]. Using default validation on input=[/organizations/organization_1/datasources].2012-02-23 17:27:57,250 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [_eventId_testDataSource]. Using default validation on input=[].2012-02-23 17:27:57,250 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.username]. Using default validation on input=[sa].2012-02-23 17:27:57,250 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.driverClass]. Using default validation on input=[com.microsoft.sqlserver.jdbc.SQLServerDriver].2012-02-23 17:27:57,250 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.description]. Using default validation on input=[].2012-02-23 17:27:57,250 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.password]. Using default validation on input=[rma2012].2012-02-23 17:27:57,250 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.timezone]. Using default validation on input=[].2012-02-23 17:27:57,250 WARN ValidatorImpl,http-8080-6:259 - No rule for parameter [reportDataSource.connectionUrl]. Using default validation on input=[jdbc:sqlserver://CHAM-NB\SQL2008R2:1433;databaseName=cards]. Hope u can help me. Link to comment Share on other sites More sharing options...
yobiwoo Posted February 23, 2012 Share Posted February 23, 2012 I have put the JDBC driver into the WEB_INF/lib folder and I have put sqljdbc-1.6.jar file int the buildomatic/conf_source/db/sqlserver/jdbc folder. I still didn't manage to connect to jasperserver but able to coonect to IReport using Ms. SQL server 2008 R2. Thank u in advance. Link to comment Share on other sites More sharing options...
norcenmarco Posted February 23, 2012 Share Posted February 23, 2012 Put this file sqljdbc-1.6.jar in WEB_INF/lib Link to comment Share on other sites More sharing options...
yobiwoo Posted February 23, 2012 Share Posted February 23, 2012 Thank u norcenmarco, i have put it in WEB_INF/lib. just wanna make clear that can jasperserver support Ms. SQL Server 2008 R2. thank u very much. Link to comment Share on other sites More sharing options...
chicolinux Posted February 23, 2012 Share Posted February 23, 2012 well, I solved my problem replacing the name of the host with it's Ip address in the datasource definition. Best Regards, M Guirao Link to comment Share on other sites More sharing options...
yobiwoo Posted February 24, 2012 Share Posted February 24, 2012 Hi, Everyone.Can anyone give me the steps how to connect to Ms SQL Server 2008 R2.So i can refer which step i might miss out.Later, i will do documentation & share it.so it will benefit so everyone.thank u in advance. Link to comment Share on other sites More sharing options...
mgeise Posted February 24, 2012 Share Posted February 24, 2012 It should go something like this:1) Copy the JDBC drive for your specific database, and in MS SQL's case the version of Java your app server is running with (MS SQL Server has different drivers for Java 1.5 vs. Java 1.6) into the .../webapps/Jasperserver/WEB-INF/lib directory2) Restart your application server3) Log in to Jasper Report Server and create a JDBC datasource a) Set the driver name to the appropriate drive, consistent with what is included in the driver that you installed b) Set the DB URL, etc.4) Check the connection All should be fine. Link to comment Share on other sites More sharing options...
yobiwoo Posted February 24, 2012 Share Posted February 24, 2012 Thank u very much Mr.mgeise, I have try your steps & still having same problem.Together i have attach my documents that have printscreen of settings all.Please correct me if i'm wrong in any steps.thank u so much again for your reply. Link to comment Share on other sites More sharing options...
mgeise Posted February 24, 2012 Share Posted February 24, 2012 Does your iReport connection work? I assume that is why you provided those settings.Everything looks ok, except for the fact that you copied all of the JDBC drivers in and they may be conflicting with each other. You may be getting the 1.5 driver when you are actually running Java 1.6. You will only want to copy in the driver you intend to use.You may also want to try referencing the server by IP address instead of domain name, as was done by mguirao, to see if your server is just not resolving the domain name. Your log only shows the warnings that it is using the default validator. There was no error that followed that such as ClassNotFound or Domain not found? If all else fails, you may want to try enabling more logging on the database driver class, etc. by modifying the log4j properties found in WEB-INF/classes. Link to comment Share on other sites More sharing options...
yobiwoo Posted February 24, 2012 Share Posted February 24, 2012 Thank u very much sir for steps all.my IReport connection working fine.For the jasperServer I will go thru & let u know sir.thank u again. Link to comment Share on other sites More sharing options...
yobiwoo Posted February 24, 2012 Share Posted February 24, 2012 Thank u very much Mr.mgeise.It work wonderful.The problem is conflicting between 1.5 & 1.6. Mine using java 1.6 but when i put both in same folder, it taking java 1.5 as default.thank u million sir.U really save my day.I will do full documentation with PrintScreen, so it will benefit everyone.thanks again. Link to comment Share on other sites More sharing options...
yobiwoo Posted February 25, 2012 Share Posted February 25, 2012 Dear Friends,As i have promise before that i will upload the documentation regarding the Connection steps.This is the steps that make you easy in do connection.Enjoy with JasperSoft. Link to comment Share on other sites More sharing options...
locatesri Posted March 12, 2012 Share Posted March 12, 2012 I am also having the same problem with DB2 connection. Did anyone find a solution for this?I am trying to connect to DB2 7. For This version of DB2 we have to use db2java.zip instead of Jar file.By including this file in class path in ireport I am able to connect from ireport.I copied this db2java.zip intoC:Program Filesjasperreports-server-4.5apache-tomcatwebappsjasperserver-proWEB-INFlibandC:Program Filesjasperreports-server-4.5buildomaticconf_sourcedbdb2jdbc My ireport Jdbc url is as followsjdbc:db2:DSNA In server Iam not sure on what to try.I tried various options like with ip etc but nothing worked.Please help let me know if any of you have connected to DB2 before.Post Edited by locatesri at 03/12/2012 05:54 Link to comment Share on other sites More sharing options...
abdulvahed11 Posted November 18, 2013 Share Posted November 18, 2013 thankshttp://community-static.jaspersoft.com/sites/default/files/pictures/picture-3650-1348204395.jpgmgeise for the posts... copying the libs from buildomatic to WEB-INF lib solved my jdbc driver error for oracle... thanks a lot Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now