how to display data in DataTable

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

how to display data in DataTable

Shibi Thomas
Hi,
 
i am trying to use <x:dataTable to diplay a resultset [from postgresql]. I have wrapped the resultset into a JDBCrowset. I am using jetty . Basically the data doesn't get displayed on the we browser.
 
i get the  following error:
 
13:40:15.610 WARN!! [P1-19] org.apache.myfaces.renderkit.html.HtmlRenderKitImpl.
getRenderer(HtmlRenderKitImpl.java:67) >36> Unsupported component-family/rendere
r-type: javax.faces.ViewRoot/org.apache.myfaces.Table
 
Could anybody give an example of how they have done this or kindy help me here
--
Kind Regards
Shibi Thomas



 
Reply | Threaded
Open this post in threaded view
|

Re: how to display data in DataTable

Johannes Hiemer

Hi Shibi,
here is an example on how it works for me:
<h:dataTable id="bean" rowClasses="row"
                                value="#{searchSystemdataSpringBean.bean}"
                                var="systemdata" styleClass="hidden">
                                <h:column>
                                        <f:facet name="header">
                                                <h:outputText value="#{bundle.searchSystemTagNumber}" />
                                        </f:facet>
                                        <h:commandButton styleClass="button" id="tagnumber" value="#{systemdata.sdtagnumber}"  onclick="javascript: passToParentWindow(id, value)" />
                                </h:column>  
                                <h:column>
                                        <f:facet name="header">
                                                <h:outputText  value="#{bundle.searchSystemModel}" />
                                        </f:facet>
                                        <h:outputText id="model" value="#{systemdata.sdmodel}" />
                                </h:column>
                                <h:column>
                                        <f:facet name="header">
                                                <h:outputText  value="#{bundle.searchSystemSn}" />
                                        </f:facet>
                                        <h:outputText id="systemnumber" value="#{systemdata.sdsn}" />
                                </h:column>  
                                <h:column>
                                        <f:facet name="header">
                                                <h:outputText value="#{bundle.searchSystemType}" />
                                        </f:facet>
                                        <h:outputText id="systemtype" value="#{systemdata.sdtype}" />
                                </h:column>
                        </h:dataTable>
The important things are value="#{searchSystemdataSpringBean.bean}" assigning the values from the backed bean, the next stept is putting these values into var="systemdata", and after that you can output them normaly like this:
<h:outputText id="systemtype" value="#{systemdata.sdtype}" />

        private List bean;

        public void search(ActionEvent event) {
                HtmlDataTable dataTable = (HtmlDataTable) event.getComponent()
                                .findComponent("bean");
                if (getSystemdata().getSdtagnumber() == null) {
                        bean = getSystemdataManager().getSystemdatas();
                }
        }
As you can see, bean is just a normal list.
That's the way it works for me, if you could provide a bit more code, it would be easyer to figure out your problem.

Hope that helps.

Regards Johannes
wishfully waiting for the cooling tempest.

"MyFaces Discussion" <[hidden email]> schrieb am 18.07.05 13:57:47:

> Hi,   i am trying to use <x:dataTable to diplay a resultset [from postgresql]. I have wrapped the resultset into a JDBCrowset. I am using jetty . Basically the data doesn't get displayed on the we browser.   i get the  following error:
>   13:40:15.610 WARN!! [P1-19] org.apache.myfaces.renderkit.html.HtmlRenderKitImpl.
> getRenderer(HtmlRenderKitImpl.java:67) >36> Unsupported component-family/rendere
> r-type: javax.faces.ViewRoot/org.apache.myfaces.Table    Could anybody give an example of how they have done this or kindy help me here
> --
> Kind Regards
> Shibi Thomas
>
>
>
>  


______________________________________________________________
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193

Reply | Threaded
Open this post in threaded view
|

Re: how to display data in DataTable

Shibi Thomas
I am using myfaces.
 
The bean class [searchbean] looks like this :
 
 public JdbcRowSet getdataresult()
    {
        if (dataresult != null)
        return dataresult;
        else
            return null;
    }
 
public String doQuery()
    {
     .................
.    .................
     try {
            dataresult  =Connect(sqlquery);
        } catch (SQLException e) {
            e.printStackTrace();  //To change body of catch statement use File | Settings | File Templates.
            ctx.addMessage(null, new FacesMessage(e.toString()));
            return "error";
        } catch (ClassNotFoundException e) {
            e.printStackTrace();  //To change body of catch statement use File | Settings | File Templates.
            ctx.addMessage(null, new FacesMessage(e.toString()));
            return "error";
        }
                    //--------finished
      return "success";
    }    
 

public JdbcRowSet Connect (String query) throws SQLException, ClassNotFoundException {

      Class.forName("org.postgresql.Driver");
      JdbcRowSetImpl jrs = new JdbcRowSetImpl();
      jrs.setCommand(sqlquery);
      jrs.setUrl("jdbc:<a href="postgresql://bungo:5432/vods&quot;)"> postgresql://bungo:5432/vods");
      jrs.setUsername("vodsview");
      jrs.setPassword("");
        System.out.println("inside this method connect");
      jrs.execute();
      return jrs;
    }

 
the showresult.jsp looks like this
 

<?xml version="1.0"?>
<jsp:root version="2.0" xmlns:jsp="
http://java.sun.com/JSP/Page"
 xmlns:h="
http://java.sun.com/jsf/html "
 xmlns:f="
http://java.sun.com/jsf/core "
    xmlns:x="
http://myfaces.apache.org/extensions">

 <jsp:directive.page contentType="text/html;charset=UTF-8"
  isELIgnored="false" />
 <jsp:output omit-xml-declaration="true" doctype-root-element="html"
  doctype-system="
http://www.w3.org/TR/html4/loose.dtd"
  doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN" />

 <html>
  <head>
   <title>VODS log search result</title>
  </head>
  <body>
   This is the result page.
      <f:view>
        <h:dataTable  id = "data"
                rendered = "true"
                styleClass= "table-background"
                rowClasses= "table-odd-row,table-even-row"
                cellpadding="3"
                value="#{searchBean.dataresult}"
                var="row">

           <h:column>
            <f:facet name= "Header">
            <h:outputText value ="Sender"/>
            </f:facet>
            <h:outputText value ="#{row.Sender}" />
           </h:column>


       </h:dataTable>
      </f:view>
      </body>
  </html>
</jsp:root>

I get an error that the resultsetDatamodel is not implemented......i hope this help....
 
Shibi
 
On 7/18/05, Johannes Hiemer <[hidden email]> wrote:

Hi Shibi,
here is an example on how it works for me:
<h:dataTable id="bean" rowClasses="row"
                               value="#{searchSystemdataSpringBean.bean}"
                               var="systemdata" styleClass="hidden">
                               <h:column>
                                       <f:facet name="header">
                                               <h:outputText value="#{bundle.searchSystemTagNumber}" />
                                       </f:facet>
                                       <h:commandButton styleClass="button" id="tagnumber" value="#{systemdata.sdtagnumber}"  onclick="javascript: passToParentWindow(id, value)" />
                               </h:column>
                               <h:column>
                                       <f:facet name="header">
                                               <h:outputText  value="#{ bundle.searchSystemModel}" />
                                       </f:facet>
                                       <h:outputText id="model" value="#{systemdata.sdmodel}" />
                               </h:column>
                               <h:column>
                                       <f:facet name="header">
                                               <h:outputText  value="#{ bundle.searchSystemSn}" />
                                       </f:facet>
                                       <h:outputText id="systemnumber" value="#{systemdata.sdsn}" />
                               </h:column>
                               <h:column>
                                       <f:facet name="header">
                                               <h:outputText value="#{ bundle.searchSystemType}" />
                                       </f:facet>
                                       <h:outputText id="systemtype" value="#{systemdata.sdtype}" />
                               </h:column>
                       </h:dataTable>
The important things are value="#{searchSystemdataSpringBean.bean}" assigning the values from the backed bean, the next stept is putting these values into var="systemdata", and after that you can output them normaly like this:
<h:outputText id="systemtype" value="#{systemdata.sdtype}" />

       private List bean;

       public void search(ActionEvent event) {
               HtmlDataTable dataTable = (HtmlDataTable) event.getComponent()
                               .findComponent("bean");
               if (getSystemdata().getSdtagnumber() == null) {
                       bean = getSystemdataManager().getSystemdatas();
               }
       }
As you can see, bean is just a normal list.
That's the way it works for me, if you could provide a bit more code, it would be easyer to figure out your problem.

Hope that helps.

Regards Johannes
wishfully waiting for the cooling tempest.

"MyFaces Discussion" <[hidden email]> schrieb am 18.07.05 13:57:47:
> Hi,   i am trying to use <x:dataTable to diplay a resultset [from postgresql]. I have wrapped the resultset into a JDBCrowset. I am using jetty . Basically the data doesn't get displayed on the we browser.   i get the  following error:

>   13:40:15.610 WARN!! [P1-19] org.apache.myfaces.renderkit.html.HtmlRenderKitImpl.
> getRenderer(HtmlRenderKitImpl.java:67) >36> Unsupported component-family/rendere
> r-type: javax.faces.ViewRoot /org.apache.myfaces.Table    Could anybody give an example of how they have done this or kindy help me here
> --
> Kind Regards
> Shibi Thomas
>
>
>
>


______________________________________________________________
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193




--
Kind Regards
Shibi Thomas

Can a mother forget the baby at her breast and have no compassion on the child she has borne?
Though she may forget, I will not forget you! See, I have engraved you on the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]


Reply | Threaded
Open this post in threaded view
|

Re: how to display data in DataTable

Bruno Aranda
> I get an error that the resultsetDatamodel is not implemented......i hope this help....

Actually, the javax.faces.model.ResultSetDataModel is not implemented.
Every method is throwing an UnsupportedOperationException. If someone
wants to implement it, please do so. It should not be difficult,

Regards,

Bruno

2005/7/18, Shibi Thomas <[hidden email]>:

> I am using myfaces.
>  
> The bean class [searchbean] looks like this :
>  
>  public JdbcRowSet getdataresult()
>     {
>         if (dataresult != null)
>         return dataresult;
>         else
>             return null;
>     }
>  
> public String doQuery()
>     {
>      .................
> .    .................
>      try {
>             dataresult  =Connect(sqlquery);
>         } catch (SQLException e) {
>             e.printStackTrace();  //To change body of catch statement use
> File | Settings | File Templates.
>             ctx.addMessage(null, new FacesMessage(e.toString()));
>             return "error";
>         } catch (ClassNotFoundException e) {
>             e.printStackTrace();  //To change body of catch statement use
> File | Settings | File Templates.
>             ctx.addMessage(null, new FacesMessage(e.toString()));
>             return "error";
>         }
>                     //--------finished
>       return "success";
>     }    
>  
>  
>
> public JdbcRowSet Connect (String query) throws SQLException,
> ClassNotFoundException {
>
>       Class.forName("org.postgresql.Driver");
>       JdbcRowSetImpl jrs = new JdbcRowSetImpl();
>       jrs.setCommand(sqlquery);
>       jrs.setUrl("jdbc: postgresql://bungo:5432/vods");
>       jrs.setUsername("vodsview");
>       jrs.setPassword("");
>         System.out.println("inside this method connect");
>       jrs.execute();
>       return jrs;
>     }
>  
> the showresult.jsp looks like this
>  
>  
>
> <?xml version="1.0"?>
> <jsp:root version="2.0" xmlns:jsp=" http://java.sun.com/JSP/Page"
>  xmlns:h="http://java.sun.com/jsf/html "
>  xmlns:f="http://java.sun.com/jsf/core "
>     xmlns:x="http://myfaces.apache.org/extensions">
>
>  <jsp:directive.page contentType="text/html;charset=UTF-8"
>   isELIgnored="false" />
>  <jsp:output omit-xml-declaration="true" doctype-root-element="html"
>   doctype-system="http://www.w3.org/TR/html4/loose.dtd"
>   doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN" />
>
>  <html>
>   <head>
>    <title>VODS log search result</title>
>   </head>
>   <body>
>    This is the result page.
>       <f:view>
>         <h:dataTable  id = "data"
>                 rendered = "true"
>                 styleClass= "table-background"
>                 rowClasses= "table-odd-row,table-even-row"
>                 cellpadding="3"
>                 value="#{searchBean.dataresult}"
>                 var="row">
>
>            <h:column>
>             <f:facet name= "Header">
>             <h:outputText value ="Sender"/>
>             </f:facet>
>             <h:outputText value ="#{row.Sender}" />
>            </h:column>
>
>
>        </h:dataTable>
>       </f:view>
>       </body>
>   </html>
> </jsp:root>I get an error that the resultsetDatamodel is not
> implemented......i hope this help....
>  
> Shibi
>  
>  
> On 7/18/05, Johannes Hiemer <[hidden email]> wrote:
> >
> > Hi Shibi,
> > here is an example on how it works for me:
> > <h:dataTable id="bean" rowClasses="row"
> >                                value="#{searchSystemdataSpringBean.bean}"
> >                                var="systemdata" styleClass="hidden">
> >                                <h:column>
> >                                        <f:facet
> name="header">
> >                                              
> <h:outputText value="#{bundle.searchSystemTagNumber}" />
> >                                        </f:facet>
> >                                        <h:commandButton
> styleClass="button" id="tagnumber" value="#{systemdata.sdtagnumber}"
> onclick="javascript: passToParentWindow(id, value)" />
> >                                </h:column>
> >                                <h:column>
> >                                        <f:facet
> name="header">
> >                                              
> <h:outputText  value="#{ bundle.searchSystemModel}" />
> >                                        </f:facet>
> >                                        <h:outputText
> id="model" value="#{systemdata.sdmodel}" />
> >                                </h:column>
> >                                <h:column>
> >                                        <f:facet
> name="header">
> >                                              
> <h:outputText  value="#{ bundle.searchSystemSn}" />
> >                                        </f:facet>
> >                                        <h:outputText
> id="systemnumber" value="#{systemdata.sdsn}" />
> >                                </h:column>
> >                                <h:column>
> >                                        <f:facet
> name="header">
> >                                              
> <h:outputText value="#{ bundle.searchSystemType}" />
> >                                        </f:facet>
> >                                        <h:outputText
> id="systemtype" value="#{systemdata.sdtype}" />
> >                                </h:column>
> >                        </h:dataTable>
> > The important things are value="#{searchSystemdataSpringBean.bean}"
> assigning the values from the backed bean, the next stept is putting these
> values into var="systemdata", and after that you can output them normaly
> like this:
> > <h:outputText id="systemtype" value="#{systemdata.sdtype}" />
> >
> >        private List bean;
> >
> >        public void search(ActionEvent event) {
> >                HtmlDataTable dataTable = (HtmlDataTable)
> event.getComponent()
> >                                .findComponent("bean");
> >                if (getSystemdata().getSdtagnumber() ==
> null) {
> >                        bean =
> getSystemdataManager().getSystemdatas();
> >                }
> >        }
> > As you can see, bean is just a normal list.
> > That's the way it works for me, if you could provide a bit more code, it
> would be easyer to figure out your problem.
> >
> > Hope that helps.
> >
> > Regards Johannes
> > wishfully waiting for the cooling tempest.
> >
> > "MyFaces Discussion" <[hidden email]> schrieb am 18.07.05
> 13:57:47:
> > > Hi,   i am trying to use <x:dataTable to diplay a resultset [from
> postgresql]. I have wrapped the resultset into a JDBCrowset. I am using
> jetty . Basically the data doesn't get displayed on the we browser.   i get
> the  following error:
> > >   13:40:15.610 WARN!! [P1-19]
> org.apache.myfaces.renderkit.html.HtmlRenderKitImpl.
> > > getRenderer(HtmlRenderKitImpl.java:67) >36> Unsupported
> component-family/rendere
> > > r-type: javax.faces.ViewRoot /org.apache.myfaces.Table  
>  Could anybody give an example of how they have done this
> or kindy help me here
> > > --
> > > Kind Regards
> > > Shibi Thomas
> > >
> > >
> > >
> > >
> >
> >
> >
> ______________________________________________________________
> > Verschicken Sie romantische, coole und witzige Bilder per SMS!
> > Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
> >
> >
>
>  
>
> --
> Kind Regards
> Shibi Thomas
>
> Can a mother forget the baby at her breast and have no compassion on the
> child she has borne?
> Though she may forget, I will not forget you! See, I have engraved you on
> the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]
>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: how to display data in DataTable

Bruno Aranda
Shibi, in the meanwhile maybe you could put your results in a List...

Regards,

Bruno

2005/7/18, Bruno Aranda <[hidden email]>:

