iReport on linux, setting up JDBC Drivers - jdbc

I am trying to get some JasperReports working. To build them I am using iReport.
I need to connect to an MS SQL Server db. In iReport the MS JDBC driver is listed. However when I go to test the connection I get a class not found error.
I have made sure that I have the driver in my class path
echo $CLASSPATH
/home/USER/dev/jtds/jtds-1.2.5.jar
Has any one run into these sorts of issues and found a way around?

The key idea is "In iReport the MS JDBC driver is listed." Somewhat surprisingly... this means nothing at all.
Well... it means that the iReport team thinks this is a common enough driver that they put it into the drop down list so that you would not have to type it. It does not mean that the driver is available.
As Dan has already alluded to in the comments, the solution is to add the relevant .jar file (jtds-1.2.5.jar) to iReport's classpath using the menu Tools → Options. (On OS X it's the menu iReport → Preferences).

go to the ireport there u will see one icon on top and click it it will show paths there u establish a connection to jdbc and add ojdbc 14 jar to it . that's it simple and add that jar to classpath.

Related

Added external library can't be seen - NetBeans

I downloaded SocketTest project and made some changes to read data from MS SQL database. Added external library:
But I'm getting java.sql.SQLException: No suitable driver found... when I run the project.
I'm sure there is no mistake in my source code. Because I tested my class on alternate project. It's running smoothly. But I wonder why MS SQL library can't be seen even after I add that.
I also tried to use the newest version of MS SQL library but still no success.
I also tried to analyze project.xml file. But I guess solution is not there.
Please help me to solve this issue.
Thanks in advance.
Solution has been found. build.xml file has been cleared and copied from newly created NetBeans project.

BIRT 431: Java/JDBC for Oracle compatibility issue

