Skip to main content

Displaying ClobDomain on a page

There is a default JSF converter(oracle.genericDomain) available for most of the oracle.jbo.domain types( not a new stuff, this has been available since 11.1.1.1.0). The converter-class for 'oracle.genericDomain' is oracle.adfinternal.view.faces.convert.GenericDomainConverter. This precofigured converter comes along with ADF binaries, so you just need to use it wherever required :)

Example :
 <af:inputText value="#{bindings.ClobContent.inputValue}"  
       label="#{bindings.ClobContent.hints.label}"  
       converter="oracle.genericDomain"  
       required="#{bindings.ClobContent.hints.mandatory}"  
       columns="#{bindings.ClobContent.hints.displayWidth}"  
       maximumLength="#{bindings.ClobContent.hints.precision}"  
       shortDesc="#{bindings.ClobContent.hints.tooltip}"  
       id="it2" rows="5">  
   <f:validator binding="#{bindings.ClobContent.validator}"/>  
 </af:inputText>  

Comments

Gowtham said…
Hi Jobinesh,
I have a database table whose column is Clob. Accordingly the Entity Attribute and VO attribute are of type. oracle.jbo.domain.ClobDomain

Now this VO is wired as a ADF Table in jsff page. I am setting the value programmatically inside the AM by using the following.

//Code inside AM
String text="some xml";
ClobDomain clobval=new ClobDomain(text.toString())
vo.setAttribute("atrName",clobVal);
Now at the UI level, I was able to print the value of the attribute inside a bean code. However, in the adf table, this cell is always empty. But if i try to set the value through UI then it works.
If i make the inputText readonly then it displays the value.
Am i missing something.

Inside the af:column


</af:inputText

Thanks
Gowtham
Gowtham said…
this is the ui code(without the tags)


af:inputText value="#{row.bindings.VariableValue.inputValue}"
label="#{bindings.TestcaseInput.hints.VariableValue.label}"
required="#{bindings.TestcaseInput.hints.VariableValue.mandatory}"
columns="#{bindings.TestcaseInput.hints.VariableValue.displayWidth}"
shortDesc="#{bindings.TestcaseInput.hints.VariableValue.tooltip}"
id="it4" converter="oracle.genericDomain"
rows="10">
validator binding="#{row.bindings.VariableValue.validator}"/>
af:inputText
VARJAIN said…
This comment has been removed by the author.
VARJAIN said…
This comment has been removed by the author.

Popular posts from this blog

Happy New Year 2018 !

We can't go back and change the beginning, but we always can start where we are and change the ending. Believe in yourself and you will be unstoppable!

Wishing you and your family a very happy new year 2018 !!!

How to set Bind Variable Values at runtime ?

In this post I'm sharing a couple of approaches for programmatically setting bind variables values at run time. This post is an attempt to explain 'When to use what ?'[ In case if you are familiar with 'Bind Variables' in ADF BC, please refer Section 5.10, Working with Bind Variables in Fusion Developer's Guide ]

1. Set the Bind Variable value using RowSet::setNamedWhereClauseParam(...)

You can use use the setNamedWhereClauseParam(...) method on the ViewObject interface (which extends oracle.jbo.RowSet) to set the value for bind variables. Please note this sets the value on default RowSet. In other words, this doesn't have any effect on the secondary RowSets that you/system generates.
ViewObject vo = am.findViewObject("EmployeesView1"); vo.setNamedWhereClauseParam("bindVarDeptId", new Number(10)); vo.executeQuery();
2. Set the Bind Variable value using ViewObject's VariableValueManager::setVariableValue(...)

VariableValueManager Ma…