Zdrenka's Profile
Reputation: 6
Worker
- Group:
- Contributors
- Active Posts:
- 116 (0.09 per day)
- Joined:
- 24-November 09
- Profile Views:
- 5,905
- Last Active:
May 07 2013 07:05 AM- Currently:
- Offline
Previous Fields
- Country:
- GB
- OS Preference:
- Linux
- Favorite Browser:
- Chrome
- Favorite Processor:
- Intel
- Favorite Gaming Platform:
- XBox
- Your Car:
- Who Cares
- Dream Kudos:
- 50
Latest Visitors
-
bucky112 
02 May 2013 - 04:45 -
tlhIn`toq 
23 Nov 2012 - 13:37 -
RCR 
06 Jul 2012 - 08:32 -
AES 
28 Sep 2011 - 03:27 -
carsonk 
05 Jul 2011 - 18:35 -
Momerath 
21 Jun 2011 - 18:20 -
Asusultra 
19 May 2011 - 18:59 -
macosxnerd101 
19 May 2011 - 18:22 -
CodingSup3rna... 
15 May 2011 - 11:07 -
Ronald91 
14 May 2011 - 12:54
Posts I've Made
-
In Topic: Vector cannot be cast ArrayList..
Posted 25 Jun 2012
Yeah I tried what you mentioned
public DateUpdateEventList getDateUpdateEvents() { DateUpdateEventList dispList = new DateUpdateEventList(); String sql = "select * from display where date_update_frequency > 0"; Query query = manager.createNativeQuery(sql); List results = query.getResultList(); System.out.println(results.get(0).getClass()); //for (Vector v : results) { //dispList.addDate(v); //} return dispList; }
However I got the same error and a HUGE list of the following:
ERROR: null
ERROR: null
ERROR: null
ERROR: null
Maybe something wrong with my manager.createNativeQuery(0)?
I have just realised that that return statement would return a null :\ *face palm* -
In Topic: Vector cannot be cast ArrayList..
Posted 25 Jun 2012
javax.ejb.EJBException: nested exception is: java.rmi.ServerException: RemoteException occurred in server thread; nested exception is: java.rmi.RemoteException: null; nested exception is: java.lang.ClassCastException: java.util.Vector cannot be cast to java.util.ArrayList java.rmi.ServerException: RemoteException occurred in server thread; nested exception is: java.rmi.RemoteException: null; nested exception is: java.lang.ClassCastException: java.util.Vector cannot be cast to java.util.ArrayList at com.sun.corba.ee.impl.javax.rmi.CORBA.Util.mapSystemException(Util.java:243) at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.privateInvoke(StubInvocationHandlerImpl.java:205) at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.invoke(StubInvocationHandlerImpl.java:152) at com.sun.corba.ee.impl.presentation.rmi.bcel.BCELStubBase.invoke(BCELStubBase.java:225) at com.jmwrti.session.event.__EventRemote_Remote_DynamicStub.getDateUpdateEvents(com/jmwrti/session/event/__EventRemote_Remote_DynamicStub.java) at com.jmwrti.session.event._EventRemote_Wrapper.getDateUpdateEvents(com/jmwrti/session/event/_EventRemote_Wrapper.java) at com.jmwrti.rtiserver.EventProcessor.getDateUpdates(EventProcessor.java:212) at com.jmwrti.rtiserver.EventProcessor.run(EventProcessor.java:302) at java.lang.Thread.run(Thread.java:722) Caused by: java.rmi.RemoteException: null; nested exception is: java.lang.ClassCastException: java.util.Vector cannot be cast to java.util.ArrayList at com.sun.enterprise.iiop.POAProtocolMgr.mapException(POAProtocolMgr.java:251) at com.sun.ejb.containers.BaseContainer.postInvoke(BaseContainer.java:1411) at com.sun.ejb.containers.BaseContainer.postInvoke(BaseContainer.java:1316) at com.sun.ejb.containers.EJBObjectInvocationHandler.invoke(EJBObjectInvocationHandler.java:210) at com.sun.ejb.containers.EJBObjectInvocationHandlerDelegate.invoke(EJBObjectInvocationHandlerDelegate.java:117) at $Proxy86.getDateUpdateEvents(Unknown Source) at sun.reflect.GeneratedMethodAccessor628.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.sun.corba.ee.impl.presentation.rmi.ReflectiveTie._invoke(ReflectiveTie.java:154) at com.sun.corba.ee.impl.protocol.CorbaServerRequestDispatcherImpl.dispatchToServant(CorbaServerRequestDispatcherImpl.java:687) at com.sun.corba.ee.impl.protocol.CorbaServerRequestDispatcherImpl.dispatch(CorbaServerRequestDispatcherImpl.java:227) at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleRequestRequest(CorbaMessageMediatorImpl.java:1846) at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:1706) at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleInput(CorbaMessageMediatorImpl.java:1088) at com.sun.corba.ee.impl.protocol.giopmsgheaders.RequestMessage_1_2.callback(RequestMessage_1_2.java:223) at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleRequest(CorbaMessageMediatorImpl.java:806) at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.dispatch(CorbaMessageMediatorImpl.java:563) at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.doWork(CorbaMessageMediatorImpl.java:2567) at com.sun.corba.ee.impl.orbutil.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:555) Caused by: java.lang.ClassCastException: java.util.Vector cannot be cast to java.util.ArrayList at com.jmwrti.session.event.EventBean.getDateUpdateEvents(EventBean.java:444) at sun.reflect.GeneratedMethodAccessor629.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.sun.enterprise.security.application.EJBSecurityManager.runMethod(EJBSecurityManager.java:1011) at com.sun.enterprise.security.SecurityUtil.invoke(SecurityUtil.java:175) at com.sun.ejb.containers.BaseContainer.invokeTargetBeanMethod(BaseContainer.java:2920) at com.sun.ejb.containers.BaseContainer.intercept(BaseContainer.java:4011) at com.sun.ejb.containers.EJBObjectInvocationHandler.invoke(EJBObjectInvocationHandler.java:203) ... 16 more javax.ejb.EJBException: nested exception is: java.rmi.ServerException: RemoteException occurred in server thread; nested exception is: java.rmi.RemoteException: null; nested exception is: java.lang.ClassCastException: java.util.Vector cannot be cast to java.util.ArrayList at com.jmwrti.session.event._EventRemote_Wrapper.getDateUpdateEvents(com/jmwrti/session/event/_EventRemote_Wrapper.java) at com.jmwrti.rtiserver.EventProcessor.getDateUpdates(EventProcessor.java:212) at com.jmwrti.rtiserver.EventProcessor.run(EventProcessor.java:302) at java.lang.Thread.run(Thread.java:722)
Sorry if this looks a mess I wasn't to sure how I should paste this in.. -
In Topic: get certain value from object
Posted 31 Aug 2011
never mind, I've sorted it out now with the following code:
for(Object s: list) { if(s.toString().contains("Value")) { slist.add(s); } } -
In Topic: Favorite Candy(old skool)
Posted 11 Jul 2011
Whisper Gold! they came back for a short while...I think its just a England thing though... -
In Topic: A Great C# Learning Resource!
Posted 2 Jul 2011
A good place that I have been using is Project Euler not so much for gaming but good coding concepts and handy for making your code very efficient
My Information
- Member Title:
- D.I.C Head
- Age:
- 25 years old
- Birthday:
- February 16, 1988
- Gender:
-
- Location:
- UK
- Interests:
- Learning and reading
- Full Name:
- Karl Zdrenka
- Years Programming:
- 5
- Programming Languages:
- Java,C#, C++, Java Script, SQL, WPF, VB.NET, ASP.NET
Contact Information
- E-mail:
- Click here to e-mail me
- MSN:
-
Zdrenka@hotmail.com
- Website URL:
-
http://doitwithlinux.blogspot.com/
- Facebook:
- http://www.facebook.com/zdrenka
Friends
|
|


Find Topics
Find Posts
View Reputation Given
|
Comments
SingingBush
09 Mar 2010 - 12:12