> > I get an error that the resultsetDatamodel is not implemented......i hope this help....
>
> Actually, the javax.faces.model.ResultSetDataModel is not implemented.
> Every method is throwing an UnsupportedOperationException. If someone
> wants to implement it, please do so. It should not be difficult,
>
> Regards,
>
> Bruno
>
> 2005/7/18, Shibi Thomas <[hidden email]>:
> > I am using myfaces.
> >
> > The bean class [searchbean] looks like this :
> >
> >  public JdbcRowSet getdataresult()
> >     {
> >         if (dataresult != null)
> >         return dataresult;
> >         else
> >             return null;
> >     }
> >
> > public String doQuery()
> >     {
> >      .................
> > .    .................
> >      try {
> >             dataresult  =Connect(sqlquery);
> >         } catch (SQLException e) {
> >             e.printStackTrace();  //To change body of catch statement use
> > File | Settings | File Templates.
> >             ctx.addMessage(null, new FacesMessage(e.toString()));
> >             return "error";
> >         } catch (ClassNotFoundException e) {
> >             e.printStackTrace();  //To change body of catch statement use
> > File | Settings | File Templates.
> >             ctx.addMessage(null, new FacesMessage(e.toString()));
> >             return "error";
> >         }
> >                     //--------finished
> >       return "success";
> >     }
> >
> >
> >
> > public JdbcRowSet Connect (String query) throws SQLException,
> > ClassNotFoundException {
> >
> >       Class.forName("org.postgresql.Driver");
> >       JdbcRowSetImpl jrs = new JdbcRowSetImpl();
> >       jrs.setCommand(sqlquery);
> >       jrs.setUrl("jdbc: postgresql://bungo:5432/vods");
> >       jrs.setUsername("vodsview");
> >       jrs.setPassword("");
> >         System.out.println("inside this method connect");
> >       jrs.execute();
> >       return jrs;
> >     }
> >
> > the showresult.jsp looks like this
> >
> >
> >
> > <?xml version="1.0"?>
> > <jsp:root version="2.0" xmlns:jsp=" http://java.sun.com/JSP/Page"
> >  xmlns:h="http://java.sun.com/jsf/html "
> >  xmlns:f="http://java.sun.com/jsf/core "
> >     xmlns:x="http://myfaces.apache.org/extensions">
> >
> >  <jsp:directive.page contentType="text/html;charset=UTF-8"
> >   isELIgnored="false" />
> >  <jsp:output omit-xml-declaration="true" doctype-root-element="html"
> >   doctype-system="http://www.w3.org/TR/html4/loose.dtd"
> >   doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN" />
> >
> >  <html>
> >   <head>
> >    <title>VODS log search result</title>
> >   </head>
> >   <body>
> >    This is the result page.
> >       <f:view>
> >         <h:dataTable  id = "data"
> >                 rendered = "true"
> >                 styleClass= "table-background"
> >                 rowClasses= "table-odd-row,table-even-row"
> >                 cellpadding="3"
> >                 value="#{searchBean.dataresult}"
> >                 var="row">
> >
> >            <h:column>
> >             <f:facet name= "Header">
> >             <h:outputText value ="Sender"/>
> >             </f:facet>
> >             <h:outputText value ="#{row.Sender}" />
> >            </h:column>
> >
> >
> >        </h:dataTable>
> >       </f:view>
> >       </body>
> >   </html>
> > </jsp:root>I get an error that the resultsetDatamodel is not
> > implemented......i hope this help....
> >
> > Shibi
> >
> >
> > On 7/18/05, Johannes Hiemer <[hidden email]> wrote:
> > >
> > > Hi Shibi,
> > > here is an example on how it works for me:
> > > <h:dataTable id="bean" rowClasses="row"
> > >                                value="#{searchSystemdataSpringBean.bean}"
> > >                                var="systemdata" styleClass="hidden">
> > >                                <h:column>
> > >                                        <f:facet
> > name="header">
> > >
> > <h:outputText value="#{bundle.searchSystemTagNumber}" />
> > >                                        </f:facet>
> > >                                        <h:commandButton
> > styleClass="button" id="tagnumber" value="#{systemdata.sdtagnumber}"
> > onclick="javascript: passToParentWindow(id, value)" />
> > >                                </h:column>
> > >                                <h:column>
> > >                                        <f:facet
> > name="header">
> > >
> > <h:outputText  value="#{ bundle.searchSystemModel}" />
> > >                                        </f:facet>
> > >                                        <h:outputText
> > id="model" value="#{systemdata.sdmodel}" />
> > >                                </h:column>
> > >                                <h:column>
> > >                                        <f:facet
> > name="header">
> > >
> > <h:outputText  value="#{ bundle.searchSystemSn}" />
> > >                                        </f:facet>
> > >                                        <h:outputText
> > id="systemnumber" value="#{systemdata.sdsn}" />
> > >                                </h:column>
> > >                                <h:column>
> > >                                        <f:facet
> > name="header">
> > >
> > <h:outputText value="#{ bundle.searchSystemType}" />
> > >                                        </f:facet>
> > >                                        <h:outputText
> > id="systemtype" value="#{systemdata.sdtype}" />
> > >                                </h:column>
> > >                        </h:dataTable>
> > > The important things are value="#{searchSystemdataSpringBean.bean}"
> > assigning the values from the backed bean, the next stept is putting these
> > values into var="systemdata", and after that you can output them normaly
> > like this:
> > > <h:outputText id="systemtype" value="#{systemdata.sdtype}" />
> > >
> > >        private List bean;
> > >
> > >        public void search(ActionEvent event) {
> > >                HtmlDataTable dataTable = (HtmlDataTable)
> > event.getComponent()
> > >                                .findComponent("bean");
> > >                if (getSystemdata().getSdtagnumber() ==
> > null) {
> > >                        bean =
> > getSystemdataManager().getSystemdatas();
> > >                }
> > >        }
> > > As you can see, bean is just a normal list.
> > > That's the way it works for me, if you could provide a bit more code, it
> > would be easyer to figure out your problem.
> > >
> > > Hope that helps.
> > >
> > > Regards Johannes
> > > wishfully waiting for the cooling tempest.
> > >
> > > "MyFaces Discussion" <[hidden email]> schrieb am 18.07.05
> > 13:57:47:
> > > > Hi,   i am trying to use <x:dataTable to diplay a resultset [from
> > postgresql]. I have wrapped the resultset into a JDBCrowset. I am using
> > jetty . Basically the data doesn't get displayed on the we browser.   i get
> > the  following error:
> > > >   13:40:15.610 WARN!! [P1-19]
> > org.apache.myfaces.renderkit.html.HtmlRenderKitImpl.
> > > > getRenderer(HtmlRenderKitImpl.java:67) >36> Unsupported
> > component-family/rendere
> > > > r-type: javax.faces.ViewRoot /org.apache.myfaces.Table
> >  Could anybody give an example of how they have done this
> > or kindy help me here
> > > > --
> > > > Kind Regards
> > > > Shibi Thomas
> > > >
> > > >
> > > >
> > > >
> > >
> > >
> > >
> > ______________________________________________________________
> > > Verschicken Sie romantische, coole und witzige Bilder per SMS!
> > > Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
> > >
> > >
> >
> >
> >
> > --
> > Kind Regards
> > Shibi Thomas
> >
> > Can a mother forget the baby at her breast and have no compassion on the
> > child she has borne?
> > Though she may forget, I will not forget you! See, I have engraved you on
> > the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]
> >
> >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: how to display data in DataTable

Shibi Thomas
could u please clarify  Q?
some more  more stack trace 
 
 
14:54:24.982 ERROR! [P1-19] org.apache.myfaces.taglib.core.LoadBundleTag.doStartTag(LoadBundleTag.java:123) >34> Resource bundle 'net.sourceforge.myfaces.examples.resource.example_messages' could not be found.
14:54:24.992 ERROR! [P1-19] org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:108) >52> java.lang.Long
javax.faces.el.PropertyNotFoundException: Bean: java.lang.Long, property: id
        at org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor(PropertyResolverImpl.java:464)
        at org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor(PropertyResolverImpl.java:435)
        at org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:398)
        at org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:104)
        at org.apache.myfaces.el.ELParserHelper$MyPropertySuffix.evaluate (ELParserHelper.java:555)
        at org.apache.commons.el.ComplexValue.evaluate(ComplexValue.java:145)
        at org.apache.myfaces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:441)
        at javax.faces.component.UIOutput.getValue (UIOutput.java:75)
        at org.apache.myfaces.renderkit.RendererUtils.getStringValue(RendererUtils.java:296)
        at org.apache.myfaces.renderkit.html.HtmlTextRendererBase.renderInput(HtmlTextRendererBase.java :159)
        at org.apache.myfaces.renderkit.html.HtmlTextRendererBase.encodeEnd(HtmlTextRendererBase.java:77)
        at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:341)
        at org.apache.myfaces.renderkit.RendererUtils.renderChild (RendererUtils.java:494)
        at org.apache.myfaces.renderkit.RendererUtils.renderChildren(RendererUtils.java:471)
        at org.apache.myfaces.renderkit.RendererUtils.renderChild(RendererUtils.java:492)
        at org.apache.myfaces.renderkit.html.HtmlTableRendererBase.renderColumnBody(HtmlTableRendererBase.java:205)
        at org.apache.myfaces.renderkit.html.HtmlTableRendererBase.encodeChildren(HtmlTableRendererBase.java:160)
        at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:329)
        at org.apache.myfaces.component.html.ext.HtmlDataTable.encodeChildren(HtmlDataTable.java:507)
        at javax.faces.webapp.UIComponentTag.encodeChildren (UIComponentTag.java:380)
        at javax.faces.webapp.UIComponentTag.doEndTag(UIComponentTag.java:288)
        at org.apache.myfaces.taglib.UIComponentBodyTagBase.doEndTag(UIComponentBodyTagBase.java:98)
        at org.apache.jsp.showResult_jsp._jspx_meth_x_dataTable_0(showResult_jsp.java:185)
        at org.apache.jsp.showResult_jsp._jspx_meth_f_view_0(showResult_jsp.java:118)
        at org.apache.jsp.showResult_jsp._jspService (showResult_jsp.java:84)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
        at org.apache.jasper.servlet.JspServletWrapper.service (JspServletWrapper.java:324)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
        at javax.servlet.http.HttpServlet.service (HttpServlet.java:689)
        at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427)
        at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:475)
        at org.mortbay.jetty.servlet.Dispatcher.dispatch(Dispatcher.java:275)
        at org.mortbay.jetty.servlet.Dispatcher.forward(Dispatcher.java:169)
        at org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch (ServletExternalContextImpl.java:405)
        at org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:280)
        at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java :300)
        at javax.faces.webapp.FacesServlet.service(FacesServlet.java:110)
        at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427)
        at org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter (WebApplicationHandler.java:832)
        at org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:112)
        at org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter (WebApplicationHandler.java:823)
        at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:473)
        at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567)
        at org.mortbay.http.HttpContext.handle(HttpContext.java:1565)
        at org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:635)
        at org.mortbay.http.HttpContext.handle (HttpContext.java:1517)
        at org.mortbay.http.HttpServer.service(HttpServer.java:954)
        at org.mortbay.http.HttpConnection.service(HttpConnection.java:814)
        at org.mortbay.http.HttpConnection.handleNext (HttpConnection.java:981)
        at org.mortbay.http.HttpConnection.handle(HttpConnection.java:831)
        at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:244)
        at org.mortbay.util.ThreadedServer.handle (ThreadedServer.java:357)
        at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:534)

 
On 7/25/05, Bruno Aranda <[hidden email]> wrote:
Are you sure that results.getObject(1)) returns an object which has an
Id attribute accessible with yourObject.getId ()? Could you post some
more of the stack trace?

Regards,

Bruno

2005/7/25, Shibi Thomas <[hidden email]>:

> hello tried using a list .. I get an error
>
> 14:54:25.062 WARN!! [P1-19]
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:588)
> >11> /TranFind/startSearch.jsf:
> javax.faces.FacesException: Expression: '#{ row.id }'
>
> here is the code snippet
>
>
>
> <x:dataTable  id = "data"
>                 styleClass= "standardTable"
>                 headerClass = "standardTable_Header"
>
> rowClasses="standardTable_Row1,standardTable_Row2"
>
> columnClasses="standardTable_Column,standardTable_ColumnCentered,standardTable_Column"
>                 value="#{ searchBean.list}"
>                 var="row"
>                 preserveDataModel ="true">
>
>            <h:column>
>             <f:facet name= "Header">
>              <h:outputText value="ID" />
>             </f:facet>
>             <h:outputText id = "Id" value ="#{ row.id}" />
>            </h:column>
> </x:dataTable>
>
> any clue guys. I have added the result as and object to the list.
>
> while( results.next())
>         {
>             rslist.add(results.getObject(1));
>         }
>
> kind regards
> shibi
>
> On 7/18/05, Bruno Aranda <[hidden email]> wrote:
> > Shibi, in the meanwhile maybe you could put your results in a List...
> >
> > Regards,
> >
> > Bruno
> >
> > 2005/7/18, Bruno Aranda <[hidden email]>:
> > > > I get an error that the resultsetDatamodel is not implemented......i
> hope this help....
> > >
> > > Actually, the javax.faces.model.ResultSetDataModel is
> not implemented.
> > > Every method is throwing an UnsupportedOperationException. If someone
> > > wants to implement it, please do so. It should not be difficult,
> > >
> > > Regards,
> > >
> > > Bruno
> > >
> > > 2005/7/18, Shibi Thomas < [hidden email]>:
> > > > I am using myfaces.
> > > >
> > > > The bean class [searchbean] looks like this :
> > > >
> > > >  public JdbcRowSet getdataresult()
> > > >     {
> > > >         if (dataresult != null)
> > > >         return dataresult;
> > > >         else
> > > >             return null;
> > > >     }
> > > >
> > > > public String doQuery()
> > > >     {
> > > >      .................
> > > > .    .................
> > > >      try {
> > > >             dataresult  =Connect(sqlquery);
> > > >         } catch (SQLException e) {
> > > >             e.printStackTrace();  //To change body of catch statement
> use
> > > > File | Settings | File Templates.
> > > >             ctx.addMessage (null, new FacesMessage(e.toString()));
> > > >             return "error";
> > > >         } catch (ClassNotFoundException e) {
> > > >             e.printStackTrace();  //To change body of catch statement
> use
> > > > File | Settings | File Templates.
> > > >             ctx.addMessage(null, new FacesMessage(e.toString()));
> > > >             return "error";
> > > >         }
> > > >                     //--------finished
> > > >       return "success";
> > > >     }
> > > >
> > > >
> > > >
> > > > public JdbcRowSet Connect (String query) throws SQLException,
> > > > ClassNotFoundException {
> > > >
> > > >       Class.forName("org.postgresql.Driver");
> > > >       JdbcRowSetImpl jrs = new JdbcRowSetImpl();
> > > >       jrs.setCommand(sqlquery);
> > > >       jrs.setUrl("jdbc: <a href="postgresql://bungo:5432/vods&quot;)">postgresql://bungo:5432/vods");
> > > >       jrs.setUsername("vodsview");
> > > >       jrs.setPassword("");
> > > >         System.out.println ("inside this method connect");
> > > >       jrs.execute ();
> > > >       return jrs;
> > > >     }
> > > >
> > > > the showresult.jsp looks like this
> > > >
> > > >
> > > >
> > > > <?xml version="1.0"?>
> > > > <jsp:root version="2.0" xmlns:jsp=" http://java.sun.com/JSP/Page"
> > > >  xmlns:h=" http://java.sun.com/jsf/html "
> > > >  xmlns:f="http://java.sun.com/jsf/core "
> > > >     xmlns:x=" http://myfaces.apache.org/extensions">
> > > >
> > > >  <jsp:directive.page
> contentType="text/html;charset=UTF-8"
> > > >   isELIgnored="false" />
> > > >  <jsp:output omit-xml-declaration="true" doctype-root-element="html"
> > > >
> doctype-system=" http://www.w3.org/TR/html4/loose.dtd"
> > > >   doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN" />
> > > >
> > > >  <html>
> > > >   <head>
> > > >    <title>VODS log search result</title>
> > > >   </head>
> > > >   <body>
> > > >    This is the result page.
> > > >       <f:view>
> > > >         <h:dataTable  id = "data"
> > > >                 rendered = "true"
> > > >                 styleClass= "table-background"
> > > >                 rowClasses= "table-odd-row,table-even-row"
> > > >                 cellpadding="3"
> > > >                 value="#{searchBean.dataresult }"
> > > >                 var="row">
> > > >
> > > >            <h:column>
> > > >             <f:facet name= "Header">
> > > >             <h:outputText value ="Sender"/>

> > > >             </f:facet>
> > > >             <h:outputText value ="#{row.Sender}" />
> > > >            </h:column>
> > > >
> > > >
> > > >        </h:dataTable>
> > > >       </f:view>
> > > >       </body>
> > > >   </html>
> > > > </jsp:root>I get an error that the resultsetDatamodel is not
> > > > implemented......i hope this help....
> > > >
> > > > Shibi
> > > >
> > > >
> > > > On 7/18/05, Johannes Hiemer <[hidden email]> wrote:
> > > > >
> > > > > Hi Shibi,
> > > > > here is an example on how it works for me:
> > > > > <h:dataTable id="bean" rowClasses="row"
> > > > >
> value="#{searchSystemdataSpringBean.bean }"
> > > > >                                var="systemdata"
> styleClass="hidden">
> > > > >                                <h:column>
> > > > >                                        <f:facet
> > > > name="header">
> > > > >
> > > > <h:outputText value="#{ bundle.searchSystemTagNumber}" />
> > > > >                                        </f:facet>
> > > > >
> <h:commandButton
> > > > styleClass="button" id="tagnumber" value="#{ systemdata.sdtagnumber}"
> > > > onclick="javascript: passToParentWindow(id, value)" />
> > > > >                                </h:column>
> > > > >                                <h:column>
> > > > >                                        <f:facet
> > > > name="header">
> > > > >
> > > > <h:outputText  value="#{ bundle.searchSystemModel}" />
> > > > >                                        </f:facet>
> > > > >
> <h:outputText
> > > > id="model" value="#{systemdata.sdmodel}" />
> > > > >                                </h:column>
> > > > >                                <h:column>

> > > > >                                        <f:facet
> > > > name="header">
> > > > >
> > > > <h:outputText  value="#{ bundle.searchSystemSn}" />
> > > > >                                        </f:facet>
> > > > >
> <h:outputText
> > > > id="systemnumber" value="#{ systemdata.sdsn}" />
> > > > >                                </h:column>
> > > > >                                <h:column>
> > > > >                                        <f:facet
> > > > name="header">
> > > > >
> > > > <h:outputText value="#{ bundle.searchSystemType }" />
> > > > >                                        </f:facet>
> > > > >
> <h:outputText
> > > > id="systemtype" value="#{systemdata.sdtype }" />
> > > > >                                </h:column>
> > > > >                        </h:dataTable>
> > > > > The important things are value="#{ searchSystemdataSpringBean.bean}"
> > > > assigning the values from the backed bean, the next stept is putting
> these
> > > > values into var="systemdata", and after that you can output them
> normaly
> > > > like this:
> > > > > <h:outputText id="systemtype" value="#{systemdata.sdtype}" />
> > > > >
> > > > >        private List bean;
> > > > >
> > > > >        public void search(ActionEvent event) {
> > > > >                HtmlDataTable dataTable = (HtmlDataTable)
> > > > event.getComponent ()
> > > > >
> .findComponent("bean");
> > > > >                if (getSystemdata().getSdtagnumber()
> ==
> > > > null) {
> > > > >                        bean =
> > > > getSystemdataManager().getSystemdatas();
> > > > >                }
> > > > >        }
> > > > > As you can see, bean is just a normal list.
> > > > > That's the way it works for me, if you could provide a bit more

> code, it
> > > > would be easyer to figure out your problem.
> > > > >
> > > > > Hope that helps.
> > > > >
> > > > > Regards Johannes
> > > > > wishfully waiting for the cooling tempest.
> > > > >
> > > > > "MyFaces Discussion" < [hidden email] > schrieb am 18.07.05
> > > > 13:57:47:
> > > > > > Hi,   i am trying to use <x:dataTable to diplay a resultset [from
> > > > postgresql]. I have wrapped the resultset into a JDBCrowset. I am
> using
> > > > jetty . Basically the data doesn't get displayed on the we browser.
> i get
> > > > the  following error:
> > > > > >   13:40:15.610 WARN!! [P1-19]
> > > > org.apache.myfaces.renderkit.html.HtmlRenderKitImpl .
> > > > > > getRenderer(HtmlRenderKitImpl.java:67) >36> Unsupported
> > > > component-family/rendere
> > > > > > r-type: javax.faces.ViewRoot /org.apache.myfaces.Table
> > > >  Could anybody give an example of how they have done this
> > > > or kindy help me here

> > > > > > --
> > > > > > Kind Regards
> > > > > > Shibi Thomas
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > > >
> > > >
> ______________________________________________________________
> > > > > Verschicken Sie romantische, coole und witzige Bilder per SMS!
> > > > > Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
> > > > >
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Kind Regards
> > > > Shibi Thomas
> > > >
> > > > Can a mother forget the baby at her breast and have no compassion on
> the
> > > > child she has borne?
> > > > Though she may forget, I will not forget you! See, I have engraved you
> on
> > > > the palms of my hands; your walls are ever before me. [Isaiah
> 49:15,16]
> > > >
> > > >
> > > >
> > >
> >
>
>
>
> --
>
> Kind Regards
> Shibi Thomas
>
>  Can a mother forget the baby at her breast and have no compassion on the
> child she has borne?
> Though she may forget, I will not forget you! See, I have engraved you on
> the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]
>
>
>



