Question

I have a requirement, in which the code is using a SQL as

Select <COLUMN_LIST>, ROWNUM from <TABLE_LIST_AND_WHERE_CLAUSE>;

Now i need to remove this ROWNUM from the Select list but still keep the functionality of the attribute.

I have tried forums but with no fruit.

Please suggest is i can use an EL or an attribute to do the same.

Thanks in advance

Was it helpful?

Solution

Will adding #{vs.index + 1} for getting row number in your table solve your problem . vs would be your varStatus attribute value in <af:table> ?

OTHER TIPS

You can't get the value of a column from nowhere. If you remove the ROWNUM from the select query you can not get its values anymore. If you just want to have an attribute called ROWNUM as transient, you can give a certain value to it from EL but however not the original column name, unless you get that value from a SELECT in another place and put it there. But why do you want to have it removed at all? If you don't want to get it displayed anywhere you can change its Display property to FALSE and you should be fine.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top