[JBoss Seam] - database union in ejb3
by kaviarasu
Hi i want to write a query as i had given below in ejb3
select field_1,field_2 from table1 t1,table2 t2 where t1.pk=t2.fk
union
select field_1,field_2 from table1 t1,table3 t3 where t1.pk=t3.fk
where
Table 1 is the entity with PK as a primary key.
Table 2 is using PK as a foreign key.
Table 3 is using PK as a foreign key.
Tables 2 and 3 are only related through that foreign key and contain dissimilar data that relates to Table 1.
The relationship between table 1 & 2 and 1 & 3 are both one to many.
can any onr suggest me how to achive this
my entity bean is
@Entity
| @Table(name = "TBL_REVIEWS")
|
|
| @SecondaryTables({
| @SecondaryTable(name="TBL_USER_REVIEWS",
| pkJoinColumns={@PrimaryKeyJoinColumn (name="REVIEW_ENTRY_ID")}),
| @SecondaryTable(name="TBL_COMMENTS",
| pkJoinColumns={@PrimaryKeyJoinColumn (name="REVIEW_ENTRY_ID")})
| })
can any one help me soon
thanks
regards
Kaviarasu
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4066887#4066887
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4066887
18Â years, 9Â months
[JBoss Portal] - Re: Giving Admin Priviledges to another Role
by roth
Hi Thomas
"thomas.heute(a)jboss.com" wrote : If you want them to be admin why don't you add them the admin role ?
|
Because I later want to integrate the portal with my existing ldap. Instead of adding a new role for every system I attach to my ldap ('admin' for the portal, 'root' for system x, 'administrator' for system y), I want to use already existing roles.
"thomas.heute(a)jboss.com" wrote : But you can map this role to any of your business role (see the spec and Java security in general)
That was what I was trying to do. Do the examples I posted look sensible? Or did I approach this in all wrongly? The above is what looks right to me, but I don't know much about java security. I did read the reference guide about that topic though, that's how I came up with the above.
Thanks
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4066885#4066885
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4066885
18Â years, 9Â months
[JBoss Seam] - Trouble migrating to seam 2.0
by swd847
I am having trouble migrating my appliation to SEAM 2.0 the error I get is:
| 14:58:36,412 ERROR [STDERR] java.lang.UnsupportedOperationException
| 14:58:36,414 ERROR [STDERR] at com.sun.faces.config.ConfigureListener$InitFacesContext.getViewRoot(ConfigureListener.java:1690)
| 14:58:36,414 ERROR [STDERR] at com.sun.faces.util.MessageFactory.getMessage(MessageFactory.java:113)
| 14:58:36,414 ERROR [STDERR] at com.sun.faces.util.MessageUtils.getExceptionMessageString(MessageUtils.java:277)
| 14:58:36,414 ERROR [STDERR] at com.sun.faces.config.ConfigureListener.configure(ConfigureListener.java:855)
| 14:58:36,415 ERROR [STDERR] at com.sun.faces.config.ConfigureListener.configure(ConfigureListener.java:502)
| 14:58:36,416 ERROR [STDERR] at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:402)
| 14:58:36,416 ERROR [STDERR] at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3854)
| 14:58:36,417 ERROR [STDERR] at org.apache.catalina.core.StandardContext.start(StandardContext.java:4359)
| 14:58:36,418 ERROR [STDERR] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:761)
| 14:58:36,418 ERROR [STDERR] at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:741)
| 14:58:36,419 ERROR [STDERR] at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:553)
| 14:58:36,420 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| 14:58:36,420 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| 14:58:36,421 ERROR [STDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| 14:58:36,422 ERROR [STDERR] at java.lang.reflect.Method.invoke(Method.java:585)
| 14:58:36,423 ERROR [STDERR] at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:297)
| 14:58:36,423 ERROR [STDERR] at org.jboss.mx.server.RawDynamicInvoker.invoke(RawDynamicInvoker.java:164)
| 14:58:36,424 ERROR [STDERR] at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
| 14:58:36,431 ERROR [STDERR] at org.apache.catalina.core.StandardContext.init(StandardContext.java:5310)
| 14:58:36,432 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| 14:58:36,432 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| 14:58:36,433 ERROR [STDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| 14:58:36,433 ERROR [STDERR] at java.lang.reflect.Method.invoke(Method.java:585)
| 14:58:36,434 ERROR [STDERR] at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:297)
| 14:58:36,434 ERROR [STDERR] at org.jboss.mx.server.RawDynamicInvoker.invoke(RawDynamicInvoker.java:164)
| 14:58:36,435 ERROR [STDERR] at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
| 14:58:36,435 ERROR [STDERR] at org.jboss.web.tomcat.service.TomcatDeployer.performDeployInternal(TomcatDeployer.java:301)
|
|
further down there is also this:
|
| Exception sending context initialized event to listener instance of class org.jboss.web.jsf.integration.config.JBossJSFConfigureListener
| java.lang.ClassCastException: com.sun.faces.config.WebConfiguration
| at com.sun.faces.config.WebConfiguration.getInstance(WebConfiguration.java:135)
| at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:249)
| at org.jboss.web.jsf.integration.config.JBossJSFConfigureListener.contextInitialized(JBossJSFConfigureListener.java:69)
| at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3854)
| at org.apache.catalina.core.StandardContext.start(StandardContext.java:4359)
| at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:761)
| at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:741)
| at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:553)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:297)
| at org.jboss.mx.server.RawDynamicInvoker.invoke(RawDynamicInvoker.java:164)
| at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
| at org.apache.catalina.core.StandardContext.init(StandardContext.java:5310)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:297)
| at org.jboss.mx.server.RawDynamicInvoker.invoke(RawDynamicInvoker.java:164)
| at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
| at org.jboss.web.tomcat.service.TomcatDeployer.performDeployInternal(TomcatDeployer.java:301)
| at org.jboss.web.tomcat.service.TomcatDeployer.performDeploy(TomcatDeployer.java:104)
|
|
Does anyone have any idea what could be causing this?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4066884#4066884
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4066884
18Â years, 9Â months