--
Kind Regards
Shibi Thomas

Can a mother forget the baby at her breast and have no compassion on the child she has borne?
Though she may forget, I will not forget you! See, I have engraved you on the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]


Reply | Threaded
Open this post in threaded view
|

RE: how to display data in DataTable

Broekelmann, Mathias
In reply to this post by Shibi Thomas
Nachricht
You have instances of java.lang.Long in your rows. Don´t use {row.id} but {row} since Long doesn´t have a getId() Method.
 
-----Original Message-----
From: Shibi Thomas [mailto:[hidden email]]
Sent: Monday, July 25, 2005 3:13 PM
To: Bruno Aranda; [hidden email]
Subject: Re: how to display data in DataTable

could u please clarify  Q?
some more  more stack trace 
 
 
14:54:24.982 ERROR! [P1-19] org.apache.myfaces.taglib.core.LoadBundleTag.doStartTag(LoadBundleTag.java:123) >34> Resource bundle 'net.sourceforge.myfaces.examples.resource.example_messages' could not be found.
14:54:24.992 ERROR! [P1-19] org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:108) >52> java.lang.Long
javax.faces.el.PropertyNotFoundException: Bean: java.lang.Long, property: id
        at org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor(PropertyResolverImpl.java:464)
        at org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor(PropertyResolverImpl.java:435)
        at org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:398)
        at org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:104)
        at org.apache.myfaces.el.ELParserHelper$MyPropertySuffix.evaluate (ELParserHelper.java:555)
        at org.apache.commons.el.ComplexValue.evaluate(ComplexValue.java:145)
        at org.apache.myfaces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:441)
        at javax.faces.component.UIOutput.getValue (UIOutput.java:75)
        at org.apache.myfaces.renderkit.RendererUtils.getStringValue(RendererUtils.java:296)
        at org.apache.myfaces.renderkit.html.HtmlTextRendererBase.renderInput(HtmlTextRendererBase.java :159)
        at org.apache.myfaces.renderkit.html.HtmlTextRendererBase.encodeEnd(HtmlTextRendererBase.java:77)
        at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:341)
        at org.apache.myfaces.renderkit.RendererUtils.renderChild (RendererUtils.java:494)
        at org.apache.myfaces.renderkit.RendererUtils.renderChildren(RendererUtils.java:471)
        at org.apache.myfaces.renderkit.RendererUtils.renderChild(RendererUtils.java:492)
        at org.apache.myfaces.renderkit.html.HtmlTableRendererBase.renderColumnBody(HtmlTableRendererBase.java:205)
        at org.apache.myfaces.renderkit.html.HtmlTableRendererBase.encodeChildren(HtmlTableRendererBase.java:160)
        at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:329)
        at org.apache.myfaces.component.html.ext.HtmlDataTable.encodeChildren(HtmlDataTable.java:507)
        at javax.faces.webapp.UIComponentTag.encodeChildren (UIComponentTag.java:380)
        at javax.faces.webapp.UIComponentTag.doEndTag(UIComponentTag.java:288)
        at org.apache.myfaces.taglib.UIComponentBodyTagBase.doEndTag(UIComponentBodyTagBase.java:98)
        at org.apache.jsp.showResult_jsp._jspx_meth_x_dataTable_0(showResult_jsp.java:185)
        at org.apache.jsp.showResult_jsp._jspx_meth_f_view_0(showResult_jsp.java:118)
        at org.apache.jsp.showResult_jsp._jspService (showResult_jsp.java:84)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
        at org.apache.jasper.servlet.JspServletWrapper.service (JspServletWrapper.java:324)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
        at javax.servlet.http.HttpServlet.service (HttpServlet.java:689)
        at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427)
        at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:475)
        at org.mortbay.jetty.servlet.Dispatcher.dispatch(Dispatcher.java:275)
        at org.mortbay.jetty.servlet.Dispatcher.forward(Dispatcher.java:169)
        at org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch (ServletExternalContextImpl.java:405)
        at org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:280)
        at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java :300)
        at javax.faces.webapp.FacesServlet.service(FacesServlet.java:110)
        at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427)
        at org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter (WebApplicationHandler.java:832)
        at org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:112)
        at org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter (WebApplicationHandler.java:823)
        at org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:473)
        at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567)
        at org.mortbay.http.HttpContext.handle(HttpContext.java:1565)
        at org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:635)
        at org.mortbay.http.HttpContext.handle (HttpContext.java:1517)
        at org.mortbay.http.HttpServer.service(HttpServer.java:954)
        at org.mortbay.http.HttpConnection.service(HttpConnection.java:814)
        at org.mortbay.http.HttpConnection.handleNext (HttpConnection.java:981)
        at org.mortbay.http.HttpConnection.handle(HttpConnection.java:831)
        at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:244)
        at org.mortbay.util.ThreadedServer.handle (ThreadedServer.java:357)
        at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:534)

 
On 7/25/05, Bruno Aranda <[hidden email]> wrote:
Are you sure that results.getObject(1)) returns an object which has an
Id attribute accessible with yourObject.getId ()? Could you post some
more of the stack trace?

Regards,

Bruno

2005/7/25, Shibi Thomas <[hidden email]>:

> hello tried using a list .. I get an error
>
> 14:54:25.062 WARN!! [P1-19]
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:588)
> >11> /TranFind/startSearch.jsf:
> javax.faces.FacesException: Expression: '#{ row.id }'
>
> here is the code snippet
>
>
>
> <x:dataTable  id = "data"
>                 styleClass= "standardTable"
>                 headerClass = "standardTable_Header"
>
> rowClasses="standardTable_Row1,standardTable_Row2"
>
> columnClasses="standardTable_Column,standardTable_ColumnCentered,standardTable_Column"
>                 value="#{ searchBean.list}"
>                 var="row"
>                 preserveDataModel ="true">
>
>            <h:column>
>             <f:facet name= "Header">
>              <h:outputText value="ID" />
>             </f:facet>
>             <h:outputText id = "Id" value ="#{ row.id}" />
>            </h:column>
> </x:dataTable>
>
> any clue guys. I have added the result as and object to the list.
>
> while( results.next())
>         {
>             rslist.add(results.getObject(1));
>         }
>
> kind regards
> shibi
>
> On 7/18/05, Bruno Aranda <[hidden email]> wrote:
> > Shibi, in the meanwhile maybe you could put your results in a List...
> >
> > Regards,
> >
> > Bruno
> >
> > 2005/7/18, Bruno Aranda <[hidden email]>:
> > > > I get an error that the resultsetDatamodel is not implemented......i
> hope this help....
> > >
> > > Actually, the javax.faces.model.ResultSetDataModel is
> not implemented.
> > > Every method is throwing an UnsupportedOperationException. If someone
> > > wants to implement it, please do so. It should not be difficult,
> > >
> > > Regards,
> > >
> > > Bruno
> > >
> > > 2005/7/18, Shibi Thomas < [hidden email]>:
> > > > I am using myfaces.
> > > >
> > > > The bean class [searchbean] looks like this :
> > > >
> > > >  public JdbcRowSet getdataresult()
> > > >     {
> > > >         if (dataresult != null)
> > > >         return dataresult;
> > > >         else
> > > >             return null;
> > > >     }
> > > >
> > > > public String doQuery()
> > > >     {
> > > >      .................
> > > > .    .................
> > > >      try {
> > > >             dataresult  =Connect(sqlquery);
> > > >         } catch (SQLException e) {
> > > >             e.printStackTrace();  //To change body of catch statement
> use
> > > > File | Settings | File Templates.
> > > >             ctx.addMessage (null, new FacesMessage(e.toString()));
> > > >             return "error";
> > > >         } catch (ClassNotFoundException e) {
> > > >             e.printStackTrace();  //To change body of catch statement
> use
> > > > File | Settings | File Templates.
> > > >             ctx.addMessage(null, new FacesMessage(e.toString()));
> > > >             return "error";
> > > >         }
> > > >                     //--------finished
> > > >       return "success";
> > > >     }
> > > >
> > > >
> > > >
> > > > public JdbcRowSet Connect (String query) throws SQLException,
> > > > ClassNotFoundException {
> > > >
> > > >       Class.forName("org.postgresql.Driver");
> > > >       JdbcRowSetImpl jrs = new JdbcRowSetImpl();
> > > >       jrs.setCommand(sqlquery);
> > > >       jrs.setUrl("jdbc: <A href='postgresql://bungo:5432/vods")'>postgresql://bungo:5432/vods");
> > > >       jrs.setUsername("vodsview");
> > > >       jrs.setPassword("");
> > > >         System.out.println ("inside this method connect");
> > > >       jrs.execute ();
> > > >       return jrs;
> > > >     }
> > > >
> > > > the showresult.jsp looks like this
> > > >
> > > >
> > > >
> > > > <?xml version="1.0"?>
> > > > <jsp:root version="2.0" xmlns:jsp=" http://java.sun.com/JSP/Page"
> > > >  xmlns:h=" http://java.sun.com/jsf/html "
> > > >  xmlns:f="http://java.sun.com/jsf/core "
> > > >     xmlns:x=" <A href='http://myfaces.apache.org/extensions"'>http://myfaces.apache.org/extensions">
> > > >
> > > >  <jsp:directive.page
> contentType="text/html;charset=UTF-8"
> > > >   isELIgnored="false" />
> > > >  <jsp:output omit-xml-declaration="true" doctype-root-element="html"
> > > >
> doctype-system=" http://www.w3.org/TR/html4/loose.dtd"
> > > >   doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN" />
> > > >
> > > >  <html>
> > > >   <head>
> > > >    <title>VODS log search result</title>
> > > >   </head>
> > > >   <body>
> > > >    This is the result page.
> > > >       <f:view>
> > > >         <h:dataTable  id = "data"
> > > >                 rendered = "true"
> > > >                 styleClass= "table-background"
> > > >                 rowClasses= "table-odd-row,table-even-row"
> > > >                 cellpadding="3"
> > > >                 value="#{searchBean.dataresult }"
> > > >                 var="row">
> > > >
> > > >            <h:column>
> > > >             <f:facet name= "Header">
> > > >             <h:outputText value ="Sender"/>
> > > >             </f:facet>
> > > >             <h:outputText value ="#{row.Sender}" />
> > > >            </h:column>
> > > >
> > > >
> > > >        </h:dataTable>
> > > >       </f:view>
> > > >       </body>
> > > >   </html>
> > > > </jsp:root>I get an error that the resultsetDatamodel is not
> > > > implemented......i hope this help....
> > > >
> > > > Shibi
> > > >
> > > >
> > > > On 7/18/05, Johannes Hiemer <[hidden email]> wrote:
> > > > >
> > > > > Hi Shibi,
> > > > > here is an example on how it works for me:
> > > > > <h:dataTable id="bean" rowClasses="row"
> > > > >
> value="#{searchSystemdataSpringBean.bean }"
> > > > >                                var="systemdata"
> styleClass="hidden">
> > > > >                                <h:column>
> > > > >                                        <f:facet
> > > > name="header">
> > > > >
> > > > <h:outputText value="#{ bundle.searchSystemTagNumber}" />
> > > > >                                        </f:facet>
> > > > >
> <h:commandButton
> > > > styleClass="button" id="tagnumber" value="#{ systemdata.sdtagnumber}"
> > > > onclick="javascript: passToParentWindow(id, value)" />
> > > > >                                </h:column>
> > > > >                                <h:column>
> > > > >                                        <f:facet
> > > > name="header">
> > > > >
> > > > <h:outputText  value="#{ bundle.searchSystemModel}" />
> > > > >                                        </f:facet>
> > > > >
> <h:outputText
> > > > id="model" value="#{systemdata.sdmodel}" />
> > > > >                                </h:column>
> > > > >                                <h:column>
> > > > >                                        <f:facet
> > > > name="header">
> > > > >
> > > > <h:outputText  value="#{ bundle.searchSystemSn}" />
> > > > >                                        </f:facet>
> > > > >
> <h:outputText
> > > > id="systemnumber" value="#{ systemdata.sdsn}" />
> > > > >                                </h:column>
> > > > >                                <h:column>
> > > > >                                        <f:facet
> > > > name="header">
> > > > >
> > > > <h:outputText value="#{ bundle.searchSystemType }" />
> > > > >                                        </f:facet>
> > > > >
> <h:outputText
> > > > id="systemtype" value="#{systemdata.sdtype }" />
> > > > >                                </h:column>
> > > > >                        </h:dataTable>
> > > > > The important things are value="#{ searchSystemdataSpringBean.bean}"
> > > > assigning the values from the backed bean, the next stept is putting
> these
> > > > values into var="systemdata", and after that you can output them
> normaly
> > > > like this:
> > > > > <h:outputText id="systemtype" value="#{systemdata.sdtype}" />
> > > > >
> > > > >        private List bean;
> > > > >
> > > > >        public void search(ActionEvent event) {
> > > > >                HtmlDataTable dataTable = (HtmlDataTable)
> > > > event.getComponent ()
> > > > >
> .findComponent("bean");
> > > > >                if (getSystemdata().getSdtagnumber()
> ==
> > > > null) {
> > > > >                        bean =
> > > > getSystemdataManager().getSystemdatas();
> > > > >                }
> > > > >        }
> > > > > As you can see, bean is just a normal list.
> > > > > That's the way it works for me, if you could provide a bit more
> code, it
> > > > would be easyer to figure out your problem.
> > > > >
> > > > > Hope that helps.
> > > > >
> > > > > Regards Johannes
> > > > > wishfully waiting for the cooling tempest.
> > > > >
> > > > > "MyFaces Discussion" < [hidden email] > schrieb am 18.07.05
> > > > 13:57:47:
> > > > > > Hi,   i am trying to use <x:dataTable to diplay a resultset [from
> > > > postgresql]. I have wrapped the resultset into a JDBCrowset. I am
> using
> > > > jetty . Basically the data doesn't get displayed on the we browser.
> i get
> > > > the  following error:
> > > > > >   13:40:15.610 WARN!! [P1-19]
> > > > org.apache.myfaces.renderkit.html.HtmlRenderKitImpl .
> > > > > > getRenderer(HtmlRenderKitImpl.java:67) >36> Unsupported
> > > > component-family/rendere
> > > > > > r-type: javax.faces.ViewRoot /org.apache.myfaces.Table
> > > >  Could anybody give an example of how they have done this
> > > > or kindy help me here
> > > > > > --
> > > > > > Kind Regards
> > > > > > Shibi Thomas
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > > >
> > > >
> ______________________________________________________________
> > > > > Verschicken Sie romantische, coole und witzige Bilder per SMS!
> > > > > Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
> > > > >
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Kind Regards
> > > > Shibi Thomas
> > > >
> > > > Can a mother forget the baby at her breast and have no compassion on
> the
> > > > child she has borne?
> > > > Though she may forget, I will not forget you! See, I have engraved you
> on
> > > > the palms of my hands; your walls are ever before me. [Isaiah
> 49:15,16]
> > > >
> > > >
> > > >
> > >
> >
>
>
>
> --
>
> Kind Regards
> Shibi Thomas
>
>  Can a mother forget the baby at her breast and have no compassion on the
> child she has borne?
> Though she may forget, I will not forget you! See, I have engraved you on
> the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]
>
>
>



