This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes JDBC and Relational Databases and the fly likes UCanaccess Jackcess Calculated Fields Microsoft Access Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "UCanaccess Jackcess Calculated Fields Microsoft Access" Watch "UCanaccess Jackcess Calculated Fields Microsoft Access" New topic
Author

UCanaccess Jackcess Calculated Fields Microsoft Access

Robert Panivino
Greenhorn

Joined: Nov 27, 2013
Posts: 5
I'm stuck and I'm posting this question everywhere in case someone with some experience knows anything. I need a pure java jdbc library for Microsoft Access and don't ask why. I chose Ucanaccess with jackcess. Everything was pink and beautiful until I got to calculated fields. The question is summarized below:


For simplicity, we'll assume we have a simple table with two columns: id, and idx2 which returns [id]*2. I want to either query the row (1,2) or anything related to the function (such as (1, [id*2])). I don't care how dirty the solution is.

Those who have used either of these two libraries should know what a simple select returns. How did you fix it?
Robert Panivino
Greenhorn

Joined: Nov 27, 2013
Posts: 5
Someone else was faster, I'll quote the answer here.


As you are probably aware, UCanAccess uses Jackcess to read/write the Access database so it is really a question of whether Jackcess can read a Calculated field. Unfortunately, it cannot (or at least it couldn't do so the last time I checked, which was sometime in the last few months).

On Windows you would have the option of using the JDBC-ODBC Bridge (with all its warts) under Java 7. However, I'm not aware of any other options for Java under Linux.

You may want to visit the Jackcess site on SourceForge and ask about this issue in the discussion forums, or possibly submit a feature request.


So, if by googling you end up here, ucanaccess-2.0.6.2.jar and jackcess-2.0.4.jar do NOT support this feature.
 
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
 
subject: UCanaccess Jackcess Calculated Fields Microsoft Access
 
It's not a secret anymore!