BIRT 431; Oracle 12c
IBM Maximo Asset Management 7.6.1.2 — only supports BIRT 431
I want to preview my BIRT reports (by connecting from BIRT to the Maximo database).
BIRT 431 requires Java 7. However, the latest version of JDBC for Oracle requires Java 8 (older drivers won't connect to the database).
If that's correct, then how can I preview BIRT reports if BIRT 431 doesn't support any functioning JDBC drivers?
A colleague provided this solution. I haven't been able to test it yet.
Use the latest available version of the jdbc driver for Oracle designed for Java 7:
Oracle Database 12.1.0.1 JDBC Driver & UCP Downloads --> ojdbc7.jar
In order to get preview features working for Eclipse BIRT 4.3.1 the following steps need to be taken:
Be sure that the version of Java being used for Eclipse is version 7. If it isn’t change it to version 7 as the preview feature will not work with 8.
Review chapter 2 in the attached document.
Save the attached file (ojdbc7.jar.txt) to the folder eclipse\plugins\org.eclipse.birt.report.viewer_4.3.1.v201309171028\birt\WEB-INF\lib below your base eclipse installation folder. Rename the file removing the “.txt”.
Create a copy of the file and change the extension from “.jar” to “.zip”.
Extract the contents of the zip file to eclipse\plugins\org.eclipse.birt.report.viewer_4.3.1.v201309171028\birt\WEB-INF\classes
Confirm Eclipse configuration as per the documentation from point 2.
Test with a report to confirmation functionality.
If there is an issue with the built in tool for previewing report output you may need to configure Eclipse to use a web browser instead.
In Eclipse use Window -> Preferences -> Report Design -> Preview.
Check the option “Always use external browsers.”
Click on the Web Browser link.
Click on the “Use external web browser” radio button and check “Default system web browser” or the browser of your choice if it appears in the list.
Related:
Maximo76_Designer431_Report Development Guide_Rev8.pdf

Downloading 7.0.7 - jconn-7.0.7.jar

I am trying to download jconnect-7.0.7.jar for Sybase Database from this URL [http://downloads.sybase.com/][1]. But getting error like the site is down. I searched a lot, but cannot find the jar anywhere.
Could anyone let me know where I can get the jar?
Old sybase.com page is not active any more. You can get jConnect 16.0 together with ASE 16.0 directly from sap.com page. The JDBC driver is almost the same as the 7.0.7 version except the version name has changed.

Oracle SQL Developer - Driver Class not found. Vendor code 0

I am using Oracle SQL V. 4.1.3.
I have installed it successfully, and established connections to our database. I see the db connections, but when expanding them this error message shows up:
Driver Class not found. Verify the Driver location. Vendor Code 0
I installed Ms JDBC driver 6.0 for SQL Server and unpacked it in my ProgramFiles. I then went to ControlPanel-SystemProperties and added the sqljdbc42.jar as <installation directory>\sqljdbc_<version>\<language>\sqljdbc.jar under my existing environment variable called PATH.
Now when I go to SQL Developer Properties, I see JDBC.JAR added to Java.library.path but not to java.class.path. Is this the reason I am still getting error message? How do I go about fixing it? Or is there some other issue at hand?
I also experienced the reported error. It appears one can go to preferences of a connection, click on 'Test' to test the connection and then it suddenly works again... Very strange, but it worked. You do have to do this for all connections, but hey, it worked.
Need to set driver path inside Preference -> Database -> 3rd Party JDBC driver -- in case of mssql add -- jtds-1.3.1.jar.
Nevermind, I was just little stupid. All I had to do was add Third Party JDBC Driver path under Preferences in SQL Developer and it works like a Charm.

Debug PostgreSQL function using pgAdmin

I refer this to enable the debugger in the PostgreSQL server in order to debugging the plpgsql function by stepping through the code using pgadmin.
I have already set shared_preload_libraries = '$libdir/plugins/plugin_debugger.dll' in the postgresql.conf, run pldbgapi.sql , and restarted the server.
These steps should have been run successfully and plugin_debugger.dll should be loaded successfully as can be verified by using the command show shared_preload_libraries, and I can see the debugging option in the context menu with a right click on a function in pgAdmin.
When choosing "Debugging" --> Debug, a window pops up to allow me to enter the values for the input parameters. But after that, when I press OK, it does not respond at all.
Any ideas or did I miss something in the setup of the debugger on the server?
I am using PostgreSQL 8.3 and pgAdmin 1.14
You have to enable debugging in two places. On PGAdmin and on the database itself. That article you referenced does a wonderful job explaining it but there were some nuances.
PGAdmin
When updating your postgresql.conf file to load the debugging library, I was running PGAdmin on Windows so the file was here:
C:\Program Files\PostgreSQL\9.4\data\postgresql.conf
And the path to the plugin_debugger.dll was actually
$libdir/plugin_debugger.dll
not
$libdir/plugins/plugin_debugger.dll
as specified in the article. So your postgresql.conf would need a line like this
shared_preload_libraries = '$libdir/plugin_debugger.dll'
Search for the actual .dll if you're in doubt. If you're on Linux the file you'll be looking for is plugin_debugger.so. Don't forget that changing the postgresql.conf file will require a restart for the change to take effect.
PostgreSQL Database
Assuming you're running your PostgreSQL database on a Linux server this gist does an excellent job at explaining how to download the dependencies for enabling debugging. Make sure you're running as root when you install.
The part that's easy to miss is issuing the command against the actual database you want to debug. For newer versions on PostgreSQL all you'll need to do is this:
CREATE EXTENSION IF NOT EXISTS pldbgapi;
If that doesn't return an error, you should be good to go.
Some additional things of note:
As mentioned above, you can only debug when running as a super user account
From their docs you can only debug pl/pgsql functions. So if your function says something like LANGUAGE c PGAdmin won't even show a right-click Debug menu option when you select the function. Look for something that has LANGUAGE plpgsql and the Debug menu should show.
Ken,
Have you tried pgAdmin 1.8 to rule out issue with PgAdmin 1.14/ PostgreSQL 8.3 interaction. It's been a while since I've used 8.3 and for the article I wrote -- which you are referring to, I was testing with 1.14/ PostgreSQL 9.1 so it could very well be an issue with the interaction with older version. Unfortunately I don't have a 8.3 anymore to test with.
I vaguely remember having the issue you had once, but it was when I had another shared library in my postgresql.conf in addition to the pldebugger. Can't remember which one that was, but removing the other shared library fixed my issue.
Hope some of these suggestions help,
Regina
I had the same problem.
Make sure the only shared lib you´re loading in the postgres.conf is the debugger.
Nothing else. Not even the profiler.
If you get a SSL error when trying to debug a function, reconnect to the server.

Resources