--
Kind Regards
Shibi Thomas

Can a mother forget the baby at her breast and have no compassion on the child she has borne?
Though she may forget, I will not forget you! See, I have engraved you on the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]


Reply | Threaded
Open this post in threaded view
|

Re: how to display data in DataTable

Bruno Aranda
In reply to this post by Shibi Thomas
Ok, if you want to use the dataTable you have to provide a List of
objects to it, as it seems you do. In your case you want #{row.id},
which is the equivalent to invoke getId() to one of the objects of
your List. This is why the objects obtained from the ResultSet must
have the method getId(), because otherwise it would not work the EL
#{row.id}...

Moreover, it seems that a bundle is missing in your jar
(net.sourceforge.myfaces.examples.resource.example_messages). You
should verify that you have the example_messages.properties file
inside your jar (or in the WEB-INF/classes folder) in
net/sourceforge/myfaces/examples. I guess you have copied an old
myfaces examples and you forgot to remove the bundle....

I hope that everything is clearer now. If not, ask again ;-)

Bruno


2005/7/25, Shibi Thomas <[hidden email]>:

> could u please clarify  Q?
> some more  more stack trace  
>  
>  
> 14:54:24.982 ERROR! [P1-19]
> org.apache.myfaces.taglib.core.LoadBundleTag.doStartTag(LoadBundleTag.java:123)
> >34> Resource bundle
> 'net.sourceforge.myfaces.examples.resource.example_messages'
> could not be found.
> 14:54:24.992 ERROR! [P1-19]
> org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:108)
> >52> java.lang.Long
> javax.faces.el.PropertyNotFoundException: Bean:
> java.lang.Long, property: id
>          at
> org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor(PropertyResolverImpl.java:464)
>         at
> org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor(PropertyResolverImpl.java:435)
>         at
> org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:398)
>         at
> org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:104)
>         at
> org.apache.myfaces.el.ELParserHelper$MyPropertySuffix.evaluate
> (ELParserHelper.java:555)
>         at
> org.apache.commons.el.ComplexValue.evaluate(ComplexValue.java:145)
>         at
> org.apache.myfaces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:441)
>         at javax.faces.component.UIOutput.getValue
> (UIOutput.java:75)
>         at
> org.apache.myfaces.renderkit.RendererUtils.getStringValue(RendererUtils.java:296)
>         at
> org.apache.myfaces.renderkit.html.HtmlTextRendererBase.renderInput(HtmlTextRendererBase.java
> :159)
>         at
> org.apache.myfaces.renderkit.html.HtmlTextRendererBase.encodeEnd(HtmlTextRendererBase.java:77)
>         at
> javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:341)
>         at
> org.apache.myfaces.renderkit.RendererUtils.renderChild
> (RendererUtils.java:494)
>         at
> org.apache.myfaces.renderkit.RendererUtils.renderChildren(RendererUtils.java:471)
>         at
> org.apache.myfaces.renderkit.RendererUtils.renderChild(RendererUtils.java:492)
>         at
> org.apache.myfaces.renderkit.html.HtmlTableRendererBase.renderColumnBody(HtmlTableRendererBase.java:205)
>         at
> org.apache.myfaces.renderkit.html.HtmlTableRendererBase.encodeChildren(HtmlTableRendererBase.java:160)
>         at
> javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:329)
>         at
> org.apache.myfaces.component.html.ext.HtmlDataTable.encodeChildren(HtmlDataTable.java:507)
>         at javax.faces.webapp.UIComponentTag.encodeChildren
> (UIComponentTag.java:380)
>         at
> javax.faces.webapp.UIComponentTag.doEndTag(UIComponentTag.java:288)
>         at
> org.apache.myfaces.taglib.UIComponentBodyTagBase.doEndTag(UIComponentBodyTagBase.java:98)
>         at
> org.apache.jsp.showResult_jsp._jspx_meth_x_dataTable_0(showResult_jsp.java:185)
>         at
> org.apache.jsp.showResult_jsp._jspx_meth_f_view_0(showResult_jsp.java:118)
>         at org.apache.jsp.showResult_jsp._jspService
> (showResult_jsp.java:84)
>         at
> org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
>         at
> javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
>         at
> org.apache.jasper.servlet.JspServletWrapper.service
> (JspServletWrapper.java:324)
>         at
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
>         at
> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
>         at javax.servlet.http.HttpServlet.service
> (HttpServlet.java:689)
>         at
> org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427)
>         at
> org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:475)
>         at
> org.mortbay.jetty.servlet.Dispatcher.dispatch(Dispatcher.java:275)
>         at
> org.mortbay.jetty.servlet.Dispatcher.forward(Dispatcher.java:169)
>         at
> org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch
> (ServletExternalContextImpl.java:405)
>         at
> org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:280)
>         at
> org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java
> :300)
>         at
> javax.faces.webapp.FacesServlet.service(FacesServlet.java:110)
>         at
> org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427)
>         at
> org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter
> (WebApplicationHandler.java:832)
>         at
> org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:112)
>         at
> org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter
> (WebApplicationHandler.java:823)
>         at
> org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:473)
>         at
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567)
>         at
> org.mortbay.http.HttpContext.handle(HttpContext.java:1565)
>         at
> org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:635)
>         at org.mortbay.http.HttpContext.handle
> (HttpContext.java:1517)
>         at
> org.mortbay.http.HttpServer.service(HttpServer.java:954)
>         at
> org.mortbay.http.HttpConnection.service(HttpConnection.java:814)
>         at org.mortbay.http.HttpConnection.handleNext
> (HttpConnection.java:981)
>         at
> org.mortbay.http.HttpConnection.handle(HttpConnection.java:831)
>         at
> org.mortbay.http.SocketListener.handleConnection(SocketListener.java:244)
>         at org.mortbay.util.ThreadedServer.handle
> (ThreadedServer.java:357)
>         at
> org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:534)
>
>  
>  
> On 7/25/05, Bruno Aranda <[hidden email]> wrote:
> > Are you sure that results.getObject(1)) returns an object which has an
> > Id attribute accessible with yourObject.getId ()? Could you post some
> > more of the stack trace?
> >
> > Regards,
> >
> > Bruno
> >
> > 2005/7/25, Shibi Thomas <[hidden email]>:
> > > hello tried using a list .. I get an error
> > >
> > > 14:54:25.062 WARN!! [P1-19]
> > >
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:588)
> > > >11> /TranFind/startSearch.jsf:
> > > javax.faces.FacesException: Expression: '#{ row.id }'
> > >
> > > here is the code snippet
> > >
> > >
> > >
> > > <x:dataTable  id = "data"
> > >                 styleClass= "standardTable"
> > >                 headerClass = "standardTable_Header"
> > >
> > > rowClasses="standardTable_Row1,standardTable_Row2"
> > >
> > >
> columnClasses="standardTable_Column,standardTable_ColumnCentered,standardTable_Column"
> > >                 value="#{ searchBean.list}"
> > >                 var="row"
> > >                 preserveDataModel ="true">
> > >
> > >            <h:column>
> > >             <f:facet name= "Header">
> > >              <h:outputText value="ID" />
> > >             </f:facet>
> > >             <h:outputText id = "Id" value ="#{ row.id}" />
> > >            </h:column>
> > > </x:dataTable>
> > >
> > > any clue guys. I have added the result as and object to the list.
> > >
> > > while( results.next())
> > >         {
> > >             rslist.add(results.getObject(1));
> > >         }
> > >
> > > kind regards
> > > shibi
> > >
> > > On 7/18/05, Bruno Aranda <[hidden email]> wrote:
> > > > Shibi, in the meanwhile maybe you could put your results in a List...
> > > >
> > > > Regards,
> > > >
> > > > Bruno
> > > >
> > > > 2005/7/18, Bruno Aranda <[hidden email]>:
> > > > > > I get an error that the resultsetDatamodel is not
> implemented......i
> > > hope this help....
> > > > >
> > > > > Actually, the javax.faces.model.ResultSetDataModel
> is
> > > not implemented.
> > > > > Every method is throwing an UnsupportedOperationException. If
> someone
> > > > > wants to implement it, please do so. It should not be difficult,
> > > > >
> > > > > Regards,
> > > > >
> > > > > Bruno
> > > > >
> > > > > 2005/7/18, Shibi Thomas < [hidden email]>:
> > > > > > I am using myfaces.
> > > > > >
> > > > > > The bean class [searchbean] looks like this :
> > > > > >
> > > > > >  public JdbcRowSet getdataresult()
> > > > > >     {
> > > > > >         if (dataresult != null)
> > > > > >         return dataresult;
> > > > > >         else
> > > > > >             return null;
> > > > > >     }
> > > > > >
> > > > > > public String doQuery()
> > > > > >     {
> > > > > >      .................
> > > > > > .    .................
> > > > > >      try {
> > > > > >             dataresult  =Connect(sqlquery);
> > > > > >         } catch (SQLException e) {
> > > > > >             e.printStackTrace();  //To change body of catch
> statement
> > > use
> > > > > > File | Settings | File Templates.
> > > > > >             ctx.addMessage (null, new FacesMessage(e.toString()));
> > > > > >             return "error";
> > > > > >         } catch (ClassNotFoundException e) {
> > > > > >             e.printStackTrace();  //To change body of catch
> statement
> > > use
> > > > > > File | Settings | File Templates.
> > > > > >             ctx.addMessage(null, new FacesMessage(e.toString()));
> > > > > >             return "error";
> > > > > >         }
> > > > > >                     //--------finished
> > > > > >       return "success";
> > > > > >     }
> > > > > >
> > > > > >
> > > > > >
> > > > > > public JdbcRowSet Connect (String query) throws SQLException,
> > > > > > ClassNotFoundException {
> > > > > >
> > > > > >       Class.forName("org.postgresql.Driver");
> > > > > >       JdbcRowSetImpl jrs = new JdbcRowSetImpl();
> > > > > >       jrs.setCommand(sqlquery);
> > > > > >       jrs.setUrl("jdbc: postgresql://bungo:5432/vods");
> > > > > >       jrs.setUsername("vodsview");
> > > > > >       jrs.setPassword("");
> > > > > >         System.out.println ("inside this method connect");
> > > > > >       jrs.execute ();
> > > > > >       return jrs;
> > > > > >     }
> > > > > >
> > > > > > the showresult.jsp looks like this
> > > > > >
> > > > > >
> > > > > >
> > > > > > <?xml version="1.0"?>
> > > > > > <jsp:root version="2.0" xmlns:jsp=" http://java.sun.com/JSP/Page"
> > > > > >  xmlns:h=" http://java.sun.com/jsf/html "
> > > > > >  xmlns:f="http://java.sun.com/jsf/core "
> > > > > >     xmlns:x="
> http://myfaces.apache.org/extensions">
> > > > > >
> > > > > >  <jsp:directive.page
> > > contentType="text/html;charset=UTF-8"
> > > > > >   isELIgnored="false" />
> > > > > >  <jsp:output omit-xml-declaration="true"
> doctype-root-element="html"
> > > > > >
> > > doctype-system=" http://www.w3.org/TR/html4/loose.dtd"
> > > > > >   doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN" />
> > > > > >
> > > > > >  <html>
> > > > > >   <head>
> > > > > >    <title>VODS log search result</title>
> > > > > >   </head>
> > > > > >   <body>
> > > > > >    This is the result page.
> > > > > >       <f:view>
> > > > > >         <h:dataTable  id = "data"
> > > > > >                 rendered = "true"
> > > > > >                 styleClass= "table-background"
> > > > > >                 rowClasses= "table-odd-row,table-even-row"
> > > > > >                 cellpadding="3"
> > > > > >                 value="#{searchBean.dataresult }"
> > > > > >                 var="row">
> > > > > >
> > > > > >            <h:column>
> > > > > >             <f:facet name= "Header">
> > > > > >             <h:outputText value ="Sender"/>
> > > > > >             </f:facet>
> > > > > >             <h:outputText value ="#{row.Sender}" />
> > > > > >            </h:column>
> > > > > >
> > > > > >
> > > > > >        </h:dataTable>
> > > > > >       </f:view>
> > > > > >       </body>
> > > > > >   </html>
> > > > > > </jsp:root>I get an error that the resultsetDatamodel is not
> > > > > > implemented......i hope this help....
> > > > > >
> > > > > > Shibi
> > > > > >
> > > > > >
> > > > > > On 7/18/05, Johannes Hiemer <[hidden email]> wrote:
> > > > > > >
> > > > > > > Hi Shibi,
> > > > > > > here is an example on how it works for me:
> > > > > > > <h:dataTable id="bean" rowClasses="row"
> > > > > > >
> > > value="#{searchSystemdataSpringBean.bean }"
> > > > > > >                                var="systemdata"
> > > styleClass="hidden">
> > > > > > >                                <h:column>
> > > > > > >                                        <f:facet
> > > > > > name="header">
> > > > > > >
> > > > > > <h:outputText value="#{ bundle.searchSystemTagNumber}" />
> > > > > > >                                      
> </f:facet>
> > > > > > >
> > > <h:commandButton
> > > > > > styleClass="button" id="tagnumber" value="#{
> systemdata.sdtagnumber}"
> > > > > > onclick="javascript: passToParentWindow(id, value)" />
> > > > > > >                                </h:column>
> > > > > > >                                <h:column>
> > > > > > >                                        <f:facet
> > > > > > name="header">
> > > > > > >
> > > > > > <h:outputText  value="#{ bundle.searchSystemModel}" />
> > > > > > >                                      
> </f:facet>
> > > > > > >
> > > <h:outputText
> > > > > > id="model" value="#{systemdata.sdmodel}" />
> > > > > > >                                </h:column>
> > > > > > >                                <h:column>
> > > > > > >                                        <f:facet
> > > > > > name="header">
> > > > > > >
> > > > > > <h:outputText  value="#{ bundle.searchSystemSn}" />
> > > > > > >                                      
> </f:facet>
> > > > > > >
> > > <h:outputText
> > > > > > id="systemnumber" value="#{ systemdata.sdsn}" />
> > > > > > >                                </h:column>
> > > > > > >                                <h:column>
> > > > > > >                                        <f:facet
> > > > > > name="header">
> > > > > > >
> > > > > > <h:outputText value="#{ bundle.searchSystemType }" />
> > > > > > >                                      
> </f:facet>
> > > > > > >
> > > <h:outputText
> > > > > > id="systemtype" value="#{systemdata.sdtype }" />
> > > > > > >                                </h:column>
> > > > > > >                        </h:dataTable>
> > > > > > > The important things are value="#{
> searchSystemdataSpringBean.bean}"
> > > > > > assigning the values from the backed bean, the next stept is
> putting
> > > these
> > > > > > values into var="systemdata", and after that you can output them
> > > normaly
> > > > > > like this:
> > > > > > > <h:outputText id="systemtype" value="#{systemdata.sdtype}" />
> > > > > > >
> > > > > > >        private List bean;
> > > > > > >
> > > > > > >        public void search(ActionEvent event) {
> > > > > > >                HtmlDataTable dataTable = (HtmlDataTable)
> > > > > > event.getComponent ()
> > > > > > >
> > > .findComponent("bean");
> > > > > > >                if
> (getSystemdata().getSdtagnumber()
> > > ==
> > > > > > null) {
> > > > > > >                        bean =
> > > > > > getSystemdataManager().getSystemdatas();
> > > > > > >                }
> > > > > > >        }
> > > > > > > As you can see, bean is just a normal list.
> > > > > > > That's the way it works for me, if you could provide a bit more
> > > code, it
> > > > > > would be easyer to figure out your problem.
> > > > > > >
> > > > > > > Hope that helps.
> > > > > > >
> > > > > > > Regards Johannes
> > > > > > > wishfully waiting for the cooling tempest.
> > > > > > >
> > > > > > > "MyFaces Discussion" < [hidden email] > schrieb am
> 18.07.05
> > > > > > 13:57:47:
> > > > > > > > Hi,   i am trying to use <x:dataTable to diplay a resultset
> [from
> > > > > > postgresql]. I have wrapped the resultset into a JDBCrowset. I am
> > > using
> > > > > > jetty . Basically the data doesn't get displayed on the we
> browser.
> > > i get
> > > > > > the  following error:
> > > > > > > >   13:40:15.610 WARN!! [P1-19]
> > > > > >
> org.apache.myfaces.renderkit.html.HtmlRenderKitImpl .
> > > > > > > > getRenderer(HtmlRenderKitImpl.java:67) >36> Unsupported
> > > > > > component-family/rendere
> > > > > > > > r-type: javax.faces.ViewRoot /org.apache.myfaces.Table
> > > > > >  Could anybody give an example of how they have done this
> > > > > > or kindy help me here
> > > > > > > > --
> > > > > > > > Kind Regards
> > > > > > > > Shibi Thomas
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > >
> ______________________________________________________________
> > > > > > > Verschicken Sie romantische, coole und witzige Bilder per SMS!
> > > > > > > Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193 
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > > Kind Regards
> > > > > > Shibi Thomas
> > > > > >
> > > > > > Can a mother forget the baby at her breast and have no compassion
> on
> > > the
> > > > > > child she has borne?
> > > > > > Though she may forget, I will not forget you! See, I have engraved
> you
> > > on
> > > > > > the palms of my hands; your walls are ever before me. [Isaiah
> > > 49:15,16]
> > > > > >
> > > > > >
> > > > > >
> > > > >
> > > >
> > >
> > >
> > >
> > > --
> > >
> > > Kind Regards
> > > Shibi Thomas
> > >
> > >  Can a mother forget the baby at her breast and have no compassion on
> the
> > > child she has borne?
> > > Though she may forget, I will not forget you! See, I have engraved you
> on
> > > the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]
> > >
> > >
> > >
> >
>
>
>
> --
>
> Kind Regards
> Shibi Thomas
>
> Can a mother forget the baby at her breast and have no compassion on the
> child she has borne?
> Though she may forget, I will not forget you! See, I have engraved you on
> the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]
>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: how to display data in DataTable

