2005 IR Help Posted August 27, 2006 Share Posted August 27, 2006 By: Osian (The Welsh Wizzard) - osian Passing Objects as Parameters 2004-11-09 02:03 Hi all, I am currently looking at moving over to Jasper from ReportMill, but I have a couple of things I need to verify. Within my application, I retreive objects which have relationships to other objects e.g. a Sales Order object will know about a depot object and a contract object. The question is, is if I have my SalesOrder object, can I pass this in as a parameter to the report so that I dont have to go and write big complex SQL statements to be executed on a db? The setup that we have is that we are using WebObjects, so if anyone has any advice then please let me know. Also, any example code would be greatfuly appreciated e.g. can we use the Model within EOModeler as the datasource? Regards, Osh By: Mykel Alvis - evilarchitect RE: Passing Objects as Parameters 2004-11-11 09:46 Using a locally cached object, assuming that you aren't doing any lazy initialization, you should be able to pass the object to the report as long as the definitions for the object are available to the report at compile time. You'll have to cast the object, so there must exist a class (at compile time of the report) that is the class of the object you want to pass. Runtime discovery is currently a little complex for a tool like jasper. This might be an issue with you using WO. Writing late binding for dependent objects could cause issues. You'll probably need a specifically flattened dataset and read from that. Specifically, I still think a custom datasource that reads a flattened model (it's readonly data anyway) is the simplest route to go. Link to comment Share on other sites More sharing options...
campbell-ewald Posted July 14, 2009 Share Posted July 14, 2009 Hi Osian, I'm curios, how did you work through this issue? Thanks. Link to comment Share on other sites More sharing options...
Teodor Danciu Posted July 14, 2009 Share Posted July 14, 2009 Hi, What issue? Please descriebe your problem in a fresh thread on these forums, giving as much detail as you can. From your question, we are not sure what exactly is your current problem. Thank you,Teodor Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now