wood burning stoves 2.0*
The moose likes JSF and the fly likes Displaying a column name in <rich:dataTable> Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Displaying a column name in <rich:dataTable>" Watch "Displaying a column name in <rich:dataTable>" New topic
Author

Displaying a column name in <rich:dataTable>

udaya krishna
Ranch Hand

Joined: Mar 19, 2009
Posts: 33

Hi I have just started to learn JSF along with JPA.And i was wondering if we can display all the column names (not row or data present in the row) of a database as columns in <rich:dataTable>.My idea is that whenever a new column whenever a new column is added to a database a new column must be dynamically added into the JSF page.Any inputs are welcome.

Thanks
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 15629
    
  15

You can us the rich:columns tag to support a varying number of columns in a rich:dataTable. However, the caption on the column will have to come from your model, since neither RichFaces nor core JSF have any direct connections to data persistency systems.


Customer surveys are for companies who didn't pay proper attention to begin with.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Displaying a column name in <rich:dataTable>
 
Similar Threads
Regarding Jtable row Deletion
JSF (Richfaces) DataTable Column Layout
display multiple rich:dataTables
Problem with datatable update
row selected index id (rich data table)