Bruno Aranda
> You have instances of java.lang.Long in your rows. Don´t use {row.id} but {row} since Long doesn´t have a getId() Method.

Yes, as Mathias points out, I guess you are obtaining Longs from your
ResultSet and you are creating a List with Longs. This may be the
problem...

Bruno

2005/7/25, Bruno Aranda <[hidden email]>:

> Ok, if you want to use the dataTable you have to provide a List of
> objects to it, as it seems you do. In your case you want #{row.id},
> which is the equivalent to invoke getId() to one of the objects of
> your List. This is why the objects obtained from the ResultSet must
> have the method getId(), because otherwise it would not work the EL
> #{row.id}...
>
> Moreover, it seems that a bundle is missing in your jar
> (net.sourceforge.myfaces.examples.resource.example_messages). You
> should verify that you have the example_messages.properties file
> inside your jar (or in the WEB-INF/classes folder) in
> net/sourceforge/myfaces/examples. I guess you have copied an old
> myfaces examples and you forgot to remove the bundle....
>
> I hope that everything is clearer now. If not, ask again ;-)
>
> Bruno
>
>
> 2005/7/25, Shibi Thomas <[hidden email]>:
> > could u please clarify  Q?
> > some more  more stack trace
> >
> >
> > 14:54:24.982 ERROR! [P1-19]
> > org.apache.myfaces.taglib.core.LoadBundleTag.doStartTag(LoadBundleTag.java:123)
> > >34> Resource bundle
> > 'net.sourceforge.myfaces.examples.resource.example_messages'
> > could not be found.
> > 14:54:24.992 ERROR! [P1-19]
> > org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:108)
> > >52> java.lang.Long
> > javax.faces.el.PropertyNotFoundException: Bean:
> > java.lang.Long, property: id
> >          at
> > org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor(PropertyResolverImpl.java:464)
> >         at
> > org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor(PropertyResolverImpl.java:435)
> >         at
> > org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:398)
> >         at
> > org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:104)
> >         at
> > org.apache.myfaces.el.ELParserHelper$MyPropertySuffix.evaluate
> > (ELParserHelper.java:555)
> >         at
> > org.apache.commons.el.ComplexValue.evaluate(ComplexValue.java:145)
> >         at
> > org.apache.myfaces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:441)
> >         at javax.faces.component.UIOutput.getValue
> > (UIOutput.java:75)
> >         at
> > org.apache.myfaces.renderkit.RendererUtils.getStringValue(RendererUtils.java:296)
> >         at
> > org.apache.myfaces.renderkit.html.HtmlTextRendererBase.renderInput(HtmlTextRendererBase.java
> > :159)
> >         at
> > org.apache.myfaces.renderkit.html.HtmlTextRendererBase.encodeEnd(HtmlTextRendererBase.java:77)
> >         at
> > javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:341)
> >         at
> > org.apache.myfaces.renderkit.RendererUtils.renderChild
> > (RendererUtils.java:494)
> >         at
> > org.apache.myfaces.renderkit.RendererUtils.renderChildren(RendererUtils.java:471)
> >         at
> > org.apache.myfaces.renderkit.RendererUtils.renderChild(RendererUtils.java:492)
> >         at
> > org.apache.myfaces.renderkit.html.HtmlTableRendererBase.renderColumnBody(HtmlTableRendererBase.java:205)
> >         at
> > org.apache.myfaces.renderkit.html.HtmlTableRendererBase.encodeChildren(HtmlTableRendererBase.java:160)
> >         at
> > javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:329)
> >         at
> > org.apache.myfaces.component.html.ext.HtmlDataTable.encodeChildren(HtmlDataTable.java:507)
> >         at javax.faces.webapp.UIComponentTag.encodeChildren
> > (UIComponentTag.java:380)
> >         at
> > javax.faces.webapp.UIComponentTag.doEndTag(UIComponentTag.java:288)
> >         at
> > org.apache.myfaces.taglib.UIComponentBodyTagBase.doEndTag(UIComponentBodyTagBase.java:98)
> >         at
> > org.apache.jsp.showResult_jsp._jspx_meth_x_dataTable_0(showResult_jsp.java:185)
> >         at
> > org.apache.jsp.showResult_jsp._jspx_meth_f_view_0(showResult_jsp.java:118)
> >         at org.apache.jsp.showResult_jsp._jspService
> > (showResult_jsp.java:84)
> >         at
> > org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
> >         at
> > javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
> >         at
> > org.apache.jasper.servlet.JspServletWrapper.service
> > (JspServletWrapper.java:324)
> >         at
> > org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
> >         at
> > org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
> >         at javax.servlet.http.HttpServlet.service
> > (HttpServlet.java:689)
> >         at
> > org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427)
> >         at
> > org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:475)
> >         at
> > org.mortbay.jetty.servlet.Dispatcher.dispatch(Dispatcher.java:275)
> >         at
> > org.mortbay.jetty.servlet.Dispatcher.forward(Dispatcher.java:169)
> >         at
> > org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch
> > (ServletExternalContextImpl.java:405)
> >         at
> > org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:280)
> >         at
> > org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java
> > :300)
> >         at
> > javax.faces.webapp.FacesServlet.service(FacesServlet.java:110)
> >         at
> > org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427)
> >         at
> > org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter
> > (WebApplicationHandler.java:832)
> >         at
> > org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:112)
> >         at
> > org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter
> > (WebApplicationHandler.java:823)
> >         at
> > org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:473)
> >         at
> > org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567)
> >         at
> > org.mortbay.http.HttpContext.handle(HttpContext.java:1565)
> >         at
> > org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:635)
> >         at org.mortbay.http.HttpContext.handle
> > (HttpContext.java:1517)
> >         at
> > org.mortbay.http.HttpServer.service(HttpServer.java:954)
> >         at
> > org.mortbay.http.HttpConnection.service(HttpConnection.java:814)
> >         at org.mortbay.http.HttpConnection.handleNext
> > (HttpConnection.java:981)
> >         at
> > org.mortbay.http.HttpConnection.handle(HttpConnection.java:831)
> >         at
> > org.mortbay.http.SocketListener.handleConnection(SocketListener.java:244)
> >         at org.mortbay.util.ThreadedServer.handle
> > (ThreadedServer.java:357)
> >         at
> > org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:534)
> >
> >
> >
> > On 7/25/05, Bruno Aranda <[hidden email]> wrote:
> > > Are you sure that results.getObject(1)) returns an object which has an
> > > Id attribute accessible with yourObject.getId ()? Could you post some
> > > more of the stack trace?
> > >
> > > Regards,
> > >
> > > Bruno
> > >
> > > 2005/7/25, Shibi Thomas <[hidden email]>:
> > > > hello tried using a list .. I get an error
> > > >
> > > > 14:54:25.062 WARN!! [P1-19]
> > > >
> > org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:588)
> > > > >11> /TranFind/startSearch.jsf:
> > > > javax.faces.FacesException: Expression: '#{ row.id }'
> > > >
> > > > here is the code snippet
> > > >
> > > >
> > > >
> > > > <x:dataTable  id = "data"
> > > >                 styleClass= "standardTable"
> > > >                 headerClass = "standardTable_Header"
> > > >
> > > > rowClasses="standardTable_Row1,standardTable_Row2"
> > > >
> > > >
> > columnClasses="standardTable_Column,standardTable_ColumnCentered,standardTable_Column"
> > > >                 value="#{ searchBean.list}"
> > > >                 var="row"
> > > >                 preserveDataModel ="true">
> > > >
> > > >            <h:column>
> > > >             <f:facet name= "Header">
> > > >              <h:outputText value="ID" />
> > > >             </f:facet>
> > > >             <h:outputText id = "Id" value ="#{ row.id}" />
> > > >            </h:column>
> > > > </x:dataTable>
> > > >
> > > > any clue guys. I have added the result as and object to the list.
> > > >
> > > > while( results.next())
> > > >         {
> > > >             rslist.add(results.getObject(1));
> > > >         }
> > > >
> > > > kind regards
> > > > shibi
> > > >
> > > > On 7/18/05, Bruno Aranda <[hidden email]> wrote:
> > > > > Shibi, in the meanwhile maybe you could put your results in a List...
> > > > >
> > > > > Regards,
> > > > >
> > > > > Bruno
> > > > >
> > > > > 2005/7/18, Bruno Aranda <[hidden email]>:
> > > > > > > I get an error that the resultsetDatamodel is not
> > implemented......i
> > > > hope this help....
> > > > > >
> > > > > > Actually, the javax.faces.model.ResultSetDataModel
> > is
> > > > not implemented.
> > > > > > Every method is throwing an UnsupportedOperationException. If
> > someone
> > > > > > wants to implement it, please do so. It should not be difficult,
> > > > > >
> > > > > > Regards,
> > > > > >
> > > > > > Bruno
> > > > > >
> > > > > > 2005/7/18, Shibi Thomas < [hidden email]>:
> > > > > > > I am using myfaces.
> > > > > > >
> > > > > > > The bean class [searchbean] looks like this :
> > > > > > >
> > > > > > >  public JdbcRowSet getdataresult()
> > > > > > >     {
> > > > > > >         if (dataresult != null)
> > > > > > >         return dataresult;
> > > > > > >         else
> > > > > > >             return null;
> > > > > > >     }
> > > > > > >
> > > > > > > public String doQuery()
> > > > > > >     {
> > > > > > >      .................
> > > > > > > .    .................
> > > > > > >      try {
> > > > > > >             dataresult  =Connect(sqlquery);
> > > > > > >         } catch (SQLException e) {
> > > > > > >             e.printStackTrace();  //To change body of catch
> > statement
> > > > use
> > > > > > > File | Settings | File Templates.
> > > > > > >             ctx.addMessage (null, new FacesMessage(e.toString()));
> > > > > > >             return "error";
> > > > > > >         } catch (ClassNotFoundException e) {
> > > > > > >             e.printStackTrace();  //To change body of catch
> > statement
> > > > use
> > > > > > > File | Settings | File Templates.
> > > > > > >             ctx.addMessage(null, new FacesMessage(e.toString()));
> > > > > > >             return "error";
> > > > > > >         }
> > > > > > >                     //--------finished
> > > > > > >       return "success";
> > > > > > >     }
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > public JdbcRowSet Connect (String query) throws SQLException,
> > > > > > > ClassNotFoundException {
> > > > > > >
> > > > > > >       Class.forName("org.postgresql.Driver");
> > > > > > >       JdbcRowSetImpl jrs = new JdbcRowSetImpl();
> > > > > > >       jrs.setCommand(sqlquery);
> > > > > > >       jrs.setUrl("jdbc: postgresql://bungo:5432/vods");
> > > > > > >       jrs.setUsername("vodsview");
> > > > > > >       jrs.setPassword("");
> > > > > > >         System.out.println ("inside this method connect");
> > > > > > >       jrs.execute ();
> > > > > > >       return jrs;
> > > > > > >     }
> > > > > > >
> > > > > > > the showresult.jsp looks like this
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > <?xml version="1.0"?>
> > > > > > > <jsp:root version="2.0" xmlns:jsp=" http://java.sun.com/JSP/Page"
> > > > > > >  xmlns:h=" http://java.sun.com/jsf/html "
> > > > > > >  xmlns:f="http://java.sun.com/jsf/core "
> > > > > > >     xmlns:x="
> > http://myfaces.apache.org/extensions">
> > > > > > >
> > > > > > >  <jsp:directive.page
> > > > contentType="text/html;charset=UTF-8"
> > > > > > >   isELIgnored="false" />
> > > > > > >  <jsp:output omit-xml-declaration="true"
> > doctype-root-element="html"
> > > > > > >
> > > > doctype-system=" http://www.w3.org/TR/html4/loose.dtd"
> > > > > > >   doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN" />
> > > > > > >
> > > > > > >  <html>
> > > > > > >   <head>
> > > > > > >    <title>VODS log search result</title>
> > > > > > >   </head>
> > > > > > >   <body>
> > > > > > >    This is the result page.
> > > > > > >       <f:view>
> > > > > > >         <h:dataTable  id = "data"
> > > > > > >                 rendered = "true"
> > > > > > >                 styleClass= "table-background"
> > > > > > >                 rowClasses= "table-odd-row,table-even-row"
> > > > > > >                 cellpadding="3"
> > > > > > >                 value="#{searchBean.dataresult }"
> > > > > > >                 var="row">
> > > > > > >
> > > > > > >            <h:column>
> > > > > > >             <f:facet name= "Header">
> > > > > > >             <h:outputText value ="Sender"/>
> > > > > > >             </f:facet>
> > > > > > >             <h:outputText value ="#{row.Sender}" />
> > > > > > >            </h:column>
> > > > > > >
> > > > > > >
> > > > > > >        </h:dataTable>
> > > > > > >       </f:view>
> > > > > > >       </body>
> > > > > > >   </html>
> > > > > > > </jsp:root>I get an error that the resultsetDatamodel is not
> > > > > > > implemented......i hope this help....
> > > > > > >
> > > > > > > Shibi
> > > > > > >
> > > > > > >
> > > > > > > On 7/18/05, Johannes Hiemer <[hidden email]> wrote:
> > > > > > > >
> > > > > > > > Hi Shibi,
> > > > > > > > here is an example on how it works for me:
> > > > > > > > <h:dataTable id="bean" rowClasses="row"
> > > > > > > >
> > > > value="#{searchSystemdataSpringBean.bean }"
> > > > > > > >                                var="systemdata"
> > > > styleClass="hidden">
> > > > > > > >                                <h:column>
> > > > > > > >                                        <f:facet
> > > > > > > name="header">
> > > > > > > >
> > > > > > > <h:outputText value="#{ bundle.searchSystemTagNumber}" />
> > > > > > > >
> > </f:facet>
> > > > > > > >
> > > > <h:commandButton
> > > > > > > styleClass="button" id="tagnumber" value="#{
> > systemdata.sdtagnumber}"
> > > > > > > onclick="javascript: passToParentWindow(id, value)" />
> > > > > > > >                                </h:column>
> > > > > > > >                                <h:column>
> > > > > > > >                                        <f:facet
> > > > > > > name="header">
> > > > > > > >
> > > > > > > <h:outputText  value="#{ bundle.searchSystemModel}" />
> > > > > > > >
> > </f:facet>
> > > > > > > >
> > > > <h:outputText
> > > > > > > id="model" value="#{systemdata.sdmodel}" />
> > > > > > > >                                </h:column>
> > > > > > > >                                <h:column>
> > > > > > > >                                        <f:facet
> > > > > > > name="header">
> > > > > > > >
> > > > > > > <h:outputText  value="#{ bundle.searchSystemSn}" />
> > > > > > > >
> > </f:facet>
> > > > > > > >
> > > > <h:outputText
> > > > > > > id="systemnumber" value="#{ systemdata.sdsn}" />
> > > > > > > >                                </h:column>
> > > > > > > >                                <h:column>
> > > > > > > >                                        <f:facet
> > > > > > > name="header">
> > > > > > > >
> > > > > > > <h:outputText value="#{ bundle.searchSystemType }" />
> > > > > > > >
> > </f:facet>
> > > > > > > >
> > > > <h:outputText
> > > > > > > id="systemtype" value="#{systemdata.sdtype }" />
> > > > > > > >                                </h:column>
> > > > > > > >                        </h:dataTable>
> > > > > > > > The important things are value="#{
> > searchSystemdataSpringBean.bean}"
> > > > > > > assigning the values from the backed bean, the next stept is
> > putting
> > > > these
> > > > > > > values into var="systemdata", and after that you can output them
> > > > normaly
> > > > > > > like this:
> > > > > > > > <h:outputText id="systemtype" value="#{systemdata.sdtype}" />
> > > > > > > >
> > > > > > > >        private List bean;
> > > > > > > >
> > > > > > > >        public void search(ActionEvent event) {
> > > > > > > >                HtmlDataTable dataTable = (HtmlDataTable)
> > > > > > > event.getComponent ()
> > > > > > > >
> > > > .findComponent("bean");
> > > > > > > >                if
> > (getSystemdata().getSdtagnumber()
> > > > ==
> > > > > > > null) {
> > > > > > > >                        bean =
> > > > > > > getSystemdataManager().getSystemdatas();
> > > > > > > >                }
> > > > > > > >        }
> > > > > > > > As you can see, bean is just a normal list.
> > > > > > > > That's the way it works for me, if you could provide a bit more
> > > > code, it
> > > > > > > would be easyer to figure out your problem.
> > > > > > > >
> > > > > > > > Hope that helps.
> > > > > > > >
> > > > > > > > Regards Johannes
> > > > > > > > wishfully waiting for the cooling tempest.
> > > > > > > >
> > > > > > > > "MyFaces Discussion" < [hidden email] > schrieb am
> > 18.07.05
> > > > > > > 13:57:47:
> > > > > > > > > Hi,   i am trying to use <x:dataTable to diplay a resultset
> > [from
> > > > > > > postgresql]. I have wrapped the resultset into a JDBCrowset. I am
> > > > using
> > > > > > > jetty . Basically the data doesn't get displayed on the we
> > browser.
> > > > i get
> > > > > > > the  following error:
> > > > > > > > >   13:40:15.610 WARN!! [P1-19]
> > > > > > >
> > org.apache.myfaces.renderkit.html.HtmlRenderKitImpl .
> > > > > > > > > getRenderer(HtmlRenderKitImpl.java:67) >36> Unsupported
> > > > > > > component-family/rendere
> > > > > > > > > r-type: javax.faces.ViewRoot /org.apache.myfaces.Table
> > > > > > >  Could anybody give an example of how they have done this
> > > > > > > or kindy help me here
> > > > > > > > > --
> > > > > > > > > Kind Regards
> > > > > > > > > Shibi Thomas
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > >
> > ______________________________________________________________
> > > > > > > > Verschicken Sie romantische, coole und witzige Bilder per SMS!
> > > > > > > > Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > > Kind Regards
> > > > > > > Shibi Thomas
> > > > > > >
> > > > > > > Can a mother forget the baby at her breast and have no compassion
> > on
> > > > the
> > > > > > > child she has borne?
> > > > > > > Though she may forget, I will not forget you! See, I have engraved
> > you
> > > > on
> > > > > > > the palms of my hands; your walls are ever before me. [Isaiah
> > > > 49:15,16]
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > >
> > > > Kind Regards
> > > > Shibi Thomas
> > > >
> > > >  Can a mother forget the baby at her breast and have no compassion on
> > the
> > > > child she has borne?
> > > > Though she may forget, I will not forget you! See, I have engraved you
> > on
> > > > the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]
> > > >
> > > >
> > > >
> > >
> >
> >
> >
> > --
> >
> > Kind Regards
> > Shibi Thomas
> >
> > Can a mother forget the baby at her breast and have no compassion on the
> > child she has borne?
> > Though she may forget, I will not forget you! See, I have engraved you on
> > the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]
> >
> >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: how to display data in DataTable

