Results 1 to 1 of 1
-
JDO - Retrieving a persisted object
The following code snippet shows how to retrieve persisted objects.
Java Code:try { tx = pm.currentTransaction(); tx.begin(); Extend ex = pm.getExtent(Employee.class, true); Iterator i = ex.iterator(); while(i.hasNext()) { Employee obj = (Employee) i.next(); } tx.commit(); } catch (Exception e) { if(tx.isActive()) { tx.rollback(); } }
Similar Threads
-
storing and retrieving a file as such
By anil_manu in forum Advanced JavaReplies: 0Last Post: 03-11-2008, 01:27 PM -
retrieving Properties
By bugger in forum New To JavaReplies: 1Last Post: 01-13-2008, 09:44 PM -
Retrieving out objects from Vector
By tuckker in forum New To JavaReplies: 3Last Post: 12-03-2007, 05:52 AM -
Retrieving data from the DB
By yuchuang in forum JDBCReplies: 2Last Post: 11-27-2007, 08:59 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks