Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

check if value is null before printing in jsf

843844Apr 23 2008 — edited Apr 29 2008
I have a details.jsp where I need to check whether a particular field is null before I print it on the jsp.

whats the way for checking if the value for detials.customerNumber is null or not. Only if the value is not null I have to print the value inside the <tr:outputText value="#{details.customerNumber}"/>
<f:view>
  <h:form>
    <tr:panelHeader text="Search Details"/>
    <tr:outputText value="Number: "/>
  <tr:outputText value="#{details.customerNumber}"/>
</h:form>
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 27 2008
Added on Apr 23 2008
4 comments
1,080 views