Shibi Thomas
thanks guys that helped ...
BUT i need some insite to do this .....
 
Does anyone have an example where they convert a resultset [3 to 4 columns] to a list and diaplays it in a <x:datatable
 
Does JSF RI datatable support resultsets.
 
shibi
 
On 7/25/05, Bruno Aranda <[hidden email]> wrote:
> You have instances of java.lang.Long in your rows. Don´t use {row.id} but {row} since Long doesn´t have a getId() Method.

Yes, as Mathias points out, I guess you are obtaining Longs from your
ResultSet and you are creating a List with Longs. This may be the
problem...

Bruno

2005/7/25, Bruno Aranda <[hidden email]>:

> Ok, if you want to use the dataTable you have to provide a List of
> objects to it, as it seems you do. In your case you want #{row.id},
> which is the equivalent to invoke getId() to one of the objects of
> your List. This is why the objects obtained from the ResultSet must
> have the method getId(), because otherwise it would not work the EL
> #{row.id}...
>
> Moreover, it seems that a bundle is missing in your jar
> (net.sourceforge.myfaces.examples.resource.example_messages). You
> should verify that you have the example_messages.properties file
> inside your jar (or in the WEB-INF/classes folder) in
> net/sourceforge/myfaces/examples. I guess you have copied an old
> myfaces examples and you forgot to remove the bundle....
>
> I hope that everything is clearer now. If not, ask again ;-)
>
> Bruno
>
>
> 2005/7/25, Shibi Thomas <[hidden email]>:
> > could u please clarify  Q?
> > some more  more stack trace
> >
> >
> > 14:54:24.982 ERROR! [P1-19]
> > org.apache.myfaces.taglib.core.LoadBundleTag.doStartTag (LoadBundleTag.java:123)
> > >34> Resource bundle
> > 'net.sourceforge.myfaces.examples.resource.example_messages'
> > could not be found.
> > 14:54:24.992 ERROR! [P1-19]
> > org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:108)
> > >52> java.lang.Long
> > javax.faces.el.PropertyNotFoundException: Bean:
> > java.lang.Long, property: id
> >          at
> > org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor(PropertyResolverImpl.java:464)
> >         at
> > org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor (PropertyResolverImpl.java:435)
> >         at
> > org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:398)
> >         at
> > org.apache.myfaces.el.PropertyResolverImpl.getValue (PropertyResolverImpl.java:104)
> >         at
> > org.apache.myfaces.el.ELParserHelper$MyPropertySuffix.evaluate
> > (ELParserHelper.java:555)
> >         at
> > org.apache.commons.el.ComplexValue.evaluate (ComplexValue.java:145)
> >         at
> > org.apache.myfaces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:441)
> >         at javax.faces.component.UIOutput.getValue
> > (UIOutput.java :75)
> >         at
> > org.apache.myfaces.renderkit.RendererUtils.getStringValue(RendererUtils.java:296)
> >         at
> > org.apache.myfaces.renderkit.html.HtmlTextRendererBase.renderInput (HtmlTextRendererBase.java
> > :159)
> >         at
> > org.apache.myfaces.renderkit.html.HtmlTextRendererBase.encodeEnd(HtmlTextRendererBase.java:77)
> >         at
> > javax.faces.component.UIComponentBase.encodeEnd (UIComponentBase.java:341)
> >         at
> > org.apache.myfaces.renderkit.RendererUtils.renderChild
> > (RendererUtils.java:494)
> >         at
> > org.apache.myfaces.renderkit.RendererUtils.renderChildren (RendererUtils.java:471)
> >         at
> > org.apache.myfaces.renderkit.RendererUtils.renderChild(RendererUtils.java:492)
> >         at
> > org.apache.myfaces.renderkit.html.HtmlTableRendererBase.renderColumnBody (HtmlTableRendererBase.java:205)
> >         at
> > org.apache.myfaces.renderkit.html.HtmlTableRendererBase.encodeChildren(HtmlTableRendererBase.java:160)
> >         at
> > javax.faces.component.UIComponentBase.encodeChildren (UIComponentBase.java:329)
> >         at
> > org.apache.myfaces.component.html.ext.HtmlDataTable.encodeChildren(HtmlDataTable.java:507)
> >         at javax.faces.webapp.UIComponentTag.encodeChildren
> > (UIComponentTag.java:380)
> >         at
> > javax.faces.webapp.UIComponentTag.doEndTag(UIComponentTag.java:288)
> >         at
> > org.apache.myfaces.taglib.UIComponentBodyTagBase.doEndTag (UIComponentBodyTagBase.java:98)
> >         at
> > org.apache.jsp.showResult_jsp._jspx_meth_x_dataTable_0(showResult_jsp.java:185)
> >         at
> > org.apache.jsp.showResult_jsp._jspx_meth_f_view_0 (showResult_jsp.java:118)
> >         at org.apache.jsp.showResult_jsp._jspService
> > (showResult_jsp.java:84)
> >         at
> > org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java :94)
> >         at
> > javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
> >         at
> > org.apache.jasper.servlet.JspServletWrapper.service
> > (JspServletWrapper.java :324)
> >         at
> > org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
> >         at
> > org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
> >         at javax.servlet.http.HttpServlet.service

> > (HttpServlet.java:689)
> >         at
> > org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427)
> >         at
> > org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:475)
> >         at
> > org.mortbay.jetty.servlet.Dispatcher.dispatch(Dispatcher.java:275)
> >         at
> > org.mortbay.jetty.servlet.Dispatcher.forward(Dispatcher.java:169)
> >         at
> > org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch
> > (ServletExternalContextImpl.java :405)
> >         at
> > org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:280)
> >         at
> > org.apache.myfaces.lifecycle.LifecycleImpl.render (LifecycleImpl.java
> > :300)
> >         at
> > javax.faces.webapp.FacesServlet.service(FacesServlet.java:110)
> >         at
> > org.mortbay.jetty.servlet.ServletHolder.handle (ServletHolder.java:427)
> >         at
> > org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter
> > (WebApplicationHandler.java:832)
> >         at
> > org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter (ExtensionsFilter.java:112)
> >         at
> > org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter
> > (WebApplicationHandler.java:823)
> >         at
> > org.mortbay.jetty.servlet.WebApplicationHandler.dispatch (WebApplicationHandler.java:473)
> >         at
> > org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567)
> >         at
> > org.mortbay.http.HttpContext.handle(HttpContext.java :1565)
> >         at
> > org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:635)
> >         at org.mortbay.http.HttpContext.handle
> > (HttpContext.java :1517)
> >         at
> > org.mortbay.http.HttpServer.service(HttpServer.java:954)
> >         at
> > org.mortbay.http.HttpConnection.service(HttpConnection.java:814)
> >         at org.mortbay.http.HttpConnection.handleNext
> > (HttpConnection.java:981)
> >         at
> > org.mortbay.http.HttpConnection.handle(HttpConnection.java:831)
> >         at
> > org.mortbay.http.SocketListener.handleConnection (SocketListener.java:244)
> >         at org.mortbay.util.ThreadedServer.handle
> > (ThreadedServer.java:357)
> >         at
> > org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java :534)
> >
> >
> >
> > On 7/25/05, Bruno Aranda <[hidden email]> wrote:
> > > Are you sure that results.getObject(1)) returns an object which has an
> > > Id attribute accessible with yourObject.getId ()? Could you post some
> > > more of the stack trace?
> > >
> > > Regards,
> > >
> > > Bruno
> > >

> > > 2005/7/25, Shibi Thomas <[hidden email]>:
> > > > hello tried using a list .. I get an error
> > > >
> > > > 14:54: 25.062 WARN!! [P1-19]
> > > >
> > org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:588)
> > > > >11> /TranFind/startSearch.jsf:
> > > > javax.faces.FacesException : Expression: '#{ row.id }'
> > > >
> > > > here is the code snippet
> > > >
> > > >
> > > >
> > > > <x:dataTable  id = "data"
> > > >                 styleClass= "standardTable"
> > > >                 headerClass = "standardTable_Header"
> > > >
> > > > rowClasses="standardTable_Row1,standardTable_Row2"
> > > >
> > > >
> > columnClasses="standardTable_Column,standardTable_ColumnCentered,standardTable_Column"
> > > >                 value="#{ searchBean.list }"
> > > >                 var="row"
> > > >                 preserveDataModel ="true">
> > > >
> > > >            <h:column>
> > > >             <f:facet name= "Header">

