Re: New Feature Idea

2011-12-01 Thread tgallagher
Sorry for the delay on the new feature.  I was experimenting with using 
a TransientStateManager, and the effects it would have on an object that 
is made persistent.

I would like to send the JDO group some source code that is generic enough 
to include as part of the JDO release. 

Since I did much of the original work for 3M, I'm wondering what is your 
policy about sharing source code?  Can their be a Originally developed by 
3M indicator in the source code that would remain during distribution?

I'm still checking with 3M about its open source policy, so I hope I can 
share this, but we will see.

Thanks,
Tim Gallagher

Clinical  Economic Research
3M Health Information Systems
5000 Buttercup Drive
Castle Rock, CO 80109

Phone: (303) 814-3867




From:
tgallag...@mmm.com
To:
jdo-dev@db.apache.org
Date:
11/03/2011 05:39 PM
Subject:
Re: New Feature Idea



Matthew,

Thanks for the link.  I like that query functionality.  That will cover 
everything that would ever be required. 

However, I would also propose to also include the following which would be 

a really easy mechanism query data.  I'll show it as an example using the 
example on the page you listed and continuing with the Product object:

@PersistenceCapable
public class Product
{
@PrimaryKey
long id;
String name;
double value;
...
}

Suppose you wanted all the products that start with Wal, then the code 
would be something like this:

Product product = new Product();
product.setName(Wal%);

ListProduct products = 
JDORecord_Utils.loadByExample(this.persistenceManager, Product.class, 
product, name);

In the example above, the loadByExample parameters are:

persistence Manager
candidate class
example object
sorting field name

This results in a JDO query of:

SELECT FROM mydomain.Product 
WHERE this.name.startsWith(Wal) 
ORDER BY this.name ASCENDING

In the case where the example object is null, the JDO query becomes:

SELECT FROM mydomain.Product 
ORDER BY this.name ASCENDING

Let's say you wanted to do a subquery to find all Inventory objects 
containing a Product of a particular name.

Product product = new Product();
product.setName(Wal%);

ListInventory inventory = 
JdoRecord_Utils.executeSubqueryByExample(this.persistenceManager, 
Product.class, product, id, Invetory.class, null);

In the example above, the executeSubqueryByExample parameters are:

persistence Manager
sub query candidate class
sub query example object
connecting field name
candidate class
example object

I understand that it is not a robust as the TypeSafe queries, and I will 
definitely make use of TypeSafe queries as needed.  However, the above is 
very useful for most of what I've seen over the years. My experience is 
building business layers that connect to datastores and building them in 
such a way that the GUI builders never include any queries/SQL directly in 

their code, which allows changing the datastore type and architecture 
without effecting the GUIs.

The issue I have is that even though JDO actually keeps track of what 
values have changed within a bean, there is no easy way to determine that 
from the developer's perspective.  So, I have to create a mechanism within 

the beans myself (items that are not persisted) in order to make this all 
work. If there were at least a way to easily gain that changed field 
information from a JDO object that would be great.  And from that 
indicator I would be able to get the field name and type using reflection. 

 Getting the changed field indicators is what would make the QBE work.

If I'm mistaken in not being able to get a change indicator that reliably 
identifies a field in the bean, please let me know how that is done. From 
the documentation there does not appear to be a standard way of doing 
this.

Tim Gallagher

Clinical  Economic Research
3M Health Information Systems
5000 Buttercup Drive
Castle Rock, CO 80109

Phone: (303) 814-3867




From:
Matthew Adams matt...@matthewadams.me
To:
jdo-dev@db.apache.org
Cc:
tgallag...@mmm.com
Date:
11/03/2011 04:36 PM
Subject:
Re: New Feature Idea



Hi Tim,

We are in the process of standardizing similar functionality, called type
safe query, which is currently functional, albeit proprietary, in the JDO
RI, DataNucleus:

http://www.datanucleus.org/products/accessplatform/jdo/jdoql_typesafe.html

Check that out and see if it meets your needs.

-matthew

On Thu, Nov 3, 2011 at 5:21 PM, tgallag...@mmm.com wrote:

 Hi,

 I've been working the JDO for about 6 months now.  Prior to that I was
 accessing an RMDBs using a tool I created that built JavaBeans to
 represent the DB tables and to manage those tables. I would then build 
the
 business logic on top of that.  Using JDO will 

Using nexus for Apache releases

2011-12-01 Thread Craig L Russell

I thought I'd pass this along while I'm trying to digest it...

http://wiki.apache.org/commons/UsingNexus

Craig L Russell
Architect, Oracle
http://db.apache.org/jdo
408 276-5638 mailto:craig.russ...@oracle.com
P.S. A good JDO? O, Gasp!



JDO TCK Conference Call Friday, Dec 2, 9 am Pacific Time

2011-12-01 Thread Michelle Caisse

Hi,

 We will have our regular meeting Friday, December 2 at 9 am Pacific 
Time to discuss JDO TCK issues and status.


  Dial-in numbers are:
  US Toll free: 866 682-4770
  Germany Frankfurt 06916106
  Germany Toll free: 08006648515
  (Other countries by request)

  To place the call:
  1. Call the toll free number.
  2. Enter the conference number 939-3689#
  3. Enter the security code #

  Agenda:

  1. JDO 3.0.1 release status
  2. News on new feature idea 
http://osdir.com/ml/jdo-dev-db-apache/2011-11/msg2.html - possible 
code contribution from 3M
  3. Case-insensitive properties, patch ready to be checked in? See 
https://issues.apache.org/jira/browse/JDO-696
  4. Support for specification of embedded inherited objects, see 
https://issues.apache.org/jira/browse/JDO-702

  5. Other issues

  Action Items from weeks past:

  [April 8 2011] AI Craig comment on 
https://issues.apache.org/jira/browse/JDO-617 re the utility of the 
update operator.
  [Sep 23 2011] AI Michael document when changing dependencies (to 
DataNucleus) it's necessary to rebuild the exectck project before 
running tck.