Binding a Referenceable object vs Binding a reference

What is the difference between binding a Referenceable object and binding a Reference directly.

Hi gurpreetbhalla,
You'll find an answer on this [*page*|http://java.sun.com/products/jndi/tutorial/objects/storing/reference.html] .

Similar Messages

  • MXML binding creating activation-object which seems to be memory leak

    We are profiling our application trying to cut down some memory leaks and I have some loitering objects that are puzzling me.  I have searched on the internet and have seen others with similar issues, but thought I'd post here to see if I am on the right track and if anything can be done about it.  In our _bindingsSetup method that is generated from the MXML:
        private function _ManageFavoritesDialogBulb_bindingsSetup():Array
            var result:Array = [];
            var binding:Binding;
            binding = new mx.binding.Binding(this,
                function():Class
                    return (ManageFavoritesDialogView);
                function(_sourceFunctionReturnValue:Class):void
                    _ManageFavoritesDialogBulb_View1.className = _sourceFunctionReturnValue;
                "_ManageFavoritesDialogBulb_View1.className");
            result[0] = binding;
            // ... more bindings
    While profiling the app, we have a more than a handful of GC roots that say result and binding are activation objects that are causing a whole bunch of stuff to be held onto.  Is this accurate?  If so, is there anything we can do about it other than not using MXML?
    Irv

    Thanks for the quick replies.  I went to your blog and watched the presentation you had on profiling (very nice), but my application is still having a memory leak I am having trouble locating.  We have found many and have cleaned them up, but this scenario is proving pesky.  I have a very simple scenario I am working with now.  I use a PopupManager and put a component in it.  I then tell the popupManager to removePopup.  For some reason, my component is being held onto (and all the references it is holding onto).  I am using Flex 3.5 but using FlashBuilder to profile.  It tells me on my component there are 0 paths to the GC root, and I have clicked on most of the items found in loitering (this is a create and destroy scenario) and they all say 0 paths.  Do you know of any known issues with PopupManager that I should be looking for?  The only thing showing a path to GC root are some of the bindings and activation objects.  (I am hoping it is not them as you pointed out)  I assume when it says 0 paths to GC root it means there are only circular references keeping it around correct?
    Thanks for any advice.
    Irv

  • Runtime binding of JMS object(Queue, COnnection Factory)

    I want to knwo whether runtime binding the JMS Objects(Connection Factory & Destinations)
    is possible in WebLogic server?
    According to Weblogic it only binds JMS Object at the startup of the server using
    a Startup class?
    Thanks a million

    Destinations can be created dynamically.
    check:
    http://edocs.bea.com/wls/docs61/jms/implement.html#1189112
    viswa
    "Rakesh Jaiswal" <[email protected]> wrote:
    >
    I want to knwo whether runtime binding the JMS Objects(Connection Factory
    & Destinations)
    is possible in WebLogic server?
    According to Weblogic it only binds JMS Object at the startup of the server
    using
    a Startup class?
    Thanks a million

  • Bind a huge object to jndi tree in sun one 7

    Hi we are loading all the master tables in to objects at the app server startup (SUN ONE 7) and then binding the whole object to the jndi tree. All the tables data in text files comes to about 5 MB and the serilized object with data to about 8 MB. But when the app server tries to bind the object the app server process consumes over 500MB of ram and gives OutOfmemoryError as the total ram is 512MB. why is it consuming so much memory. It does bind an object of about 5 MB but when trying to lookup subsequent to the first lookup it fails. Is this a bug or what??? the same thing works perfectly with Weblogic and Websphere and also Weblogic is very efficient in memory consumption and response time is amazing. For a 5 MB object the lookup takes about 5Secs in Weblogic and about 15Mins in Sun One. We might have to drop the Sun One App Srv and go for Weblogic though we dont want. Kindly provide some guidance. Thanks in advance.

    Hi,
    Refer http://java.sun.com/products/jndi/tutorial/objects/storing/remote.html
    -amol

  • Object-XML Binding: How do I map from java to enumerated xml tags

    Hi. I'm new to Object-XML binding and toplink. XML that I'm trying to model in a schema has enumerated elements, e.g. </module_0></module_1><module_n> instead of many </module> elements. To simplify the schema I've opted to use </module> anyway with unbounded cardinality and imported this into a new project.
    What I would like to know is if I can use Toplink to map the java object back to the enumerate element types and vice versa?
    Thanks for your help.
    GeePee

    Hi Geepee,
    Below is an approach you can use if you have a fixed number of moduleX elements. In the example below X=3.
    Assume a 2 object model Root & Module, where Root has a list of Module instances:
    @XmlRootElement(name="root")
    public class Root {
        private List<Module> module = new ArrayList<Module>(3);
        ...// Accessors omitted
    }It is currently not possible to map the items in the module list to the XML elements (module1-module3), but it would be possbile to map an object (see below) with 3 properties to those XML elements:
    public class AdaptedModuleList {
        private Module module1;
        private Module module2;
        private Module module3;
        ...// Accessors omitted
    }What is required is a means to convert the unmappable object to a mappable one. This is done using a Converter:
    import org.eclipse.persistence.mappings.DatabaseMapping;
    import org.eclipse.persistence.mappings.converters.Converter;
    import org.eclipse.persistence.sessions.Session;
    public class ModuleListConverter implements Converter {
        public void initialize(DatabaseMapping mapping, Session session) {}
        public Object convertDataValueToObjectValue(Object dataValue, Session session) {
            AdaptedModuleList adaptedModuleList = (AdaptedModuleList) dataValue;
            if(null == adaptedModuleList) {
                return null;
            List<Module> moduleList = new ArrayList<Module>(3);
            moduleList.add(adaptedModuleList.getModule1());
            moduleList.add(adaptedModuleList.getModule2());
            moduleList.add(adaptedModuleList.getModule3());
            return moduleList;
        public Object convertObjectValueToDataValue(Object objectValue, Session session) {
            List<Module> moduleList = (List<Module>) objectValue;
            if(null == moduleList) {
                return null;
            AdaptedModuleList adaptedModuleList = new AdaptedModuleList();
            int moduleListSize = moduleList.size();
            if(moduleListSize > 0) {
                adaptedModuleList.setModule1(moduleList.get(0));
            if(moduleListSize > 1) {
                adaptedModuleList.setModule2(moduleList.get(1));
            if(moduleListSize > 2) {
                adaptedModuleList.setModule3(moduleList.get(2));
            return adaptedModuleList;
        public boolean isMutable() {
            return true;
    }The converter is added to the mapping metadata through the use of a Customizer:
    import org.eclipse.persistence.config.DescriptorCustomizer;
    import org.eclipse.persistence.descriptors.ClassDescriptor;
    import org.eclipse.persistence.oxm.mappings.XMLCompositeCollectionMapping;
    import org.eclipse.persistence.oxm.mappings.XMLCompositeObjectMapping;
    public class RootCustomizer implements DescriptorCustomizer {
        public void customize(ClassDescriptor descriptor) throws Exception {
            XMLCompositeCollectionMapping originalModuleMapping = (XMLCompositeCollectionMapping) descriptor.removeMappingForAttributeName("module");
            XMLCompositeObjectMapping newModuleMapping = new XMLCompositeObjectMapping();
            newModuleMapping.setAttributeName(originalModuleMapping.getAttributeName());
            newModuleMapping.setXPath(".");
            newModuleMapping.setReferenceClass(AdaptedModuleList.class);
            newModuleMapping.setConverter(new ModuleListConverter());
            descriptor.addMapping(newModuleMapping);
    }Part 1/2

  • JNDI bind/rebind and object state question

    Hi,
    I have an object that is part of an EAR application that is deployed into an app server. I load a Webapp that initializes an object and then binds it to an initial context under java:comp/env setting some initial state.
    However, when I access the object from an MDB as part of the EAR application, the state, when retrieved from the same context, was not retained. Here is the code I am using to bind the object to the context:
    if (!object.isRunning()) {
           System.out.println("Starting App...");
           object.start();
           try {
               getNamingContext().bind(object);
           } catch (Exception e) {
               System.out.println("Name bound already, rebinding...");
               try {
                   getNamingContext().rebind(object);
                   e.printStackTrace();
               } catch (Exception e1) {
                   e1.printStackTrace();
           System.out.println("Broker started...");
       }When I retrieve the object from the initial context as part of a message received within an MDB, the state is such that the object is always failing the .isRunning method test and subsequently throws an exception.
    What am I doing wrong? Is this related to the fact that possibly the WAR and the MDB create duplicate contexts when I expect there to be only one?
    Any insight is greatly appreciated.
    Thanks,
    John

    following procedure works fine for now, if there is any straight forward solutions,
    that will be helpful.
    1) Create the Subcontexts for each of the sub entries in the jndi name tree
    2) bind the object to the last entry in the tree.
    i.e if the jndi tree name is "one.two.three", and the bind object is Obj
    ctx = ctx.createSubcontext("one");
    ctx = ctx.createSubcontext("two");
    ctx = ctx.bind("three", obj);
    Thanks,
    Gangs.
    "Gangadhar" <[email protected]> wrote:
    >
    Hi,
    I am trying to bind the local object to the Weblogic JNDI, using the
    code below.
    It works fine if the bind name is a straight forward String(not a tree).
    It is
    throwing naming Exception when i am trying to bind into a new tree.
    Thanks,
    Gangs.
    //GETTING THE INITIAL CONTEXT:
    private Context getInitialContext() throws NamingException {
    Properties h = new Properties();
    h.put(Context.INITIAL_CONTEXT_FACTORY,
    "weblogic.jndi.WLInitialContextFactory");
    h.put(Context.SECURITY_PRINCIPAL, "user");
    h.put(Context.SECURITY_CREDENTIALS, "password");
    h.put(Context.PROVIDER_URL, url);
    return new InitialContext(h);
    } catch (NamingException ne) {
    log("We were unable to get a connection to the WebLogic server
    at "+url);
    log("Please make sure that the server is running.");
    throw ne;
    private registerObject()
    throws NamingException
    // Lookup the beans home using JNDI
    Context ctx = getInitialContext();
    try{
    //This binding works fine.
    String bname = "Ganga";
    ctx.bind("plainname", bname);
    //This one throws an Naming Exception..
    ctx.rebind("one.two.three", bname);
    } catch(javax.naming.NameAlreadyBoundException nlb){
    System.out.print(nlb.getMessage());
    System.exit(0);
    }catch(javax.naming.directory.InvalidAttributesException iae){
    System.out.print(iae.getMessage());
    System.exit(0);
    }catch(NamingException ne){
    System.out.print(ne.getMessage());
    System.exit(0);
    Exception msg is : Unable to resolve 'one.two.three' Resolved: '' Unresolved:'one'

  • How to bind the value of textbox with View object's bind variable?

    Hi all,
    In my use case I need to pass the value of textbox in the jsf page to the View Object's bind variable.
    I should not hard code this in my backing bean. I need to configure in the Jdeveloper itself.
    I am using Jdeveloper 11.1.1.4.0 version. Kindly come up with your help.
    Thanks,
    Phani.

    Hi,
    You have to use Named Bind Variables(ExecuteWithParams)
    http://download.oracle.com/docs/cd/B31017_01/web.1013/b25947/web_search_bc004.htm
    http://www.cloudsolid.com/2008/10/using-named-bind-variables.html

  • Re: AQ/Referenceable Objects work with MDB on WebLogic

              Great work! So you don't have to touch any of Oracle's classes, correct?
              Do you have time to document the whole thing and post it here, including the source
              code of all your custom classes?
              Eric Ma
              "Diptanshu Parui" <[email protected]> wrote:
              >
              >Forgot to add an important point.
              >The extended classes have to in the oracle.jms package (not necessarily
              >in the
              >same jar) to extend the Oracle classes. And I have used aqapi13.jar.
              >
              >Dips
              >
              >"Diptanshu Parui" <[email protected]> wrote:
              >>
              >>Hi,
              >>
              >>After days of work on getting to integrate Oracle's AQ with WebLogic
              >>I have managed
              >>to get to a solution without making changes to the Oracle's AQ API.
              >>
              >>Eric Ma had managed to provide a solution about an year back changing
              >>Oracle's
              >>API and making the AQjmsConnection, AQjmsSession, AQjmsQueueConnectionFactory
              >>& AQjmsDestination NOT implement Referenceable. This solution worked
              >>with WebLogic
              >>but meant that this cannot be deployed on Production environment.
              >>
              >>There was a myth that WebLogic's JNDI didn't provide support to Referenceable
              >>objects like Oracle's AQjmsQueueConnectionFactory etc.
              >>
              >>This myth has been broken. Referenceable object CAN be bound and looked
              >>up from
              >>WebLogic's JNDI provided right Factory classes are written and the correct
              >>constructor
              >>for Reference is used in the getReference method of the Referenceable
              >>implementation.
              >>
              >>In case of Oracle's objects, I wrote classes extending AQjmsQueueConnectionFactory
              >>& AQjmsDestination. In the extended classes, I wrote toString method
              >>and set private
              >>String variable.
              >>This string variable is just special character separated concat of all
              >>parameters
              >>used to call the constructor of the extended class.
              >>Then, in the getReference method of the extended class, I used the following
              >>constructor
              >>of Reference.
              >>
              >>return new Reference( DipsAQQueueConnectionFactory.class.getName(),
              >new
              >>StringRefAddr("value",
              >>value), DipsAQConnectionFactory.class.getName(), null);
              >>
              >>DipsAQQueueConnectionFactory is my class extending AQjmsQueueConnectionFactory
              >>and DipsAQConnectionFactory is the factory class for DipsAQQueueConnectionFactory.
              >>The object value passed in the StringRefAddr above is nothing but the
              >>toString
              >>of the extended class which was stored in the private String variable.
              >>In the
              >>factory class, the string is taken out the StringRefAddr and stripped
              >>to get individual
              >>parameters which were separated by special characters. Once, the individual
              >>parameters
              >>are got back, the Factory class instantiates the Referenceable object
              >>and returns
              >>it back.
              >>
              >>Another important point is in the extended class DipsAQQueueConnectionFactory
              >>I wrote this method
              >> public QueueConnection createQueueConnection() throws JMSException
              >>
              >> {
              >>     return createQueueConnection("user","user");
              >> }     
              >>
              >>And then using a startup class I bound the DipsAQQueueConnectionFactory
              >>& DipsAQDestination
              >>Referenceable objects to WLS. The MDB deployed on WLS was made lookup
              >>for the
              >>bound QF & Q and it started reading AQ messages.
              >>
              >>Few other points to note.
              >>I have kept the user & pwd of WLS same as DB.
              >>I have used OCI driver.
              >>
              >>Please feel free to raise further queries/suggestions.
              >>
              >>Dips
              >
              

              Eric,
              This is the relevant part of the config.xml you were looking for.
                   <JMSDistributedQueue JNDIName="DQueue1" Name="DQueue1" Targets="ClusterTwo" Template="DQueue1">
                        <JMSDistributedQueueMember JMSQueue="Queue1" Name="DQM1"/>
                        <JMSDistributedQueueMember JMSQueue="Queue2" Name="DQM2"/>
                   </JMSDistributedQueue>
                   <JMSBridgeDestination
                        ConnectionFactoryJNDIName="AQJMSConnectionFactory" ConnectionURL="t3://ip:port"
                        DestinationJNDIName="AQJMSQueue" Name="AQJMSDest"/>
                   <JMSConnectionFactory JNDIName="ConnectionFactory" Name="ConnectionFactory"
                        ServerAffinityEnabled="false" Targets="IAServer,ClusterTwo" XAConnectionFactoryEnabled="true"/>
                   <JMSBridgeDestination ConnectionFactoryJNDIName="ConnectionFactory" ConnectionURL="t3://ip:port"
                        DestinationJNDIName="DQueue1" Name="Dest"/>
                   <MessagingBridge Name="MB1" QualityOfService="Duplicate-okay"
                        SourceDestination="AQJMSDest" TargetDestination="Dest"
                        Targets="IAServer,MS1 (migratable),MS2 (migratable),ClusterTwo"/>
              No, I haven't used Oracle's OC4J 10g's AQJMS XA TX support classes.
              cheers!
              Dips
              "Eric Ma" <[email protected]> wrote:
              >
              >Dips:
              >
              >Can you post your config.xml here to show how you set up WLS messaging
              >bridges?
              >
              >Also, have you played with OC4J 10g's AQJMS XA TX support classes?
              >
              >Eric
              >
              >"Diptanshu Parui" <[email protected]> wrote:
              >>
              >>The sample code is now available at
              >>http://dev2dev.bea.com/codelibrary/code/startupclass.jsp
              >>
              >>cheers,
              >>Dips
              >>
              >>
              >>"Diptanshu Parui" <[email protected]> wrote:
              >>>
              >>>Yes, no need to touch Oracle's code at all.
              >>>
              >>>I will post the whitepaper/code soon.
              >>>
              >>>
              >>>"Eric Ma" <[email protected]> wrote:
              >>>>
              >>>>Great work! So you don't have to touch any of Oracle's classes, correct?
              >>>>
              >>>>Do you have time to document the whole thing and post it here, including
              >>>>the source
              >>>>code of all your custom classes?
              >>>>
              >>>>Eric Ma
              >>>>
              >>>>
              >>>>"Diptanshu Parui" <[email protected]> wrote:
              >>>>>
              >>>>>Forgot to add an important point.
              >>>>>The extended classes have to in the oracle.jms package (not necessarily
              >>>>>in the
              >>>>>same jar) to extend the Oracle classes. And I have used aqapi13.jar.
              >>>>>
              >>>>>Dips
              >>>>>
              >>>>>"Diptanshu Parui" <[email protected]> wrote:
              >>>>>>
              >>>>>>Hi,
              >>>>>>
              >>>>>>After days of work on getting to integrate Oracle's AQ with WebLogic
              >>>>>>I have managed
              >>>>>>to get to a solution without making changes to the Oracle's AQ API.
              >>>>>>
              >>>>>>Eric Ma had managed to provide a solution about an year back changing
              >>>>>>Oracle's
              >>>>>>API and making the AQjmsConnection, AQjmsSession, AQjmsQueueConnectionFactory
              >>>>>>& AQjmsDestination NOT implement Referenceable. This solution worked
              >>>>>>with WebLogic
              >>>>>>but meant that this cannot be deployed on Production environment.
              >>>>>>
              >>>>>>There was a myth that WebLogic's JNDI didn't provide support to
              >Referenceable
              >>>>>>objects like Oracle's AQjmsQueueConnectionFactory etc.
              >>>>>>
              >>>>>>This myth has been broken. Referenceable object CAN be bound and
              >>looked
              >>>>>>up from
              >>>>>>WebLogic's JNDI provided right Factory classes are written and the
              >>>>correct
              >>>>>>constructor
              >>>>>>for Reference is used in the getReference method of the Referenceable
              >>>>>>implementation.
              >>>>>>
              >>>>>>In case of Oracle's objects, I wrote classes extending AQjmsQueueConnectionFactory
              >>>>>>& AQjmsDestination. In the extended classes, I wrote toString method
              >>>>>>and set private
              >>>>>>String variable.
              >>>>>>This string variable is just special character separated concat
              >of
              >>>>all
              >>>>>>parameters
              >>>>>>used to call the constructor of the extended class.
              >>>>>>Then, in the getReference method of the extended class, I used the
              >>>>following
              >>>>>>constructor
              >>>>>>of Reference.
              >>>>>>
              >>>>>>return new Reference( DipsAQQueueConnectionFactory.class.getName(),
              >>>>>new
              >>>>>>StringRefAddr("value",
              >>>>>>value), DipsAQConnectionFactory.class.getName(), null);
              >>>>>>
              >>>>>>DipsAQQueueConnectionFactory is my class extending AQjmsQueueConnectionFactory
              >>>>>>and DipsAQConnectionFactory is the factory class for DipsAQQueueConnectionFactory.
              >>>>>>The object value passed in the StringRefAddr above is nothing but
              >>>the
              >>>>>>toString
              >>>>>>of the extended class which was stored in the private String variable.
              >>>>>>In the
              >>>>>>factory class, the string is taken out the StringRefAddr and stripped
              >>>>>>to get individual
              >>>>>>parameters which were separated by special characters. Once, the
              >>individual
              >>>>>>parameters
              >>>>>>are got back, the Factory class instantiates the Referenceable object
              >>>>>>and returns
              >>>>>>it back.
              >>>>>>
              >>>>>>Another important point is in the extended class DipsAQQueueConnectionFactory
              >>>>>>I wrote this method
              >>>>>> public QueueConnection createQueueConnection() throws JMSException
              >>>>>>
              >>>>>> {
              >>>>>>     return createQueueConnection("user","user");
              >>>>>> }     
              >>>>>>
              >>>>>>And then using a startup class I bound the DipsAQQueueConnectionFactory
              >>>>>>& DipsAQDestination
              >>>>>>Referenceable objects to WLS. The MDB deployed on WLS was made lookup
              >>>>>>for the
              >>>>>>bound QF & Q and it started reading AQ messages.
              >>>>>>
              >>>>>>Few other points to note.
              >>>>>>I have kept the user & pwd of WLS same as DB.
              >>>>>>I have used OCI driver.
              >>>>>>
              >>>>>>Please feel free to raise further queries/suggestions.
              >>>>>>
              >>>>>>Dips
              >>>>>
              >>>>
              >>>
              >>
              >
              

  • Is Object Table a true Reference Table?

    Does Object table only contain reference of each row objects within the table?
    Does the Object Table take up the same disk space as compare to relational table with the same number of rows?
    Your help in the above two questions is very appreciated!
    Fred.
    null

    VB.Net is object oriented in the same sense as C++ is. It provides objects but doesn't require them. Java goes further by requiring that all code must be in classes and Smalltalk goes all the way by treating primitive types as objects as well.
    VB.Net is much more object oriented than VB6, which didn't have classes but did have components. All of VB, C# and Managed C++ run under the Common Language Runtime so share a lot of structure.

  • Dynamic view object loses bind variables after passivation

    I am creating a view object definition/view object programmatically in Jdev 11.1.1.2.0. The query requires a named bind parameter. All was working fine but now I am testing with app module pooling disabled and the bind variable is not being restored after passivation -- it's like the definition has disappeared or something.
    Here is my VO creation code:
    ViewObject vo = findViewObject("FinalistsWithEvalDataVO");
    if (vo != null){
    vo.remove();
    ViewDefImpl voDef = new ViewDefImpl("FinalistsWithEvalDataVODef");
         // I add a bunch of viewAttrs here...
    voDef.setQuery(fullQuery);
    voDef.setFullSql(true);
    voDef.setBindingStyle(SQLBuilder.BINDING_STYLE_ORACLE_NAME);
    voDef.resolveDefObject();
    voDef.registerDefObject();
    vo = createViewObject("FinalistsWithEvalDataVO", voDef);
    vo.defineNamedWhereClauseParam("Bind_SchlrAyId", null, new int[] {0});
    vo.setNamedWhereClauseParam("Bind_SchlrAyId", new Number(1)); //For testing
    vo.executeQuery();
    The query executes fine right there and then the VO seems to passivate fine. I even see the bind var in passivation:
    <exArgs count="1">
    <arg name="Bind_SchlrAyId" type="oracle.jbo.domain.Number">
    <![CDATA[1]]>
    </arg>
    </exArgs>
    But then when it reactivates prior to rendering the page, it invariably throws a missing parameter exception and this in the log:
    <ViewUsageHelper><createViewAttributeDefImpls> [7409] *** createViewAttributeDefImpls: oracle.jdbc.driver.OraclePreparedStatementWrapper@1af78e1
    <ViewUsageHelper><createViewAttributeDefImpls> [7410] Bind params for ViewObject: [FinalistsWithEvalDataVO]AwardViewingServiceAM.FinalistsWithEvalDataVO
    <ViewUsageHelper><createViewAttributeDefImpls> [7411] ViewUsageHelper.createViewAttributeDefImpls failed...
    <ViewUsageHelper><createViewAttributeDefImpls> [7412] java.sql.SQLException: Missing IN or OUT parameter at index:: 1
    I have worked on this for hours and can't see anything wrong. Like I said, it works fine when not forcing passivation...
    Any help would be appreciated.
    Thanks.
    -Ed

    @Jobinesh - Thanks for the suggestions. I have read all the documentation I can find. Everything works fine without passivation. Everything still breaks with passivation. I have given up on trying to get the bind variable to restore after passivation and am currently just building the query with all values embedded in the query rather than bind variables. This is bad practice but avoids the problem. However, now that I avoided that obstacle, I'm on to the next issue with passivation of this dynamic view object, which is that the current row primary key apparently cannot be reset after activation. I get the following error:
    <Key><parseBytes> [7244] Key(String, AttributeDef[]): Invalid Key String found. AttributeCount:1 does not match Key attributes
    <DCBindingContainer><reportException> [7254] oracle.jbo.InvalidParamException: JBO-25006: Value 00010000000A30303033383133343734 passed as parameter String to method Constructor:Key is invalid: {3}.
         at oracle.jbo.Key.parseBytes(Key.java:537)
         at oracle.jbo.Key.<init>(Key.java:179)
         at oracle.jbo.server.IteratorStateHolder.getCurrentRowKey(IteratorStateHolder.java:34)
         at oracle.jbo.server.ViewRowSetIteratorImpl.activateIteratorState(ViewRowSetIteratorImpl.java:3877)
    I've been trying various workarounds for over a day now with no luck. Very frustrating.
    Thanks for trying to help.
    -Ed

  • View object query bind variable

    I have a bind variable in my view object query and "Required" is unchecked for it. Due to this JUnits are failing with the Missing IN or OUT parameter error. If I set the bind variable as required, the JUnits run fine.
    But this bind variable is also used in several view criterias where it is set as Optional. So if I set the bind variable in the view object query as Required, will it affect the view criterias as well?

    check https://blogs.oracle.com/jdevotnharvest/entry/the_infamous_missing_in_or

  • How to bind a complex object to a composite component

    I'm using JSF2 and having an issue binding an object (EL Expression) as a parameter to my composite component.
    I have written a composite component (not very complex) that will display a drop-down list of countries and should bind the selection to a provided target bean.
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:composite="http://java.sun.com/jsf/composite"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:a4j="http://richfaces.org/a4j"
    xmlns:rich="http://richfaces.org/rich">
    <!-- INTERFACE -->
    <composite:interface>
    <composite:attribute name="label" required="true" />
    <composite:attribute name="requiredMessage" required="true"/>
    <composite:attribute name="target" required="true" type="com.mycompany.entity.Country"/>
    </composite:interface>
    <!-- IMPLEMENATION -->
    <composite:implementation>
    <h:panelGrid columns="2">
    <h:outputLabel for="country-list" value="#{cc.attrs.label}"/>
    <h:panelGrid id="country" columns="1" styleClass="select-one-menu-panel" >
    <h:selectOneMenu id="country-list"
    enabledClass="select-one-menu-enabled" disabledClass="select-one-menu-disabled"
    layout="pageDirection"
    value="#{cc.attrs.target}"
    required="true" requiredMessage="#{cc.attrs.requiredMessage}"
    >
    <f:selectItem itemLabel="#{msgs['label.pleaseSelect']}" itemValue="" />
    <f:selectItems value="#{countryController.countries}" />
    <a4j:ajax />
    </h:selectOneMenu>
    <a4j:outputPanel id="country-list-error-panel" ajaxRendered="true">
    <h:message id="country-list-error" for="country-list" style="color:red"/>
    </a4j:outputPanel>
    </h:panelGrid>
    </h:panelGrid>
    </composite:implementation>
    </html>
    I want to be able to use the composite component in the following way:
    <util:country-select
    label="#{msgs['label.countryOfBirth']}"
    requiredMessge="#{msgs['error.birthCountryRequired']}"
    target="#{participant.countryOfBirth}"/>
    When I load the page everything renders correctly, but when I select an item from the drop-down I get a validation error.
    apply-form:j_idt77:country-list: Validation Error: Value is not valid
    I know that it must be something with the way that I have the parameters defined but I simply can't find any information to help me figure this out.
    Any light that you might be able to she on this would be greatly appreciated.
    Thank you for the help...

    Hi,
    well, you can. What the ADF Data Control and thus the binding gives you is the JSF component binding and the business service access.
    If you don't want to use ADF, then what you can do is
    - Create an ADF BC root Application Module from a managed bean
    e.g. see http://docs.oracle.com/cd/E21764_01/web.1111/b31974/bcservices.htm#CHDDDBFC
    - Access the View Object for querying the data to display
    - Expose the queried data so the component can handle it e.g. setter/getter for input components, ArrayList for tables (or you create the more complex component models like table and tree models)
    Having outlined the above, here are some gotchas to watch out for
    - Make sure creating the root application module is done such that you don't create/release it with each request. So you may consider a data serving managed bean in a scope like page flow or session
    - Ensure you have helper methods that allow you to query and CRUD operate the View Object data
    Frank

  • How to bind "Image Field" object on a database

    Hi to all
    I inserted into a dynamic PDF (Livecycle ES3 trial) an image field, but I don't understand how I can to bind a JPG into a database.
    In (F5) preview... I'm able to open a image file on filesystem and visualize it on PDF form... but then? How to bind on database?
    In my several tentatives I'm using a MS Access 2010 database table, where I defined a OLE object... but doesn't work.
    Thank you at all.
    visert

    Hi,
    I have not tried to do this, but this document provides some instructions.
    http://partners.adobe.com/public/developer/en/livecycle/lc_designer_XML_schemas.pdfhttp://partners.adobe.com/public/developer/en/livecycle/lc_designer_XML_schemas.pdf
    Hope it helps
    Bruce

  • Using a polymorphic view object with binding

    Hi,
    I'm hoping there's something simple I'm missing when trying to setup up the bindings for a ADF/struts page using a polymorphic view object.
    I'm using Entity and VO polymorphism to create a Question which has different types - boolean, multi-choice, likert, etc. I have the various question types created as sub type entity and view objects and added to the app module - when added to the app module the question types are subtypes of QuestionView so they don't actually appear in the Data Controls palette. This setup is like that used in Steve Muench's examples (blog at http://radio.weblogs.com/0118231/stories/2003/02/06/constructingTheDesiredEntityInAPolymorphicViewObject.html and the related undocumented one)
    My question is, how do I get to the data and have jdev create the necessary bindings for the extra attributes the subtype questions have? Since they don't appear as available data controls I can't create a binding iterator or anything for them - short of adding them as spearate view objects (which destroys the whole point of using polymorphism in this case) is there a way to do this?
    Really, the only reason I want to use the polymorphism is so I can have different types of entity validation depending on the type. Should I just simplify this to be one entity object with one VO and put all the validation into "if else's" based on a discriminator?
    Assistance appreciated...
    - Nathaniel

    How else are you planning to associate a JUTableBinding to the 'common' iterator containing all four types of rows and then selectively display them? Perhaps you'd need a custom model over the JUTabelModel that'd filter the rows out.
    I'm not sure if all that trouble is worth it given that your datasets (as far as mentioned in this post) are not large. If these tables/data has to be refreshed/executed a number of times, then you may see the overhead of four queries otherwise it should be fine as database is always faster in filtering rows than doing that in memory.

  • ADF -how to create table binding when view object is no known until runtime

    I want to programmatically create a table binding to a view object where the view object name is not known until run-time. Then I will use a dynamic table to display it. Can anyone provide an example?

    I looked at example #9. It gets me closer to what I am looking for but not quite enough. In my case, I don't have (or want in this case) a pageDefinition with a pre-declared Iterator binding. I am converting an exsisting BC4J/Struts/JSP application. I would like to rewrite my reusable component tags to make use of ADF bindings and Faces. My tags are passed the ApplicationModule and ViewObject names as parameters, much like the old BC4J datatags. I do not want to go back and rewrite all of my pages from scratch using drag-and-drop declarative bindings with a pageDefinition for every page. I am hoping to have my rewritten tags handle everything programmatically based only on the ViewObject name passed at run-time.

Maybe you are looking for

  • Can't make an event go away in the html..

    I created an event (all day) some time in the past. Then I deleted this event. It has gone away on my iCal and on other Mac Subscriber(s) iCal versions. The html version at my .Mac account continues to display this event. I've tried unpublishing and

  • How to handle freight vendor ?

    Dear friends, The scenario is like - Company places the PO to a vendor, say A. In this PO I have freight condition and to this condition I have freight vendor assigned, say B. (e.g. PO contains material price $10 and freight value $1) I then post the

  • Reference to record

    Hi, I have problem with referencing to record of table. Could you help me, please. I have two tables: tab1(PK_tab1,something) and tab2(PK_tab2,FK_pk_tab1,somethingelse) relation tab1.pk = tab2.FK_pk_tab1 On 1st page(report) is displayed by select * f

  • Data written in file doesnt remain the sme!!

    Hey guys I am writing a small app for myself to store imp data like my IDs, passwords etc. I want this application to -accept string -get ASCII value of each character -make cipher by changing ASCII values -store new characters in a file. The code is

  • Major textfield bug AIR 3.7/3.8 on Android

    Hey guys, I was wondering if anyone encountered this bug and managed to fix it. If not (or if this is not my fault somehow), I will open a bug report about it. The bug does not happen on AIR 3.6 on any platform. It also does not happen on 3.7/3.8 for