define the result

Hi all

I just want to know how to create a result that is displayed as a result of the State:

example is similar to

If the output equal to 1 = good
2 = better
3 = excellent

someone at - he had the idea how I can do?
Thank you

Nadège azym
UTHM
Malaysia


Tags: NI Software

Similar Questions

  • How to define the result of a call sequence of pass/fail

    Hi all

    in my application, I have a pass/fail with the adapter of the test sequence. The Source of data for the stage is Step.Result.PassFail.

    Is it possible to tell the appellant (the stage of appeal for success/failure sequence) the result within the sequence? I've experimented with the RunState.Caller, but did not find any property that applies to the PassFail result.

    Madottati

    This link is not very useful and, in my view, is not the right solution for you.

    It makes not sense why you need to change the Step.Result.PassFail inside your sequence.  It is not evaluated until after that sequence is returned to the caller.  So why not just pass back a parameter and and set the Step.Result.PassFail parameter.  I've attached a picture that shows.

    However, if it is essential that you change in the subsequence Fail pass then use this expression:

    RunState.Caller.Step.Result.PassFail = here, a Boolean expression

    It won't evaluate at time of publishing, but will work during runtime.

    The reason why you use Pass/Fail card combination and sequence is to create a modularized test.  Let's say you need to call several code modules in order to obtain pass/fail status.  Think of it as a function or a Subvi.  It just creates a clean, maintainable code.

    Hope this helps,

  • defining the results of a query to a variable

    Hi all

    I'm having a problem affecting the results of a query to a variable. What I'm trying to do, is to do an AJAX call to a .cfc file and pass back the results of the function. The main problem is, I'm again moving a block of HTML (resulting from a cfquery in a cfoutput) stored in a variable. My code is something like...

    < name cffunction = "getText" access = "remote" returntype = 'Cancel' >

    < datasource = "" #request.dsn # cfquery "name ="queryTable">"
    SELECT kort, infoB

    Of infoTable

    < / cfquery >


    < cfset result = ' <!-this is the part I'm stuck, I want the table go here. -> ">"

    < table >
    < cfoutput query = "tablequery" >
    < b >
    < td > #infoA # < table > < td > #infoB # < table >
    < /tr >
    < / cfoutput >
    < /table >


    < cfwddx action = "cfml2js" input = "" # result # ' toplevelvariable 'o' = > "

    < / cffunction >

    It is a simplified version of what I want to do, but you get the idea...

    Is it still the right way to go about this?  Thank you

    That's what I get for trying the E-mail response feature!  Are you not happy, that I double checked my post.

    You could do a lot of string concatenation here to do stuff like"& Kort &""& infoB &""> time and time again."  But in reality the tags is so much easier to use.



      

        
      

    #infoA #.#infoB #.

  • Schema of database for the processing of the results

    Hi all

    I have a question on the results of teststep registration in the database. I use the generic recordset as my database for the recording of data.

    In my database (SQL Server), there are the following diagrams: dbo, dbtest1, dbtest2. I created all the tables of results (UUT_Result, Step_Result etc...) of the generic Recordset object in all schemas. Therefore, to display the results in the table of Step_Result, I specify the schema as well as the name of the table, for example SELECT * FROM dbtest1. Step_Result.

    Is there a way to tell Teststand to save the result in another schema (dbo, dbtest1, dbtest2) programmatically?

    Yours sincerely,

    chati

    Yes, the tool is easier to visualize what makes SQL. A user can access patterns as much as they have permission for. The problem is that, in order to specify the schema, you must assign the rating on your SQL commands. I don't know of an easy way to do this in Teststand.

    If you manually create the SQL commands is noted:

    [Database]. [Schema]. [Table]

    It is easier to implement multiple user names and to use the default schema to define.

    You can also have a database that is different for each category of journaling (and no need to use patterns at all).

    A lot of good information here:

    https://TechNet.Microsoft.com/en-us/library/dd283095 (v = sql.100) .aspx

  • PNG to the result "ugly" 2D photo

    First of all, sorry about I can't better define my problem, but I'm really not that familiar with the handling of graphics and transform the image, so I can say only the result is ugly

    I have a simple example, created from a file png file vector graphic svg with Inkscape. Png size is 300 x 200, PPP: 270.

    My problem is, I want to introduce this png on my façade of good quality image, an indicator of the 2D image. When I do this, the result looks "ugly" or "pixelated". Is there a way to view these files png in LV with better quality (I LV 2015 32-bit Pro, but no IMAQ and other similar toolkits available)? If I have a look at this file png using, for example, Irfanview, even after some zoom, the image looks good and "smooth".

    Currently, I use this simple way to load the png in the 2D image indicator:

    I've also attached the file png for reference.

    Edit:

    When I compare the LV and Irfanview results (left is LV):

    I take your png and fill the white background.
    There are results (low img):

  • Unexpected behavior with the Option "record in the result.

    Hello

    I have unexpected behavior with the Option "record in the result.

    I have a few steps in the subsequence 'X', this subsequence passes a Boolean parameter. According to the value of the parameter I change the "Recorgind results" Option to report it or not. The thing is that if 'result Recorgind' set at race time I modofy by changing the value of Step.ResultRecordingOption to "Enable" and "Disable", the step is not reported until the same sous-suite 'X' is called for the second time (without changing the parameter passed).

    For example: (Preconditon: result Recorgind Option of all value sous-suite x are defined as Disable)

    1 CallSubsequenceX(Parameter: Enable)

    2 CallSubsequenceX(Parameter: Enable)

    3 CallSubsequenceX(Parameter: Disable)

    4 CallSubsequenceX(Parameter: Disable)

    Expected result:

    1. measures have been reported.

    2. measures have been reported.

    3. measures have not been reported.

    4. measures have not been reported.

    Result:

    1. measures would not same value Step.ResultRecordingOption has been changed to 'enable '. (Not Ok)

    2. measures have been reported. (Ok)

    3. measures reported same value Step.ResultRecordingOption has been changed to 'disable '. (Not Ok)

    4. measures have not been reported. (Ok)

    I use TestStand 2013 (5.1.0.226)

    Thanks in advance.

    -Josymar.

    Hi josymar_guzman,

    I just review the sequence and indeed we´re experience unexpected behavior with the Step.ResultRecordingOption callback. By a reason when you run the callback in the expression before each step section, the statement runs only until the next sequence is called, which is not what we want.

    To avoid this, you can place a statement before each step of the sequence, so you can change the State of the Option "record result" for the sequence running (and it is only the following). You can try something like this

    where the expression of the statement will be the recall "RunState.NextStep.ResultRecordingOption is YourCondition". With this, we guarantee that the results of the next step will be saved or not. I also remove the expression in the expression prior to each step section, because the condition is now on the statement before each step.

    I tried and it works fine. I´ll set the sequence that you share with me, with the changes. I hope this will help you and solve your problem.

  • Join the results of a case statement

    Hello everyone;

    I can't with a query where I use a case statement to create a new column and attempt to reach an additional table on the resulting column.  I am fairly new to this and learn by trial and error, so if you think that it looks a little ugly or ineffective, I won't be offended.  It is used on my interface based on the web of companies, while I am not able to answer some basic questions such as the version of db.

    My need to use the case statement is the result of some strange methods and somewhat contradictory in order to link the product subcodes (sku, fcsku, fnsku), to a product code parent (ProdID).  In this case, the inventory is stored in the first table with one of the few types of premises SKUs, however the dimensional data only links to the ProdID.  I'm trying to instruction box allows to send the parent a second table (ProdID) code if the sku is there, or a third table if it is found on this table.  The main reason (in this case) I have to this ProdID is I can join the dimensional data of a fourth table.

    My current query:

    SELECT / * + USE_HASH (dbin, sku, xProdID, msr) * /.

    dbin.snapshot_date, dbin.bin_id, dbin. ISBN,

    CASE WHEN sku. ProdID IS NULL THEN xProdID.ITEM_AUTHORITY_ID

    Of ANOTHER sku. ProdID

    END ProdIDMaster,

    dbin. OWNER, dbin. QUANTITY, dbin. CONTAINER_ID,

    MSR. HEIGHT, msr. WIDTH, msr. LENGTH, msr. WEIGHT, msr. DIMENSIONAL_UOM, msr. WEIGHT_UOM,

    MSR. HEIGHT * msr. WIDTH * msr. LENGTH as a Volume

    OF D_BIN_ITEMS dbin

    SKU of LEFT JOIN O_FCSKUS ON dbin. ISBN = sku. FCSKU

    LEFT JOIN (SELECT * FROM D_FNSKU_ProdID_MAP)

    WHERE REGION_ID = 1

    AND SNAPSHOT_DAY = TO_DATE('{RUN_DATE_YYYY/MM/DD}','YYYY/MM/DD')) xProdID

    ON dbin. ISBN = xProdID.FULFILLMENT_NETWORK_SKU

    LEFT JOIN (SELECT * FROM D_MP_ProdID_PKG_MEASUREMENTS)

    WHERE REGION_ID = 1 AND MARKETPLACE_ID = 1 AND PACKAGE_TYPE_ID = 1) msr

    ON ProdIDMaster = msr. ProdID

    WHERE dbin. WAREHOUSE_ID = "PHL5."

    AND dbin. Snapshot_date = TO_DATE('{RUN_DATE_YYYY/MM/DD}','YYYY/MM/DD')

    AND dbin.bin_id like '% P-1-R '.

    ORDER BY dbin.bin_id;

    The error I receive:

    Statement 1 is invalid. ORA-00904: "ProdIDMaster": invalid identifier

    ProdIDMaster appears only in two places, an alias for the case statement, as well as a side of the join statement.  If I simply change the alias name, it has no effect, so I can only assume the question is how I refer to results of the case statement. I also tried to reach the word 'CASE', which returned "1 statement is not valid. "ORA-00904:"The MATTER": invalid identifier.

    Any help or advice would be greatly appreciated.

    Post edited by: 8ea4344e-80ea-44e7-b8ac-d482be7245a7 I made a mistake when I posted the code.  The ProdID_ID shown in the join should have been ProdIDMaster.  I need to change this due to the fact that the name of the column used (which is what I based my alias on) may have been considered confidential information. All the other columns names remained unchanged.

    Hello

    8ea4344e-80EA-44e7-B8AC-d482be7245a7 wrote:

    Hello everyone;

    I can't with a query where I use a case statement to create a new column and attempt to reach an additional table on the resulting column.  I am fairly new to this and learn by trial and error, so if you think that it looks a little ugly or ineffective, I won't be offended.  It is used on my interface based on the web of companies, while I am not able to answer some basic questions such as the version of db.

    My need to use the case statement is the result of some strange methods and somewhat contradictory in order to link the product subcodes (sku, fcsku, fnsku), to a product code parent (ProdID).  In this case, the inventory is stored in the first table with one of the few types of premises SKUs, however the dimensional data only links to the ProdID.  I'm trying to instruction box allows to send the parent a second table (ProdID) code if the sku is there, or a third table if it is found on this table.  The main reason (in this case) I have to this ProdID is I can join the dimensional data of a fourth table.

    My current query:

    SELECT / * + USE_HASH (dbin, sku, xProdID, msr) * /.

    dbin.snapshot_date, dbin.bin_id, dbin. ISBN,

    CASE WHEN sku. ProdID IS NULL THEN xProdID.ITEM_AUTHORITY_ID

    Of ANOTHER sku. ProdID

    END ProdIDMaster,

    dbin. OWNER, dbin. QUANTITY, dbin. CONTAINER_ID,

    MSR. HEIGHT, msr. WIDTH, msr. LENGTH, msr. WEIGHT, msr. DIMENSIONAL_UOM, msr. WEIGHT_UOM,

    MSR. HEIGHT * msr. WIDTH * msr. LENGTH as a Volume

    OF D_BIN_ITEMS dbin

    SKU of LEFT JOIN O_FCSKUS ON dbin. ISBN = sku. FCSKU

    LEFT JOIN (SELECT * FROM D_FNSKU_ProdID_MAP)

    WHERE REGION_ID = 1

    AND SNAPSHOT_DAY = TO_DATE('{RUN_DATE_YYYY/MM/DD}','YYYY/MM/DD')) xProdID

    ON dbin. ISBN = xProdID.FULFILLMENT_NETWORK_SKU

    LEFT JOIN (SELECT * FROM D_MP_ProdID_PKG_MEASUREMENTS)

    WHERE REGION_ID = 1 AND MARKETPLACE_ID = 1 AND PACKAGE_TYPE_ID = 1) msr

    ON ProdIDid_ID = msr. ProdID

    WHERE dbin. WAREHOUSE_ID = "PHL5."

    AND dbin. Snapshot_date = TO_DATE('{RUN_DATE_YYYY/MM/DD}','YYYY/MM/DD')

    AND dbin.bin_id like '% P-1-R '.

    ORDER BY dbin.bin_id;

    The error I receive:

    Statement 1 is invalid. ORA-00904: "ProdIDMaster": invalid identifier

    ProdIDMaster appears only in two places, an alias for the case statement, as well as a side of the join statement.  If I simply change the alias name, it has no effect, so I can only assume the question is how I refer to results of the case statement. I also tried to reach the word 'CASE', which returned "1 statement is not valid. "ORA-00904:"The MATTER": invalid identifier.

    Any help or advice would be greatly appreciated.

    Whenever you have a problem, please post a small example data (CREATE TABLE and only relevant columns, INSERT statements) of all the tables involved, so that people who want to help you can recreate the problem and test their ideas.

    Also post the exact results you want from this data, as well as an explanation of how you get these results from these data, with specific examples.

    Always say what version of Oracle you are using (for example, 11.2.0.2.0).  Use "SELECT * VERSION of $ v;" to get it.

    See the FAQ forum: Re: 2. How can I ask a question on the forums?

    When you define an alias for column (such as PriodIDMaster) in the SELECT a query clause, you can use the alias in the ORDER byclause in this request, but this is the only place in this same query, where you can use it.  If you want to use anywhere, like in a join condition, then calculate the new column in a subquery; then you can use it anywhere you want in a Super request.

    I see expression BOX (not the same as a declarationBOX) where when ProdIDMaster is defined, but I do not see where it is used.  Are you sure that you posted the code that is causing the problem?

  • How to define the rules of navigation in faces - config.xml dynamically?

    In jdev 12.1.2 I am studying and performing the adf faces demo (12.1.2 version).

    I am trying to implement the function of navigation like this:

    1. in the navigation tree in the left panel of the accordion will show the features of an application which is read from database tables;

    2. When you click on a node in the navigation tree, a corresponding function/page will be launched in the Panel to the right of the home page;

    3. the navigation tree nodes display names and information pages target will be resident in the database tables and will be read in my case, the control of data bindings.

    and now I know, the click action was executed in this file in the demo: componentGallerySideBarTree.jsff:

    ->action = "#{stamp.actionOutcome}"

    < af:tree id = "tree" value = "#{attrs.menuModel}" var = "stamp" = "single" rowSelection fetchSize = "200" "

    Summary = "#{uploading." Summary}"disclosedRowKeys =" #{attrs.menuModel.foldersTreeState} "autoHeightRows = '0'"

    displayRow selectedRowKeys = "#{attrs.menuModel.selectionState}" = "selected" "

    contentDelivery = 'immediate' emptyText = "there are no demos for this category.

    styleClass = "AFStretchWidth" >

    < f: facet name = "nodeStamp" >

    < af:panelGroupLayout id = "nodePgl" >

    < af:image source = "#{stamp.ico}" styleClass = "GalleryIcon" shortDesc = "Image of a tree node" "

    ID = "nodeImg" / >

    < af:switcher facetName = "#{stamp.children == null?' leaves ': 'notLeaf'}" id = "nodeSw" > "

    < f: facet = "journal batch name" >

    < af:link id = text = "#{stamp.label"leafLink"} '"

    shortDesc = "#{stamp.label} #{stamp.deprecated eq 'real'?" (not recommended) " :"} »

    action = "#{stamp.actionOutcome}"

    inlineStyle = "#{stamp.deprecated eq 'true'?-style: italic; color: gray':"} ' "

    selected = "true" >

    < af:target execute="@this"/ >

    < / af:link >

    < / f: facet >

    < f: facet name = "notLeaf" >

    < af:outputText id = value = "#{stamp.label"notLeafText"} ' shortDesc =" #{stamp.label} "/ >"

    < / f: facet >

    < / af:switcher >

    < / af:panelGroupLayout >

    < / f: facet >

    < / af:tree >

    and the value of actionOutcome was entered in this file DemoConfusedComponentsMenuModel.java:

    (for the case of the confused component navagation tree folder)

    private TreeModel _initConfusedComponents()

    {

    Confused components

    The list < DemoItemNode > confusedComponentsNodes = new ArrayList < DemoItemNode >)

    {

    {

    ..

    Add (new DemoItemNode ("Tabs", "/ confusedComponents/tabs.jspx","/adfdt/panelTabbed.png","confused.tabs"));

    Add (new DemoItemNode ("iterators","/ confusedComponents/iterators.jspx","/adfdt/iterator.png","confused.iterators" ""));

    }

    };

    DemoItemNode confusedComponentsGroup = new DemoItemNode ("Often confused", "/ images/folder.png", confusedComponentsNodes);

    List ConfusedComponentsList = new ArrayList();
    confusedComponentsList.add (confusedComponentsGroup);

    TreeModel confusedComponents = new ChildPropertyTreeModel (confusedComponentsList, _CHILDREN);
    Return confusedComponents;
    }

    In addition, there are elements in faces-config .xml to define the rules of navigation for the actions 'by clicking on the tree node.

    <>navigation-case

    < from outcome >confused.iterators< / de-results >

    < to view - id > /confusedComponents/iterators.jspx< / to-view-id >

    <!-< redirect / >->

    < / navigation-case >

    So, I can add a new entry in the navigation tree, like this:

    1. in DemoConfusedComponentsMenuModel.javaof the file: Add

    Add (new DemoItemNode ("Iterators", "/confusedComponents/cms.jspx","/ adfdt/iterator.png","confused.cms" ""));

    2. in the file faces - config.xml, add:

    <>navigation-case

    < from outcome >confused.cms< / de-results >

    < to view - id > /confusedComponents/cms.jspx< / to-view-id >

    <!-< redirect / >->

    < / navigation-case >

    and it works!- I have successfully added a new node in the navigation tree, called a new page created by myself cms.jspx.

    If I implement them using database tables (links datacontrols EO/VO),.

    I think I can put action = "#{stamp.actionOutcome}" by links.

    But how can I pay the entry in the faces-config file. XML? -That is to say:

    How to define the rules of navigation in faces - config.xml dynamically?

    Thanks in advance!

    ADF 12 c comes with support for JSF 2.0, you can use the implicit navigation feature.

    In short: you don't need to add case action property, any set of navigation in the name of the page (and include the path if necessary).

    In your case, the name of the action will be: ' / confusedComponents/cms.jspx ' and of course, you can link the action property of method that returns this string.

    If you want to add by the case of navigation program, try ConfigurableNavigationHandler.

    For example:

    Manager of ConfigurableNavigationHandler = (ConfigurableNavigationHandler) FacesContext.getCurrentInstance () .getApplication () .getNavigationHandler ();

    handler.getNavigationCases () .put (...);

    Dario

  • Working with the results of the Action generated Poweshell

    Hello

    I have an action from orchestrator of a powershell script/function that I use regularly. The function is supposed to return a System.Object with email content (n, fromAdd, body, etc) that I would use in a script task.

    The problem I'm having is that I can't access these results in my work of scriptable. I know that the performance of the action a PowerShellRemotePSObject (and I have reviewed the literature on 'Working with PowerShell results'), but none of my attempts to explore the values give the results, I'm looking for. I'd appreciate any help to know what I'm missing.

    Thank you

    Thank you once again Ivo. Sorry for the delayed reactions. I took a peek at the solution you provided but had a few mistakes - there was no GetFilter() function defined for the call to psObject.getRootObject () .getProperty ('from'). After fiddling around with the results, I found my solution.

    I basically closed the rootobject of the return value of invocation of script that turns out to be a collection data structure (last result in the enumeration in italics/bold).

    .....

    rootObject var = psObject.getRootObject

    (rootObject element)

    {

    System.log (rootObject [index])

    }

    [10:43:33.159 2013-12-10] [I] DynamicWrapper (Instance): [PowerShellPSObject]-[class com.vmware.o11n.plugin.powershell.model.result.PSObject] - VALUE: com.vmware.o11n.plugin.powershell.model.result.PSObject@e9e592

    ....

    It turns out that the value of back in my Powershell script is the last element in the collection. from there, I could get my values:

    System.log (rootObj [rootObj.length - 1] .getProperty ("to"));

    System.log (rootObj [rootObj.length - 1] .getProperty ("from"));

    System.log (rootObj [rootObj.length - 1] .getProperty ("Subject"));

    System.log (rootObj [rootObj.length - 1] .getProperty ("body"));

    System.log (rootObj [rootObj.length - 1] .getProperty ("logFile"));

    I don't know if this will always be the case with psObject return values of Powershell called scripts, but several tests will help.

    Thanks for your time.

  • AF:inputListOfValues sets the value of the first item in the result set when using enter key or tab and component value autosubmit = true

    I use JDev 11.1.1.6 and when I type in a value in an af:inputListOfValues element and press enter or the tab key, it will replace the value I entered with the first element in the set of results LOV. If enter a value, simply click on the component af:inputListOfValues it works correctly. If I use the popup and find a value it works properly as well. I have a programmatic view object that contains a single transitional attribute (this is the view object that is used to create the list of the components of the value of) and then I have another object from view based on entities which defines one of its attributes in a list of the attribute value. I tried to use a base object view of entity to create the LOV to and everything works as expected, so I don't know if this is a bug when using programmatic view objects or if I need more code in the VOImpl. In addition, it seems after that first of the value being replaced by the first value in the result set that it will work correctly as well. Here are some excerpts of important code.

    Also, it seems that this does not work only if the text entered in the component af:inputListOfValues would have only a single game, returned in the result set. For example, given the result defined in code: Brad, Adam, Aaron, Fred, Charles, Charlie, Jimmy

    If we get into Cha, the component works as expected

    If we register A, the component works as expected

    If we get Jimmy, the component does not work as expected, and returns the first value of results IE. Brad

    If we get Fred, the component does not work as expected, and returns the first value of results IE. Brad

    I also checked that I get the same behavior in JDev 11.1.1.7

    UsersVOImpl (programmatic view with 1 transitional attribute object)

    import java.sql.ResultSet;
    
    import java.util.ArrayList;
    import java.util.Iterator;
    import java.util.List;
    
    import oracle.adf.share.logging.ADFLogger;
    
    import oracle.jbo.JboException;
    import oracle.jbo.server.ViewObjectImpl;
    import oracle.jbo.server.ViewRowImpl;
    import oracle.jbo.server.ViewRowSetImpl;
    
    // ---------------------------------------------------------------------
    // ---    File generated by Oracle ADF Business Components Design Time.
    // ---    Wed Sep 18 15:59:44 CDT 2013
    // ---    Custom code may be added to this class.
    // ---    Warning: Do not modify method signatures of generated methods.
    // ---------------------------------------------------------------------
    
    public class UsersVOImpl extends ViewObjectImpl {
    
        private static ADFLogger LOGGER = ADFLogger.createADFLogger(UsersVOImpl.class);
        private long hitCount = 0;
    
        /**
         * This is the default constructor (do not remove).
         */
        public UsersVOImpl () {
        }
    
        /**
         * executeQueryForCollection - overridden for custom java data source support.
         */
        protected void executeQueryForCollection (Object qc, Object[] params, int noUserParams) {
    
             List<String> usersList = new ArrayList<String>();
             usersList.add("Brad");
             usersList.add("Adam");
             usersList.add("Aaron");
             usersList.add("Fred");
             usersList.add("Charles");
             usersList.add("Charlie");
             usersList.add("Jimmy");
    
             Iterator usersIterator = usersList.iterator();
             setUserDataForCollection(qc, usersIterator);
             hitCount = usersList.size();
             super.executeQueryForCollection(qc, params, noUserParams);
    
        } // end executeQueryForCollection
    
        /**
         * hasNextForCollection - overridden for custom java data source support.
         */
        protected boolean hasNextForCollection (Object qc) {
    
             Iterator usersListIterator = (Iterator)getUserDataForCollection(qc);
             if (usersListIterator.hasNext()) {
         
                 return true;
    
             } else {
    
                 setFetchCompleteForCollection(qc, true);
                 return false;
    
             } // end if
    
        } // end hasNextForCollection
    
        /**
         * createRowFromResultSet - overridden for custom java data source support.
         */
        protected ViewRowImpl createRowFromResultSet (Object qc, ResultSet resultSet) {
    
             Iterator usersListIterator = (Iterator)getUserDataForCollection(qc);
             String user = (String)usersListIterator.next();
             ViewRowImpl viewRowImpl = createNewRowForCollection(qc);
    
             try {
    
                 populateAttributeForRow(viewRowImpl, 0, user.toString());
    
             } catch (Exception e) {
    
                 LOGGER.severe("Error Initializing Data", e);
                 throw new JboException(e);
    
             } // end try/catch
    
             return viewRowImpl;
    
        } // end createRowFromResultSet
    
        /**
         * getQueryHitCount - overridden for custom java data source support.
         */
        public long getQueryHitCount (ViewRowSetImpl viewRowSet) {
             return hitCount;
        } // end getQueryHitCount
    
        @Override
        protected void create () {
    
             getViewDef().setQuery(null);
             getViewDef().setSelectClause(null);
             setQuery(null);
    
        } // end create
    
        @Override
        protected void releaseUserDataForCollection (Object qc, Object rs) {
    
             Iterator usersListIterator = (Iterator)getUserDataForCollection(qc);
             usersListIterator = null;
             super.releaseUserDataForCollection(qc, rs);
    
        } // end releaseUserDataForCollection
    
    } // end class
    
    

    <af:inputListOfValues id="userName" popupTitle="Search and Select: #{bindings.UserName.hints.label}" value="#{bindings.UserName.inputValue}"
                                                  label="#{bindings.UserName.hints.label}" model="#{bindings.UserName.listOfValuesModel}" required="#{bindings.UserName.hints.mandatory}"
                                                  columns="#{bindings.UserName.hints.displayWidth}" shortDesc="#{bindings.UserName.hints.tooltip}" autoSubmit="true"
                                                  searchDesc="#{bindings.UserName.hints.tooltip}"                                           
                                                  simple="true">
                              <f:validator binding="#{bindings.UserName.validator}"/>                       
    </af:inputListOfValues>
    
    
    
    

    I found a solution to this problem. It seems that, when using a view object programmatic that has a transient as its primary key attribute, you need to override the methods in the ViewObjectImpl so that he knows how to locate the line related to the primary key when the view object records are not in the cache. That's why it would work properly sometimes, but not always. Here are the additional methods that you must override. The logic you use in the retrieveByKey would be on a view view object database object and would be different if you had a primary key consisting of multiple attributes.

    @Override
    protected Row[] retrieveByKey (ViewRowSetImpl viewRowSetImpl, Key key, int i) {
        return retrieveByKey(viewRowSetImpl, null, key, i, false);
    }
    
    @Override
    protected Row[] retrieveByKey (ViewRowSetImpl viewRowSetImpl, String string, Key key, int i, boolean b) {
    
        RowSetIterator usersRowSetIterator = this.createRowSet(null);
        Row[] userRows = usersRowSetIterator.getFilteredRows("UserId", key.getAttribute(this.getAttributeIndexOf("UserId")));
        usersRowSetIterator.closeRowSetIterator();
        return userRows;
    
    }
    
    @Override
    protected Row[] retrieveByKey (ViewRowSetImpl viewRowSetImpl, Key key, int i, boolean b) {
        return retrieveByKey(viewRowSetImpl, null, key, i, b);
    }
    
  • Caching the result of OSB: expiration

    Hello

    Anyone know if it is possible to replace the TTL value (defined at design time) of the result while deploying caching (using the example or WLST customization file?).

    Kind regards

    Mathieu

    or you can create a script ant with xmltask to find/replace the expression directly in your business service file.

    We also use it to add sla during deployment

  • How to display the result of a java class in InputText?

    Hi all
    How can I get the result of the java classes to InputText or OutputText?
    also everyone in the forum can road map me to deal with Java in oracle adf because I am a beginner in oracle adf
    I saw a few samples in corner of oracle adf, but it is difficult for me.

    I use JDeveloper Version 11.1.2.3, technology of the Adf.
    My question is how to return the result of java Bean InputText or OutText
    Thank you

    see if you want to have show some .so beans instance variable value you can have a few bean .define managed a variable as
    string abc = "abc";

    create the getter set for her.

    in the value property of inputText or OutPutText write an el as #{beanscope.managedbeanName.abc}

  • Problems with separation of the results in different lines. Group question?

    Hi all!

    I have a table that looks a bit like this:
    Pallet          Status          Number          Time
    A          MoveIn          48          11:11
    A          Pick          -1          11:11
    A          Pick          -1          11:12
    A          Pick          -1          11:12
    A          MoveOut     45          11:13
    A          MoveIn          45          18:20
    A          Pick          -1          18:23
    A          Pick          -1          18:23
    A          Pick          -1          18:23
    A          Pick          -1          18:24
    A          MoveOut     41          18:25
    A          MoveIn          41          21:31
    A          Pick          -1          21:55
    .....
    It's exploitation forest pallets that is moved to a station and then number of boxes is picked off the coast. (To make it more simple, I only show a palette in above example.)

    I would like to introduce the result with one row for each time that the palette were at the station, as:
    Pallet          Picked          Time
    A          3          11:11
    A          5          18:20
    A          ....          .....
    This means that the same palette can be showned on several lines, as happened to the station several times. I tried several different 'GROUP BY', but I can't get it to work.
    For example, I tried to group by time, but this fails if a pallet is moved twice per hour or if the boxes are picket at different times (for example, first box picked 09:59, last box 10:01)

    Anyone has a suggestion how to fix this problem?

    Thanks in advance and greetings / Anders from Sweden

    Hej, Anders,

    Can you explain what defines a group?

    Looks like you say that a group is a subset of a palette. If we organize all the lines for a palette in the order of time, a new group starts whenever we have a line where status = 'MoveIn. In other words, a group consists of a line with status = "MoveIn" and all the lines immediately after, in order by time, up to, but not including, the next row with status =-"MoveIn. Is this fair?

    If so, you can use the function COUNT (or SUM) Analytics to see how many lines with status = "MoveIn" have already taken place, in order by time, like this:

    WITH     got_grp          AS
    (
         SELECT     pallet, status, time
         ,     COUNT ( CASE
                             WHEN  status = 'MoveIn'
                       THEN  1
                         END
                    ) OVER ( PARTITION BY  pallet
                                ORDER BY          time
                        )           AS grp
         FROM    table_x
    )
    SELECT       pallet
    ,       COUNT ( CASE
                      WHEN  status = 'Pick'
                    THEN  1
                  END
                )          AS picked
    ,       MIN (time)          AS start_time
    FROM       got_grp
    GROUP BY  pallet
    ,            grp
    ORDER BY  pallet
    ,            grp
    ;
    

    If you would care to post CREATE TABLE and INSERT statements for your sample data, and then I could test this.

    This assumes that the combination (palette, time) is unique. Your sample data includes:

    Pallet          Status          Number          Time
    A          MoveIn          48          11:11
    A          Pick          -1          11:11
    

    I suppose that you decide to simply not show the full time, and your data is really something like:

    Pallet          Status          Number          Time
    A          MoveIn          48          23-Sep-2011 11:11:01
    A          Pick          -1          23-Sep-2011 11:11:08
    

    Otherwise, how do you know if these two lines are in you the same group or not? You may need to add a break to the analytical ORDER BY clause. For example, if you say "ORDER BY time, * status *", then, if the above two lines really have exactly the same time, to the second, then one with status = "MoveIn" would be considered as prior to the line with status = 'Choose'. "

  • Search criteria in a page, the results of the query in another page?

    Hi, can I search criteria in a page and get query results in another page?

    Need help

    Thanks in advance

    Karman

    Hello

    Yes you can.
    Create the page corresponding to your article (s) where user define the search criteria.
    Create another page is where your first report and use in where clause page elements.

    Then, on the first page create button submit the page and creates a branch to the second page where is your report.

    Kind regards
    Jari

  • get the result without Union all the

    < pre >
    WITH GET_BALANCE AS
    (SELECT "CREDIT2' AS TYPE, - 6336.37 AS A AMOUNT OF DOUBLE
    Union of all the
    SELECT 'CREDIT', 8340.52 OF THE DOUBLE
    Union of all the
    SELECT 'CREDIT', THE DOUBLE 609.48
    Union of all the
    SELECT 'CREDIT', 50 OF THE DOUBLE
    Union of all the
    SELECT 'CREDIT', 6336.37 OF THE DOUBLE
    Union of all the
    Select "DEBIT", 628.68 DUAL FROM
    Union of all the
    Select "DEBITORG", 9000 DUAL FROM
    Union of all the
    SELECT 'DEBIT1', DOUBLE 50,81
    Union of all the
    SELECT 'DEBIT2',-679.49 OF THE DOUBLE
    UNION ALL
    SELECT 'DEBIT1', THE DOUBLE 679.49
    UNION ALL
    SELECT 'DEBIT2',-679.49 OF THE DOUBLE
    )

    SELECT sum (debit) debit, sum (credit) in the form of credit, (sum (debit) - sum (credit)) such as (FROM) balance
    SELECT FLAT CREDIT, DEBIT GET_BALANCE 0
    WHERE TO TYPE LIKE 'CREDIT %'
    UNION ALL
    SELECT 0 CREDIT, DEBIT GET_BALANCE PLATE
    WHERE TO TYPE LIKE' FLOW %')

    I got the result;
    credit debit balance
    9000 9000 0
    < / pre >
    But,
    I want to get the result without union all.
    I try sum on the partition by, or group by type...
    can not get the result. you would tell me the other way to get above result

    Thank you

    Published by: Jimmie_M on October 4, 2010 14:59

    Published by: Jimmie_M on October 4, 2010 15:01

    Hello

    Here's one way:

    WITH   got_credit_and_debit     AS
    (
         SELECT     SUM ( CASE
                     WHEN  SUBSTR (type, 1, 6) = 'CREDIT'
                         THEN  amount
                    END
                  )     AS credit
         ,     SUM ( CASE
                        WHEN  SUBSTR (type, 1, 5) = 'DEBIT'
                         THEN  amount
                    END
                  )     AS debit
         FROM    get_balance
    )
    SELECT     credit
    ,     debit
    ,     debit - credit     AS balance
    FROM     got_credit_and_debit
    ;
    

    What type of application is as follows, where the balance is defined as the debit - credit? Usually, it's the opposite: balance = credit - debit.

    You don't absolutely need a subquery:

    SELECT     SUM ( CASE
                WHEN  SUBSTR (type, 1, 6) = 'CREDIT'
                    THEN  amount
               END
             )     AS credit
    ,     SUM ( CASE
                   WHEN  SUBSTR (type, 1, 5) = 'DEBIT'
                    THEN  amount
               END
             )     AS debit
    ,     SUM ( CASE
                WHEN  SUBSTR (type, 1, 6) = 'CREDIT'
                THEN  amount
                   WHEN  SUBSTR (type, 1, 5) = 'DEBIT'
                    THEN  -amount
               END
             )     AS balance
    FROM    get_balance
    

    Published by: Frank Kulash, October 4, 2010 18:15
    Added query replacing without subquery

Maybe you are looking for