Reverse Engineer DB View with Spring Roo
I am using roo for a project with an existing DB. I've attempted to reverse engineer a view which works, but I can't figure out how to call it or use it.
It creates two sets of files:
ViewName.java (and supporting files)
ViewNamePK.java (and supporting files)
I try to make a finder like:
And that never works.
Reading the in the Roo documentation, it indicates that views should not be used except for specialized use cases (what ever that means).
So, question 1, should I be using views and if so, how do I use them and create a finder? (As stated below, I'm trying to use the finders it creates by default, and they just return lists of nulls. I've manually created a finder, and it also returns a list of nulls).
Question 2, if views are not to be used, how can I do a simple table join so that I don't have to get all of the properties from all of the joined tables? I'm only interested in a few columns from each and to do multiple queries seems like a waste of cycles.....
In executing the find all method, it returns a List with the right number of items, but all items are null. Obviously, I'm not doing something right.