> > > >              <h:outputText value="ID" />
> > > >             </f:facet>
> > > >             <h:outputText id = "Id" value ="#{ row.id}" />
> > > >            </h:column>
> > > > </x:dataTable>
> > > >
> > > > any clue guys. I have added the result as and object to the list.
> > > >
> > > > while( results.next())
> > > >         {
> > > >             rslist.add(results.getObject(1));
> > > >         }
> > > >
> > > > kind regards
> > > > shibi
> > > >
> > > > On 7/18/05, Bruno Aranda <[hidden email]> wrote:
> > > > > Shibi, in the meanwhile maybe you could put your results in a List...
> > > > >
> > > > > Regards,
> > > > >
> > > > > Bruno
> > > > >
> > > > > 2005/7/18, Bruno Aranda <[hidden email]>:
> > > > > > > I get an error that the resultsetDatamodel is not
> > implemented......i
> > > > hope this help....
> > > > > >
> > > > > > Actually, the javax.faces.model.ResultSetDataModel
> > is
> > > > not implemented.
> > > > > > Every method is throwing an UnsupportedOperationException. If
> > someone
> > > > > > wants to implement it, please do so. It should not be difficult,
> > > > > >
> > > > > > Regards,
> > > > > >
> > > > > > Bruno
> > > > > >
> > > > > > 2005/7/18, Shibi Thomas < [hidden email]>:
> > > > > > > I am using myfaces.
> > > > > > >
> > > > > > > The bean class [searchbean] looks like this :
> > > > > > >
> > > > > > >  public JdbcRowSet getdataresult()
> > > > > > >     {
> > > > > > >         if (dataresult != null)
> > > > > > >         return dataresult;
> > > > > > >         else
> > > > > > >             return null;
> > > > > > >     }
> > > > > > >
> > > > > > > public String doQuery()
> > > > > > >     {
> > > > > > >      .................
> > > > > > > .    .................
> > > > > > >      try {
> > > > > > >             dataresult  =Connect(sqlquery);
> > > > > > >         } catch (SQLException e) {
> > > > > > >             e.printStackTrace();  //To change body of catch
> > statement
> > > > use
> > > > > > > File | Settings | File Templates.
> > > > > > >             ctx.addMessage (null, new FacesMessage(e.toString()));
> > > > > > >             return "error";
> > > > > > >         } catch (ClassNotFoundException e) {
> > > > > > >             e.printStackTrace();  //To change body of catch
> > statement
> > > > use
> > > > > > > File | Settings | File Templates.
> > > > > > >             ctx.addMessage(null, new FacesMessage(e.toString()));
> > > > > > >             return "error";
> > > > > > >         }
> > > > > > >                     //--------finished
> > > > > > >       return "success";
> > > > > > >     }
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > public JdbcRowSet Connect (String query) throws SQLException,
> > > > > > > ClassNotFoundException {
> > > > > > >
> > > > > > >       Class.forName("org.postgresql.Driver");
> > > > > > >       JdbcRowSetImpl jrs = new JdbcRowSetImpl();
> > > > > > >       jrs.setCommand(sqlquery);
> > > > > > >       jrs.setUrl("jdbc: <a href="postgresql://bungo:5432/vods&quot;)">postgresql://bungo:5432/vods");
> > > > > > >       jrs.setUsername("vodsview");

> > > > > > >       jrs.setPassword("");
> > > > > > >         System.out.println ("inside this method connect");
> > > > > > >       jrs.execute ();
> > > > > > >       return jrs;
> > > > > > >     }
> > > > > > >
> > > > > > > the showresult.jsp looks like this
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > <?xml version="1.0"?>
> > > > > > > <jsp:root version="2.0" xmlns:jsp=" http://java.sun.com/JSP/Page"
> > > > > > >  xmlns:h=" http://java.sun.com/jsf/html "
> > > > > > >  xmlns:f="http://java.sun.com/jsf/core "
> > > > > > >     xmlns:x="
> > http://myfaces.apache.org/extensions">
> > > > > > >
> > > > > > >  <jsp:directive.page
> > > > contentType="text/html;charset=UTF-8"

> > > > > > >   isELIgnored="false" />
> > > > > > >  <jsp:output omit-xml-declaration="true"
> > doctype-root-element="html"
> > > > > > >
> > > > doctype-system=" http://www.w3.org/TR/html4/loose.dtd "
> > > > > > >   doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN" />
> > > > > > >
> > > > > > >  <html>
> > > > > > >   <head>
> > > > > > >    <title>VODS log search result</title>
> > > > > > >   </head>
> > > > > > >   <body>
> > > > > > >    This is the result page.
> > > > > > >       <f:view>
> > > > > > >         <h:dataTable  id = "data"
> > > > > > >                 rendered = "true"
> > > > > > >                 styleClass= "table-background"
> > > > > > >                 rowClasses= "table-odd-row,table-even-row"
> > > > > > >                 cellpadding="3"
> > > > > > >                 value="#{searchBean.dataresult }"
> > > > > > >                 var="row">
> > > > > > >
> > > > > > >            <h:column>
> > > > > > >             <f:facet name= "Header">
> > > > > > >             <h:outputText value ="Sender"/>
> > > > > > >             </f:facet>
> > > > > > >             <h:outputText value ="#{row.Sender}" />
> > > > > > >            </h:column>
> > > > > > >
> > > > > > >
> > > > > > >        </h:dataTable>
> > > > > > >       </f:view>
> > > > > > >       </body>
> > > > > > >   </html>
> > > > > > > </jsp:root>I get an error that the resultsetDatamodel is not
> > > > > > > implemented......i hope this help....
> > > > > > >
> > > > > > > Shibi

> > > > > > >
> > > > > > >
> > > > > > > On 7/18/05, Johannes Hiemer <[hidden email]> wrote:
> > > > > > > >
> > > > > > > > Hi Shibi,
> > > > > > > > here is an example on how it works for me:
> > > > > > > > <h:dataTable id="bean" rowClasses="row"
> > > > > > > >
> > > > value="#{searchSystemdataSpringBean.bean }"
> > > > > > > >                                var="systemdata"
> > > > styleClass="hidden">
> > > > > > > >                                <h:column>
> > > > > > > >                                        <f:facet
> > > > > > > name="header">
> > > > > > > >
> > > > > > > <h:outputText value="#{ bundle.searchSystemTagNumber}" />
> > > > > > > >
> > </f:facet>
> > > > > > > >
> > > > <h:commandButton
> > > > > > > styleClass="button" id="tagnumber" value="#{
> > systemdata.sdtagnumber}"
> > > > > > > onclick="javascript: passToParentWindow(id, value)" />
> > > > > > > >                                </h:column>
> > > > > > > >                                <h:column>
> > > > > > > >                                        <f:facet
> > > > > > > name="header">
> > > > > > > >
> > > > > > > <h:outputText  value="#{ bundle.searchSystemModel}" />
> > > > > > > >
> > </f:facet>
> > > > > > > >
> > > > <h:outputText
> > > > > > > id="model" value="#{systemdata.sdmodel}" />
> > > > > > > >                                </h:column>
> > > > > > > >                                <h:column>
> > > > > > > >                                        <f:facet
> > > > > > > name="header">
> > > > > > > >
> > > > > > > <h:outputText  value="#{ bundle.searchSystemSn}" />
> > > > > > > >
> > </f:facet>
> > > > > > > >
> > > > <h:outputText
> > > > > > > id="systemnumber" value="#{ systemdata.sdsn}" />
> > > > > > > >                                </h:column>
> > > > > > > >                                <h:column>
> > > > > > > >                                        <f:facet
> > > > > > > name="header">
> > > > > > > >
> > > > > > > <h:outputText value="#{ bundle.searchSystemType }" />
> > > > > > > >
> > </f:facet>
> > > > > > > >
> > > > <h:outputText
> > > > > > > id="systemtype" value="#{systemdata.sdtype }" />
> > > > > > > >                                </h:column>
> > > > > > > >                        </h:dataTable>
> > > > > > > > The important things are value="#{
> > searchSystemdataSpringBean.bean}"
> > > > > > > assigning the values from the backed bean, the next stept is
> > putting
> > > > these
> > > > > > > values into var="systemdata", and after that you can output them
> > > > normaly
> > > > > > > like this:
> > > > > > > > <h:outputText id="systemtype" value="#{systemdata.sdtype}" />
> > > > > > > >
> > > > > > > >        private List bean;
> > > > > > > >
> > > > > > > >        public void search(ActionEvent event) {
> > > > > > > >                HtmlDataTable dataTable = (HtmlDataTable)
> > > > > > > event.getComponent ()
> > > > > > > >
> > > > .findComponent("bean");
> > > > > > > >                if
> > (getSystemdata().getSdtagnumber()
> > > > ==
> > > > > > > null) {
> > > > > > > >                        bean =
> > > > > > > getSystemdataManager().getSystemdatas();
> > > > > > > >                }
> > > > > > > >        }
> > > > > > > > As you can see, bean is just a normal list.
> > > > > > > > That's the way it works for me, if you could provide a bit more
> > > > code, it
> > > > > > > would be easyer to figure out your problem.
> > > > > > > >
> > > > > > > > Hope that helps.
> > > > > > > >

> > > > > > > > Regards Johannes
> > > > > > > > wishfully waiting for the cooling tempest.
> > > > > > > >
> > > > > > > > "MyFaces Discussion" < [hidden email] > schrieb am
> > 18.07.05
> > > > > > > 13:57:47:
> > > > > > > > > Hi,   i am trying to use <x:dataTable to diplay a resultset
> > [from
> > > > > > > postgresql]. I have wrapped the resultset into a JDBCrowset. I am
> > > > using
> > > > > > > jetty . Basically the data doesn't get displayed on the we
> > browser.
> > > > i get
> > > > > > > the  following error:
> > > > > > > > >   13:40:15.610 WARN!! [P1-19]
> > > > > > >
> > org.apache.myfaces.renderkit.html.HtmlRenderKitImpl .
> > > > > > > > > getRenderer( HtmlRenderKitImpl.java:67) >36> Unsupported
> > > > > > > component-family/rendere
> > > > > > > > > r-type: javax.faces.ViewRoot /org.apache.myfaces.Table
> > > > > > >  Could anybody give an example of how they have done this
> > > > > > > or kindy help me here
> > > > > > > > > --
> > > > > > > > > Kind Regards
> > > > > > > > > Shibi Thomas
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > >
> > ______________________________________________________________
> > > > > > > > Verschicken Sie romantische, coole und witzige Bilder per SMS!
> > > > > > > > Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > > Kind Regards
> > > > > > > Shibi Thomas
> > > > > > >
> > > > > > > Can a mother forget the baby at her breast and have no compassion
> > on
> > > > the
> > > > > > > child she has borne?
> > > > > > > Though she may forget, I will not forget you! See, I have engraved
> > you
> > > > on
> > > > > > > the palms of my hands; your walls are ever before me. [Isaiah
> > > > 49:15,16]
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > >
> > > > Kind Regards

> > > > Shibi Thomas
> > > >
> > > >  Can a mother forget the baby at her breast and have no compassion on
> > the
> > > > child she has borne?
> > > > Though she may forget, I will not forget you! See, I have engraved you
> > on
> > > > the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]
> > > >
> > > >
> > > >
Reply | Threaded
Open this post in threaded view
|

Re: how to display data in DataTable

Bruno Aranda
Comments inline...

2005/8/2, Shibi Thomas <[hidden email]>:
> thanks guys that helped ...
> BUT i need some insite to do this .....
>  
> Does anyone have an example where they convert a resultset [3 to 4 columns]
> to a list and diaplays it in a <x:datatable

I always use hibernate now and it's a long time of the last resultset,
but what I would do in this case is create a new object with the
values from the ResultSet, insert the objects in a List and pass the
list to the dataTable. Something like this:

In the constructor, for instance, of your backing bean:

[CODE]

List<Person> people;  // using generics to improve readibility...
don't forget the accessor methods (get,set)

public YourBackingBean() {

people = new ArrayList<Person>();

ResultSet rs = // get the resultSet here in the way you need
   
        // Fetch each row from the result set
        while (rs.next()) {
            // Get the data from the row using the column index
            String firstName = rs.getString(1);
            String lastName = rs.getString(2);
            int age = rs.getInteger(3);
   
            // create an object for each row (yes, it is hibernate biased) ;-)
            Person p = new Person();
            p.setFirstName(firstName);
            p.setLastName(lastName);
            p.setAge(age);

            // Add the object to the list
            people.add(p);
        }
}

[/CODE]

Then, in your jsp page, invoke the people list from the bean...

<x:dataTable value="#{yourBackingBean.people} var="person" >
     <h:column>
          <h:outputText value="#{people.firstName}" />
     </h:column>
     <h:column>
          <h:outputText value="#{people.lastName}"/>
     </h:column>
</x:dataTable>

>  
> Does JSF RI datatable support resultsets.

AFAIK, yes, but I've never tried it....

>  
> shibi
>  

Hope this sheds some light...

Bruno

