You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

index.xml 5.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. <?xml version="1.0"?>
  2. <document>
  3. <properties>
  4. <author email="javajedi@users.sf.net">Tim McCune</author>
  5. <title>Java Library for MS Access</title>
  6. </properties>
  7. <body>
  8. <section name="Jackcess">
  9. <p>
  10. Jackcess is a pure Java library for reading from and writing to MS
  11. Access databases (currently supporting versions 2000-2019). It is not
  12. an application. There is no GUI. It's a library, intended for other
  13. developers to use to build Java applications. Jackcess is licensed
  14. under the <a href="http://www.apache.org/licenses/LICENSE-2.0.txt">Apache License</a>
  15. (as of version 2.1.0) and currently requires Java 8+ (as of the 3.0.0
  16. release) Take a look at our <a href="faq.html">Frequently Asked
  17. Questions</a> for more info.
  18. </p>
  19. <subsection name="Java 9+ Compatibility (2021-01-20)">
  20. <p>
  21. While Jackcess <i>still only requires Java 8+</i>, as of the 4.0.0
  22. release it now includes an Automatic-Module-Name of
  23. <code>com.healthmarketscience.jackcess</code> in its manifest. This
  24. allows it to be used safely in the module path for Java 9+ projects.
  25. </p>
  26. <p>
  27. This release is binary compatible with the 3.x release series.
  28. </p>
  29. </subsection>
  30. <subsection name="Java 8+ Support (2019-02-08)">
  31. <p>
  32. Jackcess now requires Java 8+ as of the 3.0.0 release. All third
  33. party dependencies have been updated to the latest versions.
  34. Jackcess now supports Java 8+ data types like
  35. <code>LocalDateTime</code> and <code>Path</code>. Databases can now
  36. optionally return <code>Date</code> values (legacy, backwards
  37. compatible) or <code>LocalDateTime</code> values. See <a href="apidocs/com/healthmarketscience/jackcess/DateTimeType.html">DateTimeType</a>
  38. and the <a href="jackcess-3.html">Upgrade Guide</a> for more details
  39. </p>
  40. </subsection>
  41. <subsection name="Expression Evaluation (2018-09-08)">
  42. <p>
  43. Have you ever wished that Jackcess could handle field "default
  44. values" (or other expressions)? Wish no longer! Expression
  45. evaluation is now enabled by default as of the 3.5.0 release. See
  46. the <a href="apidocs/com/healthmarketscience/jackcess/expr/package-summary.html#package_description">expression package</a> javadocs for more details.
  47. </p>
  48. </subsection>
  49. <subsection name="Brand New License! (2015-04-16)">
  50. <p>
  51. Due to the generosity of Health Market Science and the efforts of
  52. the <a href="https://tika.apache.org/">Apache Tika project</a>, the
  53. OpenHMS projects have been relicensed under the <b>Apache License,
  54. Version 2.0</b> (Jackcess versions 2.1.0 and higher).
  55. </p>
  56. </subsection>
  57. </section>
  58. <section name="Sample code">
  59. <p>
  60. Here are a few snippets of code to whet your appetite. For more
  61. extensive examples, checkout the <a href="cookbook.html">cookbook</a>. And, since Jackcess is heavily
  62. unit tested, you can find even more example code in the <a href="xref-test/index.html">unit tests</a>.
  63. </p>
  64. <ul>
  65. <li>Iterating through the rows of a table:
  66. <source>Table table = DatabaseBuilder.open(new File("my.mdb")).getTable("MyTable");
  67. for(Row row : table) {
  68. System.out.println("Column 'a' has value: " + row.get("a"));
  69. }
  70. </source>
  71. </li>
  72. <li>Searching for a row with a specific column value:
  73. <source>Row row = CursorBuilder.findRow(table, Collections.singletonMap("a", "foo"));
  74. if(row != null) {
  75. System.out.println("Found row where 'a' == 'foo': " + row);
  76. } else {
  77. System.out.println("Could not find row where 'a' == 'foo'");
  78. }
  79. </source>
  80. </li>
  81. <li>Creating a new table and writing data into it:
  82. <source>Database db = DatabaseBuilder.create(Database.FileFormat.V2000, new File("new.mdb"));
  83. Table newTable = new TableBuilder("NewTable")
  84. .addColumn(new ColumnBuilder("a", DataType.LONG))
  85. .addColumn(new ColumnBuilder("b", DataType.TEXT))
  86. .toTable(db);
  87. newTable.addRow(1, "foo");
  88. </source>
  89. </li>
  90. <li>Copying the contents of a JDBC ResultSet (e.g. from an
  91. external database) into a new table:
  92. <source>Database db = DatabaseBuilder.open(new File("my.mdb"));
  93. new ImportUtil.Builder(db, "Imported").importResultSet(resultSet);
  94. db.close();</source>
  95. </li>
  96. <li>Copying the contents of a CSV file into a new table:
  97. <source>Database db = DatabaseBuilder.open(new File("my.mdb"));
  98. new ImportUtil.Builder(db, "Imported2").setDelimiter(",").importFile(new File("my.csv"));
  99. db.close();</source>
  100. </li>
  101. </ul>
  102. </section>
  103. <section name="Other Resources">
  104. <p>
  105. Some other jackcess related projects:
  106. </p>
  107. <ul>
  108. <li>
  109. <a href="https://github.com/brianb/mdbtools">mdbtools</a> - Open Source project
  110. for reading Access files, written in C.
  111. </li>
  112. <li>
  113. <a href="https://jackcessencrypt.sourceforge.io/">Jackcess
  114. Encrypt</a> - Extension library for Jackcess which implements
  115. support for some forms of Microsoft Access and Microsoft Money
  116. encryption.
  117. </li>
  118. <li>
  119. <a href="http://ucanaccess.sourceforge.net/site.html">UCanAccess</a>
  120. - Open Source pure Java JDBC Driver implementation.
  121. </li>
  122. </ul>
  123. </section>
  124. </body>
  125. </document>