with different same DataBlock where condition

Hello

I use forms 6i and 10g db.

I have a datablock, say product_master, which retrieves columns product_id, product_name and price.

and I have 2 control blocks (2 tables)

what I want is based on list in 2 blocks of different control items, I need to retrieve data from the datablock

say ctrlblk1 has a listitem named 'pdtlst '.
so in this case where condition to be - WHERE the product_id =: pdtlst

and in ctrlblk2 have another element of list "edpdtlst."

where condition will - WHERE the product_id =: edpdtlst

Is this possible?
I found a "WHERE Clause" option in the Palette property of the Datablock.But I want to spend the condition based on the ctrlblock

Pls help

Hello

Changing the block where clause with:

-- numeric column --
 Set_Block_property( 'block_name', DEFAULT_WHERE, 'col1=' || :ctrl.item1 ) ;

-- char column --
 Set_Block_property( 'block_name', DEFAULT_WHERE, 'col1=''' || :ctrl.item1 || '''') ;

François

Tags: Oracle Development

Similar Questions

  • How to include a page with different orientation under certain conditions?

    Hi experts,


    I use BI Publisher included on EBS 12.2.4, and I need to print an invoice and conditionally add a page with a different orientation (portrait, rest pages are landscape).

    The condition is if TRX_TYPE = "ND".


    I realized to break the page (with a change of section) and call an auxiliary template (named cartaDevolucion) with the text on the last page:

    ------- this is ms word section jump (next page)
    <?import:file:///C:/tmp/XXSON_RETURNNOTE_LETTER.rtf?>
    
    <?if:TRX_TYPE='ND'?>
    <?call@cartaDevolucion?><?end call?> 
    <?end if?>
    

    My problem is that if the condition evaluates to false, the last page is strill printed in white.

    Any recommendations?

    Thank you
    Jose.

    Hello

    I solved the problem. I was missing the key word "@section":

    
    

    Thanks a lot for your help Alex. I'll keep your Xpath comment in mind.

    Kind regards

    Jose.

  • can I use 2 Mac Pro, the old and the other from different locations with the same apple ID?

    can I use 2 Mac Pro, the old and the other from different locations with the same apple ID?

    Yes. The only problem that I see if Macs were different countries. The method of payment in the account/ID must be associated with the country where the unit is located and you can only buy Apps from the store of the country where the computers are located

  • How to take a column of duplicate names and fill a different column with the same names, excluding duplicates?

    How to take a column of duplicate names and fill a different column with the same names, excluding duplicates?

    I find easier to use this copy separate Automator Service (download Dropbox).

    To install in your numbers > Services, double-click menu just the package downloaded .workflow and if necessary give permissions in system preferences > security & privacy.

    To use, just:

    1. Select the cells in the column with duplicate names.
    2. Choose separate copy in numbers > Services menu.
    3. Click once in the upper cell where you want the deduplicated values appear.
    4. Command-v to paste.

    SG

  • Mr President, how can I enter two rows at the same time with different default values that only the first line to use see?

    Mr President.

    My worm jdev is 12.2.1

    How to enter two rows at the same time with different default values that only the first line to use see?

    Suppose I have a table with four fields as below

    "DEBIT" VARCHAR2(7) , 
      "DRNAME" VARCHAR2(50),
      "CREDIT" VARCHAR2(7) , 
      "CRNAME" VARCHAR2(50),
    

    Now I want that when I click on a button (create an insert) to create the first line with the default values below

    firstrow.png

    So if I click on the button and then validate the second row with different values is also inserted on commit.

    The value of the second row are like the picture below

    tworows.png

    But the second row should be invisible. It could be achieved by adding vc in the vo.

    The difficult part in my question is therefore, to add the second row with the new default values.

    Because I already added default values in the first row.

    Now how to add second time default values.

    Concerning

    Mr President

    I change the code given by expensive Sameh Nassar and get my results.

    Thanks once again dear Sameh Nassar .

    My code to get my goal is

    First line of code is

        protected void doDML(int operation, TransactionEvent e) {    
    
            if(operation != DML_DELETE)
                 {
                     setAmount(getPurqty().multiply(getUnitpurprice()));
                 } 
    
            if (operation == DML_INSERT )
                       {
                               System.out.println("I am in Insert with vid= " + getVid());
                           insertSecondRowInDatabase(getVid(),getLineitem(),"6010010","SALES TAX PAYABLE",
                            (getPurqty().multiply(getUnitpurprice()).multiply(getStaxrate())).divide(100));      
    
                           }
    
            if(operation == DML_UPDATE)
                              {                                                    
    
                                 System.out.println("I am in Update with vid= " + getVid());
                             updateSecondRowInDatabase(getVid(),
                                 (getPurqty().multiply(getUnitpurprice()).multiply(getStaxrate())).divide(100));      
    
                              }                      
    
            super.doDML(operation, e);
        }
        private void insertSecondRowInDatabase(Object value1, Object value2, Object value3, Object value4, Object value5)
                  {
                    PreparedStatement stat = null;
                    try
                    {
                      String sql = "Insert into vdet (VID,LINEITEM,DEBIT,DRNAME,AMOUNT) values " +
                 "('" + value1 + "','" + value2 + "','" + value3 + "','" + value4 + "','" + value5 + "')";  
    
                      stat = getDBTransaction().createPreparedStatement(sql, 1);
                      stat.executeUpdate();
                    }
                    catch (Exception e)
                    {
                      e.printStackTrace();
                    }
                    finally
                    {
                      try
                      {
                        stat.close();
                      }
                      catch (Exception e)
                      {
                        e.printStackTrace();
                      }
                    }
                  }  
    
                  private void updateSecondRowInDatabase(Object value1, Object value5)
                  {
                    PreparedStatement stat = null;
                    try
                    {
                      String sql = "update vdet set  AMOUNT='"+ value5+"' where VID='" + value1 + "'";                     
    
                      stat = getDBTransaction().createPreparedStatement(sql, 1);  
    
                      stat.executeUpdate();
                    }
                    catch (Exception e)
                    {
                      e.printStackTrace();
                    }
                    finally
                    {
                      try
                      {
                        stat.close();
                      }
                      catch (Exception e)
                      {
                        e.printStackTrace();
                      }
                    }                  
    
                  }
    

    Second line code is inside a bean method

        public void addNewPurchaseVoucher(ActionEvent actionEvent) {
            // Add event code here...
    
            BindingContainer bindings = BindingContext.getCurrent().getCurrentBindingsEntry();
                   DCIteratorBinding dciter = (DCIteratorBinding) bindings.get("VoucherView1Iterator");
                   RowSetIterator rsi = dciter.getRowSetIterator();
                   Row lastRow = rsi.last();
                   int lastRowIndex = rsi.getRangeIndexOf(lastRow);
                   Row newRow = rsi.createRow();
                   newRow.setNewRowState(Row.STATUS_NEW);
                   rsi.insertRowAtRangeIndex(lastRowIndex +1, newRow);
                   rsi.setCurrentRow(newRow);
    
                   BindingContainer bindings1 = BindingContext.getCurrent().getCurrentBindingsEntry();
                   DCIteratorBinding dciter1 = (DCIteratorBinding) bindings1.get("VdetView1Iterator");
                   RowSetIterator rsi1 = dciter1.getRowSetIterator();
                   Row lastRow1 = rsi1.last();
                   int lastRowIndex1 = rsi1.getRangeIndexOf(lastRow1);
                   Row newRow1 = rsi1.createRow();
                   newRow1.setNewRowState(Row.STATUS_NEW);
                   rsi1.insertRowAtRangeIndex(lastRowIndex1 +1, newRow1);
                   rsi1.setCurrentRow(newRow1);
        }
    

    And final saveUpdate method is

        public void saveUpdateButton(ActionEvent actionEvent) {
            // Add event code here...
    
            BindingContainer bindingsBC = BindingContext.getCurrent().getCurrentBindingsEntry();      
    
                   OperationBinding commit = bindingsBC.getOperationBinding("Commit");
                   commit.execute(); 
    
            OperationBinding operationBinding = BindingContext.getCurrent().getCurrentBindingsEntry().getOperationBinding("Commit");
            operationBinding.execute();
            DCIteratorBinding iter = (DCIteratorBinding) BindingContext.getCurrent().getCurrentBindingsEntry().get("VdetView1Iterator");// write iterator name from pageDef.
            iter.getViewObject().executeQuery();  
    
        }
    

    Thanks for all the cooperation to obtain the desired results.

    Concerning

  • v$ session - request of exact same different results when it is run with the same user on the same database with the same client application on 2 different PC

    Hello

    Oracle 11.2.0.3

    We have a strange situation - using the pl/sql developer and a pc gui tool when query present at the session of $ v session INACTIVE for a sid given - also on sqlplus for INACTIVE same sid but on

    Another exact same request of pc shows as ACTIVE.

    What happens repeatedly with different sid.

    I thought session $ v must show the same SID as active or inactive desktop client as a database table.

    Someone at - he seen this before?

    Thank you

    When you ask anything about the database, your session will be activated as it does 'something' on the database. For example, when the user queries:

    select status from v$session where osuser = 'HIMSELF_USERNAME';
    

    It questions its own session which is 'something' on the database. So, just try it, run a query on the database using your own username as this, you will have the same results. There is no error on the data dictionary, please stop trying to think that it is a bug.

    Kind regards.

  • VRA unable to create groups of companies with the same name in different tenants with vRO

    vRA 6.2.2 Build - 2754020

    vRO 6.0.1

    Through the vRA GUI I can create groups of companies with the same names in different tenants as follows:

    Tenant1: BusGroup1, BusGroup2, BusGroup3

    Tenant2: BusGroup1, BusGroup2, BusGroup3


    However, to create business groups with the same names in different tenants via the vRO, specifically the workflow plugin Library / vCloud Automation Center / Administration / Business groups / create a group of companies, fails in the second tenant with the below error:


    [42106] the specified condition is not respected for 'name '. (Name of the dynamic Script Module: createBusinessGroup #12)

    If I change the naming convention to be different by tenant, then I have no problem. I thought it might be a restriction in the product, but as said I was able to create with the names of same origin through the user interface.

    Anyone experience the same thing?

    This is a known problem within IaaS API the plugin vRO uses to manage groups of companies through business groups workflows. You don't have the same problem of the vRA UI because the user interface (according to the 6.x) does not use the same API IaaS to manage groups of companies.

    The only alternative to 6.x for now is to directly use the helper generic entity Manager plug-in itself. You can take a look at the first example in example CRUD Infrastructure tasks management Scripts.

    I hope it helps.

    Sergio

  • Both adf shares VO even with different params on the same screen

    Hello everyone,
    My current problem is that I need to create a screen with several sharing the same VO graphics but with different settings for each of them.
    Lets assume I want to use EmployeesVO to show the 2 graphs on the same page jspx.
    A chart will display all the salaries of employees for the "Marketing" Department and the other will show all the salaries of employees for the Department 'IT '.
    Remember, I want them both on the same screen.
    The read-only VO will look like this:
    SELECT First_Name
    Salary
    Employees
    WHERE department_id =: p_dept

    To do this, I did the following:
    For each graph, I created an iterator.
    For each iterator I created an ExecuteWithParams. (a receiver "Depto Marketing" and anther receive "IL Depto")
    For each ExecuteWithParams, I created an InvokeAction.

    When executing the application all the graphs show the same information. All of them show only one (the last in the list of executables InvokeAction) Department.

    The question is: how to keep each graph has their own parameter on the same screen?

    I use Windows 7 x 64 SP1 JDeveloper 11.1.2.1.

    Thanks in advance!

    Why not add 2 instances of the same original version of AM. For each instance of defined the different VC.

  • Combine data sources with different granularity in the same fact table?

    I have two operating tables 'Incident (157 columns)' and 'unit (70 Colums) '. For all the "incidents" happening there could be one or more records in the table of the 'unit '.

    As part of my design of data mart, I have merged the tables in one "makes the incident (227 columns)" and insert records from two tables with a join condition between them [incident. IN_NUM = Unit.IN_NUM].

    Is this correct, is my question? or am I mix data sources with different granularity in the same fact table. Appreciate your help.

    Best regards
    Bees

    Bees,
    Are the measures of the 'Incident', repeated during an incident given, in more than one record in the table of the unit? If so, then the sum (indicent.measure) will give an incorrect result?

    What is there to merge physically tables set outside OBIEE? With OBIEE you might have a table of 'facts' logic to present the user with report, which from tables separated units and Incidents and would stop the occurrence of incorrect aggregations. A common piece of modeling in the same way would be arrested in OBIEE headers and lines of command, quite common to have a logical fact 'orders' which contained the two header orders and order line, this translates into the Incidents-> relationship of units.

    To do what I mentioned, is relatively simple, you need a "Dim - Incident" at two levels, unit, mapp and Incident unique identifiers as keys to level and then use these levels to define the content of the levels correctly in your 2 tables logic sources logic "done", IE the LTS Incidents at incident level LTS units as level of units.

    Hope this helps, let us know if you get stuck.
    See you soon
    Alastair

  • Columns with the same name but different data or precision length.

    DB version: 10 gr 2

    In a diagram, I need to find all of the columns with the same name but different or precision data length (if the column is of type number). I know I have to use the USER_TAB_COLS view for this. But I need to find a logic to compare the names of columns and its lengths.

    something like

    select t1.table_name
         , t1.column_name
         , t1.data_type
         , t1.data_length
         , t2.table_name
         , t2.column_name
         , t2.data_type
         , t2.data_length
      from user_tab_columns t1
         , user_tab_columns t2
     where t1.table_name != t2.table_name
       and t1.column_name = t2.column_name
       and t1.data_type = t2.data_type
       and t1.data_length != t2.data_length
    

    ... could be a starting point.

  • My camera has reached 9999 photos and started renumbering 0001 but in a different folder.  If I import new photos in iPhoto, the older photos with the same numbers are overwritten?

    My camera is renumbering pictures from 0001, but a new camera case.  If I import new photos in iPhoto, they replace the old photos with the same numbers?  The camera knows that they are in a different folder, but what happens when I import into iPhoto?

    iPHoto manages very well duplicate file names - each import is in another folder in the database - no problem

    LN

  • where to save the files under options the file name is duplicated how to remove an additional folder with the same name

    Under Options in Firefox, I clicked on save the files under downloads, but the file name twice and an additional file with the same name is created in the folder, i.e.:

    G:\Akbar's Songs\HAMARA DOWNLOADS\HAMARA FORUMS DOWNLOADS FORUMS

    As you can see the file repeats, how can I fix it?

    Also the music files, I download from a site of downloads as a WinRar file and I need to open it. Y at - it an option where the file opens automatically in the folder I chose?

    Thanks a lot for your help.

    Hi Akush, when you install 7 - zip, make itself the default application to open .zip and .rar files. So if you double click on the .rar file, it should open in 7 - zip. If you prefer to decompress immediately, right click the file and look for new 7 - zip items in the menu. I can't think of a way to do this automatically, however.

  • I have 2 bookmarks with the same name but different stuff in them. I want to remove one, but pass the contemts remaining bookmark

    I have 2 bookmarks with the same name but different stuff in them. I want to remove one, but pass the contemts remaining bookmark

    This is the first mention you made records. See this - https://support.mozilla.org/en-US/kb/Sorting%20bookmarks#w_rearranging-manually - and move individual bookmarks from one folder to the other folder. You may need to press the Alt key to display the Menu bar and the View menu item.

  • I want to buy an iBook. There are 2 different books with the same name, author, and the book cover. They are different number of pages with different prices. Specifically, all the light that we do not see. " How do you know that we purchase?

    I want to buy an iBook. There are 2 different books with the same name, author, and the book cover. They are different number of pages with different prices. Specifically, all the light that we do not see. " How do you know that we purchase?

    I would get one that has 4700 comments already.

  • text messages sent with an email address from a touch ipod duplicated on a second ipod touch using a different email address, but the two ipods are controlled by a parent with the same apple ID and password.

    Text messages sent with an email address from a touch ipod duplicated on a second ipod touch using a different email address, but the two ipods are controlled by a parent with the same apple ID and password.  This has happened recently.  My two girls have used their respective ipods and texting, without their messages of duplication for each of the other ipods for more than a year.  Somehow recently, both addresses seem to be synced with them or something, so that both see each and other messages.  I've recently updated two ipods, iTunes on my computer--not the cloud and added music for two ipods, but has not changed anything by email email settings or message I know.  Help, please!

    Welcome to the Apple community.

    I can't fully follow how you have everything set up, but a glance at the settings > messages > send & receive

Maybe you are looking for

  • Calendar is the name of the month showing

    This is a new, just started my laptop this morning and the menu bar showed M10 5 sea, which is also how it looks in the calendar. All other months are the same (M01, M02, etc.). Tried resetting the PRAM, but can't see any prefs calendar that I needed

  • cannot connect with facebook on other sites (firfox 27.0) (rafflecopter, buttons, etc.)

    Facebook will not link properly. For example, shows Rafflecopter NEVER the journal Facebook option. Other sites Web will not bind the 'Like' button never has. It started as soon as I upgraded to v 27; other browsers work fine. Even Facebook pages don

  • Firefox hangs at startup; not extensions, any new profile

    Even after a clean installation (removal of all extensions/plug-ins and previous profile settings), 7.0.1 Firefox still does not work in accordance with its normal operating characteristics. Immediately after double-clicking on the icon, the Crash Re

  • HP DC 7900 CMT: Memory HP

    Hello! I decided to upgrade memory on my computer and I'm confused by what's seen here: https://h10057.www1.HP.com/ecomcat/hpcatalog/specs/provisioner/05/KP719AV_link.htm This (VH640AA) memory is compatible with my computer?

  • Tektronix osciloscopio THS

    Hola I have a tektronix THS 710, he descargado los osciloscopio drivers. Quiero comunicar con el osciloscopio, worm onda in labview there get values of los puntos dicha funcion. Just start has used LV y me gustaria me ayudarais Gracias