Search the web
Sign In
New User? Sign Up
SimpleORM
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Real people. Real stories. See how Yahoo! Groups impacts members worldwide.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
findReferencing?   Message List  
Reply | Forward Message #1776 of 1847 |
How do you feel about having a findReferencing method in SRecordInstance, just
like the existing findReference there?

That'd make it just as easy to lazily fetch the one-to-many as the many-to-one
relationship.

E.g.
Already:
Department department = employee.findReference(employee.DEPARTMENT);

Proposing also:
List<Employee> employess = department.findReferencing(employee.DEPARTMENT);

Thanks,
Josh





Mon Jul 6, 2009 11:52 pm

spoerrij
Offline Offline
Send Email Send Email

Forward
Message #1776 of 1847 |
Expand Messages Author Sort by Date

How do you feel about having a findReferencing method in SRecordInstance, just like the existing findReference there? That'd make it just as easy to lazily...
spoerrij
Offline Send Email
Jul 6, 2009
11:54 pm

A good question, and the answer is no. Suppose one performed a query to select Employees in Sales where Salary > 100000 order by Name What would you expect...
berglas@...
Send Email
Jul 7, 2009
12:45 am

OK. Should we then widen the SSessionI interface? It's nice to be able to write fully testable code that doesn't depend on the concrete SSessionJdbc. But you...
spoerrij
Offline Send Email
Jul 7, 2009
3:21 am

I haven't bothered putting abstract classes on things like SSessionJdbc because I'm not sure that it is useful. Mocking out the database essentially mocks out...
berglas@...
Send Email
Jul 7, 2009
6:08 am
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help