MDB library for Java


Jackcess is a pure Java library for reading from and writing to MS Access databases. It is not an application. There is no GUI. It's a library, intended for other developers to use to build Java applications MDB Tools The MDB Tools project is a effort to document the MDB file format used in Microsoft's Access database package, and to provide a set of tools and applications to make that data available on other platforms.

มี 2 ตัว

- Jackcess
- MDB Tools



Jackcess

Tanoy ส่ง url น่าสนใจมา ซึ่งก็น่าสนใจจริงๆ เกี่ยวกับการใช้ mdb บน Java

ตัวอย่างการใช้งาน
Displaying the contents of a table:


CODE
Database.open(new File("my.mdb")).getTable("MyTable").display();



Creating a new table and writing data into it:

CODE

Database db = Database.create(new File("new.mdb"));
Column a = new Column();
a.setName("a");
a.setSQLType(Types.INTEGER);
Column b = new Column();
b.setName("b");
b.setSQLType(Types.VARCHAR);
db.createTable("NewTable", Arrays.asList(a, b));
Table newTable = db.getTable("NewTable");
newTable.addRow(new Object[] {1, "foo"});



Copying the contents of a JDBC ResultSet (e.g. from an external database) into a new table:

CODE
Database.open(new File("my.mdb")).copyTable("Imported", resultSet);



Copying the contents of a CSV file into a new table:

CODE
Database.open(new File("my.mdb")).importFile("Imported2", new File("my.csv"), ",");



อืมส์ น่าสนใจแฮะ เอา microsoft access มาใช้ใน java ได้ด้วย ใครสนใจลองไป
http://jackcess.sourceforge.net/


อีกตัวหนึ่งก็คือ MDB Tools  ลองดูครับ...

คำสำคัญ (Tags): #java#se#it#opensource
หมายเลขบันทึก: 28186เขียนเมื่อ 15 พฤษภาคม 2006 11:54 น. ()แก้ไขเมื่อ 8 มิถุนายน 2012 19:44 น. ()สัญญาอนุญาต: จำนวนที่อ่านจำนวนที่อ่าน:


ความเห็น (0)

ไม่มีความเห็น

พบปัญหาการใช้งานกรุณาแจ้ง LINE ID @gotoknow
ClassStart
ระบบจัดการการเรียนการสอนผ่านอินเทอร์เน็ต
ทั้งเว็บทั้งแอปใช้งานฟรี
ClassStart Books
โครงการหนังสือจากคลาสสตาร์ท