0 Replies Latest reply on Nov 18, 2009 5:59 PM by pcoll

    rich:dataTable Hibernate ERROR on TYPE

    pcoll

      Hi,

      Im trying to fill a dataTable with a List from hibernate.

      this is part of the code that consults the DB and returns a list..

      private List<Casos_soporte> l_casos;
      
      public List<Casos_soporte> getL_casos() {
       Session sesion=HibernateUtil.getSessionFactory().openSession();
       this.l_casos=sesion.createQuery("from Casos_soporte").list();
       return l_casos;
      }
      
      public void setL_casos(List<Casos_soporte> l_casos) {
       this.l_casos = l_casos;
      }
      


      Here is in the JSP

      <rich:dataTable id="sampleData" value="#{operaciones_casos.l_casos}"
       var="loc" rows="10">
       <rich:column>
       <h:outputText value="#{loc.cod_caso}" />
       </rich:column>
       <rich:column>
       <h:outputText value="#{loc.fecha}" />
       </rich:column>
      </rich:dataTable>
      



      by doing this im getting this ERROR:

      javax.servlet.ServletException: /index.jsp(29,2) '#{operaciones_casos.l_casos}' Error reading 'l_casos' on type persistencia.Operaciones_casos
      javax.faces.webapp.FacesServlet.service(FacesServlet.java:277)
      org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:178)
      org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:290)
      org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:388)
      org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:515)
      org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      


      I did a system.out of the list from hibernate to see if there was an error with that, its working, i get a list of data..I was able to go through that list and print out each of the columns.

      Im new using RichFaces