hi all,
I got a question regarding the cmp:
I remember I read this in somewhere: if you trying to mapping the fields in a entity bean which involve different tables you can only use BMP. What about mapping to views? I am only familiar with MS SQL Database, I was wondering since you can call SQL statement in view (which actually involve multiple tables), can you map your fields to View? is this going to work?
Thank you very much to any commends in advance!
-
can you use CMP in database view? (3 messages)
- Posted by: dj jiang
- Posted on: May 30 2002 17:58 EDT
Threaded Messages (3)
- can you use CMP in database view? by Mark Hills on May 31 2002 01:29 EDT
- can you use CMP in database view? by prashant jani on May 31 2002 03:23 EDT
- can you use CMP in database view? by dj jiang on May 31 2002 10:42 EDT
- can you use CMP in database view? by prashant jani on May 31 2002 03:23 EDT
-
can you use CMP in database view?[ Go to top ]
- Posted by: Mark Hills
- Posted on: May 31 2002 01:29 EDT
- in response to dj jiang
Without knowing more about what you're trying to do, I would say yes, you can, but you need to verify that the view you are using is updatable. Depending on how you have structured your view, you may not be able to update it, which would preclude it from being used in your CMPs.
Mark -
can you use CMP in database view?[ Go to top ]
- Posted by: prashant jani
- Posted on: May 31 2002 03:23 EDT
- in response to Mark Hills
Well,
I guess views will be excellent if ur EJB is read only .. ie u r not updating any data.
Else u have to take care of the fields in the view whether updatable or allow for nulls.
Views will definitely help in case where data is to be fetched from multiple tables (say a join)
regards
Jani -
can you use CMP in database view?[ Go to top ]
- Posted by: dj jiang
- Posted on: May 31 2002 10:42 EDT
- in response to prashant jani
Excellent, thank you very much guys!
Well, if I am sure my view is updateable so CMP should work, right?
Regards,