>  
> On 7/25/05, Bruno Aranda <[hidden email]> wrote:
> > > You have instances of java.lang.Long in your rows. Don´t use {row.id}
> but {row} since Long doesn´t have a getId() Method.
> >
> > Yes, as Mathias points out, I guess you are obtaining Longs from your
> > ResultSet and you are creating a List with Longs. This may be the
> > problem...
> >
> > Bruno
> >
> > 2005/7/25, Bruno Aranda < [hidden email]>:
> > > Ok, if you want to use the dataTable you have to provide a List of
> > > objects to it, as it seems you do. In your case you want #{row.id},
> > > which is the equivalent to invoke getId() to one of the objects of
> > > your List. This is why the objects obtained from the ResultSet must
> > > have the method getId(), because otherwise it would not work the EL
> > > #{row.id}...
> > >
> > > Moreover, it seems that a bundle is missing in your jar
> > >
> (net.sourceforge.myfaces.examples.resource.example_messages).
> You
> > > should verify that you have the example_messages.properties file
> > > inside your jar (or in the WEB-INF/classes folder) in
> > > net/sourceforge/myfaces/examples. I guess you have
> copied an old
> > > myfaces examples and you forgot to remove the bundle....
> > >
> > > I hope that everything is clearer now. If not, ask again ;-)
> > >
> > > Bruno
> > >
> > >
> > > 2005/7/25, Shibi Thomas < [hidden email]>:
> > > > could u please clarify  Q?
> > > > some more  more stack trace
> > > >
> > > >
> > > > 14:54:24.982 ERROR! [P1-19]
> > > >
> org.apache.myfaces.taglib.core.LoadBundleTag.doStartTag
> (LoadBundleTag.java:123)
> > > > >34> Resource bundle
> > > >
> 'net.sourceforge.myfaces.examples.resource.example_messages'
> > > > could not be found.
> > > > 14:54:24.992 ERROR! [P1-19]
> > > >
> org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:108)
> > > > >52> java.lang.Long
> > > > javax.faces.el.PropertyNotFoundException: Bean:
> > > > java.lang.Long, property: id
> > > >          at
> > > >
> org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor(PropertyResolverImpl.java:464)
> > > >         at
> > > >
> org.apache.myfaces.el.PropertyResolverImpl.getPropertyDescriptor
> (PropertyResolverImpl.java:435)
> > > >         at
> > > >
> org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:398)
> > > >         at
> > > > org.apache.myfaces.el.PropertyResolverImpl.getValue
> (PropertyResolverImpl.java:104)
> > > >         at
> > > >
> org.apache.myfaces.el.ELParserHelper$MyPropertySuffix.evaluate
> > > > (ELParserHelper.java:555)
> > > >         at
> > > > org.apache.commons.el.ComplexValue.evaluate
> (ComplexValue.java:145)
> > > >         at
> > > >
> org.apache.myfaces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:441)
> > > >         at javax.faces.component.UIOutput.getValue
> > > > (UIOutput.java :75)
> > > >         at
> > > >
> org.apache.myfaces.renderkit.RendererUtils.getStringValue(RendererUtils.java:296)
> > > >         at
> > > >
> org.apache.myfaces.renderkit.html.HtmlTextRendererBase.renderInput
> (HtmlTextRendererBase.java
> > > > :159)
> > > >         at
> > > >
> org.apache.myfaces.renderkit.html.HtmlTextRendererBase.encodeEnd(HtmlTextRendererBase.java:77)
> > > >         at
> > > > javax.faces.component.UIComponentBase.encodeEnd
> (UIComponentBase.java:341)
> > > >         at
> > > >
> org.apache.myfaces.renderkit.RendererUtils.renderChild
> > > > (RendererUtils.java:494)
> > > >         at
> > > >
> org.apache.myfaces.renderkit.RendererUtils.renderChildren
> (RendererUtils.java:471)
> > > >         at
> > > >
> org.apache.myfaces.renderkit.RendererUtils.renderChild(RendererUtils.java:492)
> > > >         at
> > > >
> org.apache.myfaces.renderkit.html.HtmlTableRendererBase.renderColumnBody
> (HtmlTableRendererBase.java:205)
> > > >         at
> > > >
> org.apache.myfaces.renderkit.html.HtmlTableRendererBase.encodeChildren(HtmlTableRendererBase.java:160)
> > > >         at
> > > > javax.faces.component.UIComponentBase.encodeChildren
> (UIComponentBase.java:329)
> > > >         at
> > > >
> org.apache.myfaces.component.html.ext.HtmlDataTable.encodeChildren(HtmlDataTable.java:507)
> > > >         at
> javax.faces.webapp.UIComponentTag.encodeChildren
> > > > (UIComponentTag.java:380)
> > > >         at
> > > >
> javax.faces.webapp.UIComponentTag.doEndTag(UIComponentTag.java:288)
> > > >         at
> > > >
> org.apache.myfaces.taglib.UIComponentBodyTagBase.doEndTag
> (UIComponentBodyTagBase.java:98)
> > > >         at
> > > >
> org.apache.jsp.showResult_jsp._jspx_meth_x_dataTable_0(showResult_jsp.java:185)
> > > >         at
> > > > org.apache.jsp.showResult_jsp._jspx_meth_f_view_0
> (showResult_jsp.java:118)
> > > >         at org.apache.jsp.showResult_jsp._jspService
> > > > (showResult_jsp.java:84)
> > > >         at
> > > >
> org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java
> :94)
> > > >         at
> > > >
> javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
> > > >         at
> > > > org.apache.jasper.servlet.JspServletWrapper.service
> > > > (JspServletWrapper.java :324)
> > > >         at
> > > >
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
> > > >         at
> > > >
> org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
> > > >         at javax.servlet.http.HttpServlet.service
> > > > (HttpServlet.java:689)
> > > >         at
> > > >
> org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:427)
> > > >         at
> > > >
> org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:475)
> > > >         at
> > > >
> org.mortbay.jetty.servlet.Dispatcher.dispatch(Dispatcher.java:275)
> > > >         at
> > > >
> org.mortbay.jetty.servlet.Dispatcher.forward(Dispatcher.java:169)
> > > >         at
> > > >
> org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch
> > > > (ServletExternalContextImpl.java :405)
> > > >         at
> > > >
> org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHandlerImpl.java:280)
> > > >         at
> > > > org.apache.myfaces.lifecycle.LifecycleImpl.render
> (LifecycleImpl.java
> > > > :300)
> > > >         at
> > > >
> javax.faces.webapp.FacesServlet.service(FacesServlet.java:110)
> > > >         at
> > > > org.mortbay.jetty.servlet.ServletHolder.handle
> (ServletHolder.java:427)
> > > >         at
> > > >
> org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter
> > > > (WebApplicationHandler.java:832)
> > > >         at
> > > >
> org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter
> (ExtensionsFilter.java:112)
> > > >         at
> > > >
> org.mortbay.jetty.servlet.WebApplicationHandler$CachedChain.doFilter
> > > > (WebApplicationHandler.java:823)
> > > >         at
> > > >
> org.mortbay.jetty.servlet.WebApplicationHandler.dispatch
> (WebApplicationHandler.java:473)
> > > >         at
> > > >
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:567)
> > > >         at
> > > > org.mortbay.http.HttpContext.handle(HttpContext.java
> :1565)
> > > >         at
> > > >
> org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:635)
> > > >         at org.mortbay.http.HttpContext.handle
> > > > (HttpContext.java :1517)
> > > >         at
> > > >
> org.mortbay.http.HttpServer.service(HttpServer.java:954)
> > > >         at
> > > >
> org.mortbay.http.HttpConnection.service(HttpConnection.java:814)
> > > >         at org.mortbay.http.HttpConnection.handleNext
> > > > (HttpConnection.java:981)
> > > >         at
> > > >
> org.mortbay.http.HttpConnection.handle(HttpConnection.java:831)
> > > >         at
> > > > org.mortbay.http.SocketListener.handleConnection
> (SocketListener.java:244)
> > > >         at org.mortbay.util.ThreadedServer.handle
> > > > (ThreadedServer.java:357)
> > > >         at
> > > >
> org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java
> :534)
> > > >
> > > >
> > > >
> > > > On 7/25/05, Bruno Aranda <[hidden email]> wrote:
> > > > > Are you sure that results.getObject(1)) returns an object which has
> an
> > > > > Id attribute accessible with yourObject.getId ()? Could you post
> some
> > > > > more of the stack trace?
> > > > >
> > > > > Regards,
> > > > >
> > > > > Bruno
> > > > >
> > > > > 2005/7/25, Shibi Thomas <[hidden email]>:
> > > > > > hello tried using a list .. I get an error
> > > > > >
> > > > > > 14:54: 25.062 WARN!! [P1-19]
> > > > > >
> > > >
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:588)
> > > > > > >11> /TranFind/startSearch.jsf:
> > > > > > javax.faces.FacesException : Expression: '#{ row.id }'
> > > > > >
> > > > > > here is the code snippet
> > > > > >
> > > > > >
> > > > > >
> > > > > > <x:dataTable  id = "data"
> > > > > >                 styleClass= "standardTable"
> > > > > >                 headerClass = "standardTable_Header"
> > > > > >
> > > > > >
> rowClasses="standardTable_Row1,standardTable_Row2"
> > > > > >
> > > > > >
> > > >
> columnClasses="standardTable_Column,standardTable_ColumnCentered,standardTable_Column"
> > > > > >                 value="#{ searchBean.list }"
> > > > > >                 var="row"
> > > > > >                 preserveDataModel ="true">
> > > > > >
> > > > > >            <h:column>
> > > > > >             <f:facet name= "Header">
> > > > > >              <h:outputText value="ID" />
> > > > > >             </f:facet>
> > > > > >             <h:outputText id = "Id" value ="#{ row.id}" />
> > > > > >            </h:column>
> > > > > > </x:dataTable>
> > > > > >
> > > > > > any clue guys. I have added the result as and object to the list.
> > > > > >
> > > > > > while( results.next())
> > > > > >         {
> > > > > >             rslist.add(results.getObject(1));
> > > > > >         }
> > > > > >
> > > > > > kind regards
> > > > > > shibi
> > > > > >
> > > > > > On 7/18/05, Bruno Aranda <[hidden email]> wrote:
> > > > > > > Shibi, in the meanwhile maybe you could put your results in a
> List...
> > > > > > >
> > > > > > > Regards,
> > > > > > >
> > > > > > > Bruno
> > > > > > >
> > > > > > > 2005/7/18, Bruno Aranda < [hidden email]>:
> > > > > > > > > I get an error that the resultsetDatamodel is not
> > > > implemented......i
> > > > > > hope this help....
> > > > > > > >
> > > > > > > > Actually, the
> javax.faces.model.ResultSetDataModel
> > > > is
> > > > > > not implemented.
> > > > > > > > Every method is throwing an UnsupportedOperationException. If
> > > > someone
> > > > > > > > wants to implement it, please do so. It should not be
> difficult,
> > > > > > > >
> > > > > > > > Regards,
> > > > > > > >
> > > > > > > > Bruno
> > > > > > > >
> > > > > > > > 2005/7/18, Shibi Thomas < [hidden email]>:
> > > > > > > > > I am using myfaces.
> > > > > > > > >
> > > > > > > > > The bean class [searchbean] looks like this :
> > > > > > > > >
> > > > > > > > >  public JdbcRowSet getdataresult()
> > > > > > > > >     {
> > > > > > > > >         if (dataresult != null)
> > > > > > > > >         return dataresult;
> > > > > > > > >         else
> > > > > > > > >             return null;
> > > > > > > > >     }
> > > > > > > > >
> > > > > > > > > public String doQuery()
> > > > > > > > >     {
> > > > > > > > >      .................
> > > > > > > > > .    .................
> > > > > > > > >      try {
> > > > > > > > >             dataresult  =Connect(sqlquery);
> > > > > > > > >         } catch (SQLException e) {
> > > > > > > > >             e.printStackTrace();  //To change body of catch
> > > > statement
> > > > > > use
> > > > > > > > > File | Settings | File Templates.
> > > > > > > > >             ctx.addMessage (null, new
> FacesMessage(e.toString()));
> > > > > > > > >             return "error";
> > > > > > > > >         } catch (ClassNotFoundException e) {
> > > > > > > > >             e.printStackTrace();  //To change body of catch
> > > > statement
> > > > > > use
> > > > > > > > > File | Settings | File Templates.
> > > > > > > > >             ctx.addMessage(null, new
> FacesMessage(e.toString()));
> > > > > > > > >             return "error";
> > > > > > > > >         }
> > > > > > > > >                     //--------finished
> > > > > > > > >       return "success";
> > > > > > > > >     }
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > public JdbcRowSet Connect (String query) throws
> SQLException,
> > > > > > > > > ClassNotFoundException {
> > > > > > > > >
> > > > > > > > >       Class.forName("org.postgresql.Driver");
> > > > > > > > >       JdbcRowSetImpl jrs = new JdbcRowSetImpl();
> > > > > > > > >       jrs.setCommand(sqlquery);
> > > > > > > > >       jrs.setUrl("jdbc: postgresql://bungo:5432/vods");
> > > > > > > > >       jrs.setUsername("vodsview");
> > > > > > > > >       jrs.setPassword("");
> > > > > > > > >         System.out.println ("inside this method connect");
> > > > > > > > >       jrs.execute ();
> > > > > > > > >       return jrs;
> > > > > > > > >     }
> > > > > > > > >
> > > > > > > > > the showresult.jsp looks like this
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > <?xml version="1.0"?>
> > > > > > > > > <jsp:root version="2.0" xmlns:jsp="
> http://java.sun.com/JSP/Page"
> > > > > > > > >  xmlns:h=" http://java.sun.com/jsf/html "
> > > > > > > > >  xmlns:f="http://java.sun.com/jsf/core "
> > > > > > > > >     xmlns:x="
> > > > http://myfaces.apache.org/extensions">
> > > > > > > > >
> > > > > > > > >  <jsp:directive.page
> > > > > > contentType="text/html;charset=UTF-8"
> > > > > > > > >   isELIgnored="false" />
> > > > > > > > >  <jsp:output omit-xml-declaration="true"
> > > > doctype-root-element="html"
> > > > > > > > >
> > > > > > doctype-system="
> http://www.w3.org/TR/html4/loose.dtd "
> > > > > > > > >   doctype-public="-//W3C//DTD HTML 4.01 Transitional//EN" />
> > > > > > > > >
> > > > > > > > >  <html>
> > > > > > > > >   <head>
> > > > > > > > >    <title>VODS log search result</title>
> > > > > > > > >   </head>
> > > > > > > > >   <body>
> > > > > > > > >    This is the result page.
> > > > > > > > >       <f:view>
> > > > > > > > >         <h:dataTable  id = "data"
> > > > > > > > >                 rendered = "true"
> > > > > > > > >                 styleClass= "table-background"
> > > > > > > > >                 rowClasses= "table-odd-row,table-even-row"
> > > > > > > > >                 cellpadding="3"
> > > > > > > > >                 value="#{searchBean.dataresult }"
> > > > > > > > >                 var="row">
> > > > > > > > >
> > > > > > > > >            <h:column>
> > > > > > > > >             <f:facet name= "Header">
> > > > > > > > >             <h:outputText value ="Sender"/>
> > > > > > > > >             </f:facet>
> > > > > > > > >             <h:outputText value ="#{row.Sender}" />
> > > > > > > > >            </h:column>
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >        </h:dataTable>
> > > > > > > > >       </f:view>
> > > > > > > > >       </body>
> > > > > > > > >   </html>
> > > > > > > > > </jsp:root>I get an error that the resultsetDatamodel is not
> > > > > > > > > implemented......i hope this help....
> > > > > > > > >
> > > > > > > > > Shibi
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > On 7/18/05, Johannes Hiemer <[hidden email] > wrote:
> > > > > > > > > >
> > > > > > > > > > Hi Shibi,
> > > > > > > > > > here is an example on how it works for me:
> > > > > > > > > > <h:dataTable id="bean" rowClasses="row"
> > > > > > > > > >
> > > > > > value="#{searchSystemdataSpringBean.bean }"
> > > > > > > > > >                              
> var="systemdata"
> > > > > > styleClass="hidden">
> > > > > > > > > >                                <h:column>
> > > > > > > > > >                                      
> <f:facet
> > > > > > > > > name="header">
> > > > > > > > > >
> > > > > > > > > <h:outputText value="#{ bundle.searchSystemTagNumber}" />
> > > > > > > > > >
> > > > </f:facet>
> > > > > > > > > >
> > > > > > <h:commandButton
> > > > > > > > > styleClass="button" id="tagnumber" value="#{
> > > > systemdata.sdtagnumber}"
> > > > > > > > > onclick="javascript: passToParentWindow(id, value)" />
> > > > > > > > > >                              
> </h:column>
> > > > > > > > > >                                <h:column>
> > > > > > > > > >                                      
> <f:facet
> > > > > > > > > name="header">
> > > > > > > > > >
> > > > > > > > > <h:outputText  value="#{ bundle.searchSystemModel}" />
> > > > > > > > > >
> > > > </f:facet>
> > > > > > > > > >
> > > > > > <h:outputText
> > > > > > > > > id="model" value="#{systemdata.sdmodel}" />
> > > > > > > > > >                              
> </h:column>
> > > > > > > > > >                                <h:column>
> > > > > > > > > >                                      
> <f:facet
> > > > > > > > > name="header">
> > > > > > > > > >
> > > > > > > > > <h:outputText  value="#{ bundle.searchSystemSn}" />
> > > > > > > > > >
> > > > </f:facet>
> > > > > > > > > >
> > > > > > <h:outputText
> > > > > > > > > id="systemnumber" value="#{ systemdata.sdsn}" />
> > > > > > > > > >                              
> </h:column>
> > > > > > > > > >                                <h:column>
> > > > > > > > > >                                      
> <f:facet
> > > > > > > > > name="header">
> > > > > > > > > >
> > > > > > > > > <h:outputText value="#{ bundle.searchSystemType }" />
> > > > > > > > > >
> > > > </f:facet>
> > > > > > > > > >
> > > > > > <h:outputText
> > > > > > > > > id="systemtype" value="#{systemdata.sdtype }" />
> > > > > > > > > >                              
> </h:column>
> > > > > > > > > >                        </h:dataTable>
> > > > > > > > > > The important things are value="#{
> > > > searchSystemdataSpringBean.bean}"
> > > > > > > > > assigning the values from the backed bean, the next stept is
> > > > putting
> > > > > > these
> > > > > > > > > values into var="systemdata", and after that you can output
> them
> > > > > > normaly
> > > > > > > > > like this:
> > > > > > > > > > <h:outputText id="systemtype" value="#{systemdata.sdtype}"
> />
> > > > > > > > > >
> > > > > > > > > >        private List bean;
> > > > > > > > > >
> > > > > > > > > >        public void search(ActionEvent event) {
> > > > > > > > > >                HtmlDataTable dataTable = (HtmlDataTable)
> > > > > > > > > event.getComponent ()
> > > > > > > > > >
> > > > > > .findComponent("bean");
> > > > > > > > > >                if
> > > > (getSystemdata().getSdtagnumber()
> > > > > > ==
> > > > > > > > > null) {
> > > > > > > > > >                        bean =
> > > > > > > > > getSystemdataManager().getSystemdatas();
> > > > > > > > > >                }
> > > > > > > > > >        }
> > > > > > > > > > As you can see, bean is just a normal list.
> > > > > > > > > > That's the way it works for me, if you could provide a bit
> more
> > > > > > code, it
> > > > > > > > > would be easyer to figure out your problem.
> > > > > > > > > >
> > > > > > > > > > Hope that helps.
> > > > > > > > > >
> > > > > > > > > > Regards Johannes
> > > > > > > > > > wishfully waiting for the cooling tempest.
> > > > > > > > > >
> > > > > > > > > > "MyFaces Discussion" < [hidden email] > schrieb
> am
> > > > 18.07.05
> > > > > > > > > 13:57:47:
> > > > > > > > > > > Hi,   i am trying to use <x:dataTable to diplay a
> resultset
> > > > [from
> > > > > > > > > postgresql]. I have wrapped the resultset into a JDBCrowset.
> I am
> > > > > > using
> > > > > > > > > jetty . Basically the data doesn't get displayed on the we
> > > > browser.
> > > > > > i get
> > > > > > > > > the  following error:
> > > > > > > > > > >   13:40:15.610 WARN!! [P1-19]
> > > > > > > > >
> > > > org.apache.myfaces.renderkit.html.HtmlRenderKitImpl .
> > > > > > > > > > > getRenderer( HtmlRenderKitImpl.java:67) >36> Unsupported
> > > > > > > > > component-family/rendere
> > > > > > > > > > > r-type: javax.faces.ViewRoot /org.apache.myfaces.Table
> > > > > > > > >  Could anybody give an example of how they have done this
> > > > > > > > > or kindy help me here
> > > > > > > > > > > --
> > > > > > > > > > > Kind Regards
> > > > > > > > > > > Shibi Thomas
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > >
> > > > > >
> > > >
> ______________________________________________________________
> > > > > > > > > > Verschicken Sie romantische, coole und witzige Bilder per
> SMS!
> > > > > > > > > > Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > --
> > > > > > > > > Kind Regards
> > > > > > > > > Shibi Thomas
> > > > > > > > >
> > > > > > > > > Can a mother forget the baby at her breast and have no
> compassion
> > > > on
> > > > > > the
> > > > > > > > > child she has borne?
> > > > > > > > > Though she may forget, I will not forget you! See, I have
> engraved
> > > > you
> > > > > > on
> > > > > > > > > the palms of my hands; your walls are ever before me.
> [Isaiah
> > > > > > 49:15,16]
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > >
> > > > > > Kind Regards
> > > > > > Shibi Thomas
> > > > > >
> > > > > >  Can a mother forget the baby at her breast and have no compassion
> on
> > > > the
> > > > > > child she has borne?
> > > > > > Though she may forget, I will not forget you! See, I have engraved
> you
> > > > on
> > > > > > the palms of my hands; your walls are ever before me. [Isaiah
> 49:15,16]
> > > > > >
> > > > > >
> > > > > >
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > >
> > > > Kind Regards
> > > > Shibi Thomas
> > > >
> > > > Can a mother forget the baby at her breast and have no compassion on
> the
> > > > child she has borne?
> > > > Though she may forget, I will not forget you! See, I have engraved you
> on
> > > > the palms of my hands; your walls are ever before me. [Isaiah
> 49:15,16]
> > > >
> > > >
> > > >
> > >
> >
>
>
>
> --
>
> Kind Regards
> Shibi Thomas
>
> Can a mother forget the baby at her breast and have no compassion on the
> child she has borne?
> Though she may forget, I will not forget you! See, I have engraved you on
> the palms of my hands; your walls are ever before me. [Isaiah 49:15,16]
>
>
>