Dropdown editable in a table based on a condition

Hi,
I would like to know how to solve these problems.
1. I have a cell (of the type dropdown by key) in a table, which is editable or not, depending on a condition ? Is this is possible? Please let me know if there is a sample code
2. So basically I have a  table that has 2 entries in it, user details and one of the fields in FLAG showing the values Yand N for the user. I want the table in the webdynpro application to show the 2 user entries and then in the Flag column have a DROPDOWNBYKEY that DEFAULTS to showing what flag the user has, but also allows the user to CHANGE the entry.
Thanks in advance
I appreciate for the help.

is possible
In your Context node which is binded to the table as DataSource, add an attribute WDY_BOOLEAN type
In layout bind the newly created attribute to the dropdown UI element Enable property
while filling your context node, fill the attribute with abap_true and abap_false based on your condition
Abhi

Similar Messages

  • How to make a table column block editable for a row and remain non editable for other row based on some condition

    hi ,
    i need help on the below scenario ,
    we have a web dynpro table with different columns, now based on new business requirement  one of the column need to     
    dynamically editable or non editable for different row.
    for ex :
    Field 1
    Field 2 ( Dynamic field )
    Field 3
    Field 4
    Data 11
    Data 12 ( Editable with Drop down   )
    data 13
    data 14
    Data 21
    Data 22 ( Non editable )
    Data 23
    data 24
    Data 31
    data  32 ( Editable with drop down )
    data 33
    data 34
    how to achieve this ? please help on this.
    Thanks in advance
    Thanks
    Manish

    Manish,
    there is no proper way to insert two Cell Editors in a column(except variants), have a look on below scenario, it may help.
    add one more attribute to your table context node for read-only.
    create dropDown as celleditor for table and bind with newly created attribute to read-only property of dropdown.
    before binding data to table, check the condition then mention readonly value abap_true / false.
    @ we can achieve by the use of Variants.
    for ex :
    Data 11
    Data 12 ( Editable with Drop down)
    data 13
    read-only - abap_false
    Data 21
    Data 22 ( Non editable, dropdown )
    Data 23
    read-only - abap_true
    Data 31
    data  32 ( Editable with drop down )
    data 33
    read-only - abap_false

  • Show or Hide empty table based on If condition

    I want to show or hide empty table based on condition. The table will be empty with 5 rows,2 cols and should display if <?Rout_Information1_id1?> is blank or null or when XML field is not present. Actually the JDEdwards report will generate XML file. In the XML file if <?Rout_Information1_id1?> is present it will have definitely value like 'PULL' or 'Cut' otherwise sometimes XML field itself will not be present. Need to display the empty table when the <?Rout_Information1_id1?> is not present. I am trying to do as below but the table is not displayed. Can someone tell me how to resolve this.
    <?if:Rout_Information1_id1=' '?>
    5 rows,2 cols table
    <?end if?>
    Thanks,
    Vijay Vattiprolu

    Ok. I used the below syntax from other post and it resolved displaying empty table issue.
    <?if:not(XML_TAG_NAME)?>
    <?end if?>
    Thanks,
    Vijay

  • Selecting a value to a column from a different table based on a condition

    I apologize for the confusing title.
    I have to select values from Table_1. 2 of those columns needs to be checked for values in Table_2 based on the ID and if values are present, then those values should be taken, if not the values from Table_1 should be taken. How can I achieve this?
    e.g.
    table_1
    date
    id
    fact1
    fact2
    type
    table_2
    id
    fact1
    fact2
    select date,id,type, (Need to check the condition for fact1 and fact 2, if present in table_2, then that value should be used, if not table_1 values should be used) from table_1 and table_2.
    I need to use this condition in another big query. Any help/suggestions appreciated.
    Thanks.

    Thanks Tubby,
    It worked and I incorporated with the master query too.
    Thanks a lot.
    EDIT
    Thanks for all the replies> I just saw your answers after I finished and posted the reply.
    hoek, I am not a DB person, I used to write some SQLs, but not in the last 3 years or so. I am trying to work on some reports, hence some trivial questions.
    Edited by: vj on Aug 7, 2010 5:48 PM

  • Insert into a final table based on a condition

    Hi,
    create table table1(invoice_number varchar2(4), covg_date date, employee_number varchar2(5),
    service_option varchar2(2), FEES VARCHAR2(5), AMOUNT NUMBER(9,2));
    insert into table1 values('1','01-JUL-2011','11','8','F1,F2',100);
    insert into table1 values('2','01-JUL-2011','12','2','F1,F2',110);
    insert into table1 values('3','01-JUL-2011','13','9','F1,F2',120);
    insert into table1 values('4','01-JUL-2011','14','3','F1,F2',130);
    commit;
    create table table2(invoice_number varchar2(4), covg_date date, employee_number varchar2(5),
    service_option varchar2(2),FEES VARCHAR2(5), AMOUNT NUMBER(9,2));
    insert into table2 values('1','01-JUL-2011','11','88','F1,F2',100);
    insert into table2 values('2','01-JUL-2011','12','2','F1,F2',110);
    insert into table2 values('3','01-JUL-2011','13','9','F1,F2',122);
    insert into table2 values('4','01-JUL-2011','14','3','F1',130);
    insert into table2 values('4','01-JUL-2011','15','3','F1',130);
    commit;
    create table final_table(insert_type varchar2(1),invoice_number varchar2(4), covg_date date, employee_number varchar2(5),
    service_option varchar2(2),FEES VARCHAR2(5), AMOUNT NUMBER(9,2));we need to insert into final_table based on the differences between table1 and table2. The condition for that is:
    Eg: For a given employee number(11) for a given covg_date(July-2011), if there is at least one difference in any column value which in this case is the service_option (8,88)..
    i need to insert table1 record into final_table with insert_type as 'OLD'
    and insert table2 record into final_table with insert_type as 'NEW'
    Similarly employee number 14, there is a difference between fees column and i should insert them like the above example
    Similarly employee number 13, there is a difference between AMOUNT column and i should insert them like the above example.
    For example employee number 15, there is no record in table1 but exists in table2 and that will be inserted as it is..
    What my idea was to loop through distinct employee_number, covg_date in table1 and check each value in table2 for the same condition and insert into final_table..
    But if there is a better option like inserting directly using select clause or some sort of direct insert without loop...
    Thanks for the help in advance

    Possibly a modified version of something like this:
    INSERT INTO final_table
    ( insert_type
    , invoice_number
    , covg_date
    , employee_number
    , service_option
    , fees
    , amount
    SELECT insert_type
         , invoice_number
         , covg_date
         , employee_number
         , service_option
         , fees
         , amount
    FROM   (
         SELECT invoice_number
              , covg_date
              , employee_number
              , service_option
              , fees
              , amount
              , 'OLD' AS insert_type
         FROM   table1
         MINUS
         SELECT invoice_number
              , covg_date
              , employee_number
              , service_option
              , fees
              , amount
              , 'OLD' AS insert_type
         FROM   table2
         UNION ALL
         SELECT invoice_number
              , covg_date
              , employee_number
              , service_option
              , fees
              , amount
              , 'NEW' AS insert_type
         FROM   table2
         MINUS
         SELECT invoice_number
              , covg_date
              , employee_number
              , service_option
              , fees
              , amount
              , 'NEW' AS insert_type
         FROM   table1
    WHERE  employee_number = :emp_number
    AND    covg_date       = TO_DATE(:date_string,'MM/DD/YYYY')
    ;

  • Insert data in same table based on some condition

    Hi. I am new to this forum.
    I have to write a stored procedure to Insert Data into a table say MYTABLE ,having structure as:
    Col1 Col2 Col3 ................ TotalInstallments CurrentInstallment PaidAmount MonthYear
    I have to insert all the data as it is in the same table(MYTABLE) except changing some fields on basis of some conditions:
    1. if PaidAmount>0 && CurrentInstallment<TotalInstallment then
    CurrentInstallment=CurrentInstallment+1
    2. In the MonthYear field I am having data in formate(month/year)ex. 01/2012, 11/2012 ....
    So I have to insert data by incrementing month and year. for example:
    if currentdata is 11/2012 then next data will be 12/2012
    But next will be 01/2013
    I have to select all the records which belongs to previous month(through MonthYear field ) and put checking & changes on each record of the selected data and then insert them into same table(MYTABLE).
    How to achive that?
    Thanks.

    978184 wrote:
    Every thing is working fine but some strange result as:
    when i run my Procedure TRANSFERDATATONEXTMONTH
    1. by Passing Value as : CUSTOMERID_var ='ABX101' and MONTHYEAR_var='12/2012' it insurts 5 rows
    which is correct , since I have 5 records where CUSTOMERID='ABX101' and MONTHYEAR='12/2012' and
    new 5 rows has CUSTOMERID='ABX101' and MONTHYEAR='01/2013' (all other values are as expected)
    2. now when i again run by passing values: CUSTOMERID='ABX101' and MONTHYEAR='01/2013' it inserts 10 records(just double )
    and new records has value CUSTOMERID='ABX101' and MONTHYEAR='02/2013' (while on the basis of condition CUSTOMERID='ABX101' and MONTHYEAR='01/2013' i have in my table only 5 records)
    and all records are duplicate. Some times it inserts three times , while on condition basis it should no. What is happening?Probably, meanwhile you were trying to Insert the First time and the second time, someone did run the procedure that Inserted 5 More records for 01/2013. And, hence your Second run inserted 10 records instead of 5.
    >
    Why it is inserting double of records while i have only 5 records on given condition? Am I missing some thing?Yes, you are. You are missing your Tables, Your Dummy/Sample Data, Working Procedure/Function that can be replicated.
    Without this, we cannot simply believe on assertions that Oracle is behaving incorrectly.
    In addition to this, the GetMonthYear function, should be scrapped. It is un-necessary, when the same logic can be achieved using Oracle ADD_MONTHS function (See my previous post). And you are storing the MonthYear in a Varchar field, which ideally should be a Date field. This eradicates the un-wanted need to cast from VARCHAR - DATE - VARCHAR.
    Please do make some time to read {message:id=9360002} and mentioned relevant details.
    And notice, the code difference in my previous post and in your code.
    Please use
    {noformat}
    (exactly as shown) above and below your code, that indents the code properly for better readability.
    {noformat}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Moving records to a table based on a condition...

    Hello experts,
    Here is the problem.
    1. select all records from table ztm0019 and put it in internal table t_ztm0019_tmp.
    2. sort t_ztm_acc_variance by sernr(serial no), datum in descending order and uzeit also in descending order.
    3. now loop t_ztm_acc_variance and at every new sernr, check whether its bwart is either 702, 708, 712, 718. Now if it is, move all of it(of the same serial no) into another table named t_ztm0019_tmp but if its bwart is not equal to the bwarts above then leave the first record and move all the remaining(with same serial no) in t_ztm0019. And then all the records that satisfied the condition must be deleted from the source table which is ztm0019.
    4. all the records of t_ztm0019_tmp would now be inserted to table ztm_acc_variance.
    example:
         SERNR        BWART
       123456         702
       123456         701
       123456         708
       123456         707
       222222         702
       222222         701
    So at every new sernr in the loop it must check whether the bwart is either 702, 708, 712, 718. If it is, then move all of the records with same sernr(123456) and so on. but if it is like this:
        SERNR        BWART
       123456         701
       123456         702
       123456         701
       123456         718
    the first record should be retained and the 2nd to last record(of the same sernr) must be moved.
    Help would really be appreciated. Thank you very much guys!

    1.
    DATA  t_ztm0019_tmp LIKE TABLE OF ztm0019 WITH HEADER LINE.
    SELECT *
    FROM ztm0019
    INTO TABLE t_ztm0019_tmp.
    2.
    SORT t_ztm_acc_variance BY <b>sernr ascending datum uzeit descending.</b>
    3.
    <b>DATA is_new TYPE i.</b>LOOP AT t_ztm_acc_variance.
    AT NEW sernr.
    IF bwart EQ '702' OR
       bwart EQ '708' OR
       bwart EQ '712' OR
       bwart EQ '718'.
    is_new = 1.
    LOOP AT t_ztm_acc_variance WHERE sernr = t_ztm_acc_variance-sernr.
    IF sy-subrc EQ 0.
    APPEND t_ztm_acc_variance TO t_ztm0019_tmp.
    DELETE t_ztm_acc_variance.
    ENDIF.
    ENDLOOP.
    ENDAT.
    IF is_new EQ 1.
    APPEND t_ztm_acc_variance TO t_ztm0019_tmp.
    DELETE t_ztm_acc_variance.
    ENDIF.
    AT END OF sernr.
    is_new = 0.
    ENDAT.
    ENDLOOP.
    4.
    CLEAR ztm_acc_variance[].
    APPEND LINES OF t_ztm0019_tmp TO ztm_acc_variance.

  • ADF -- Dynamic InlineStyle on cells of table based on specified conditions.

    Hi there!!
    I am trying to figure out Dynamic Inline Style on cells in ADF:
    Need to color a few columns for a particular row (don't wanna color the entire column--just want to color those cells in columns that matches the specified condition for that particular row, in MY CASE:- row: having Col-A ="BBB" column: having value>250 ).
    Col-A Col-B Col-C Col-D
    AAA 100 255 300
    BBB *255* *300* 100
    I want to color the cells in BOLD....
    My basic condition:- Col-A = 'BBB' and other col values >250
    Can anyone help me out with this???

    Hi,
    try as following
    <af:inputText contentStyle=#{row.bindings.Col-A.inputValue eq 'BBB' and (row.bindings.Col-B.inputValue gt 250 or row.bindings.Col-C.inputValue gt 250 or row.bindings.Col-D.inputValue gt 250) ? 'font-weight:bold;':''}"/>
    {code}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Populate a dropdown based on selected in another dropdown in a seperate table

    Good Day All;
    This may sound like a simple question to most, but… It has had me frustrated trying to figure out.
    I am trying to populate a dropdown based on what is selected in another dropdown.
    Let me explain what I have done so far.
    LifeCycle Designer 8.05.2
    When I had both dropdowns in the same table, I did not have a problem. The code I used is
    Table name is “Table1”
    if(directorate.rawValue == "1")
    division.clearItems();
    division.addItem("select")
    I was asked to move things around and now “division” is located in “Table2”
    I know I need to reference “Table1” but I am running into a Syntax error. I have tried the following code;
    if(Table1 Row1 directorate.rawValue == "1")
    division.clearItems();
    division.addItem("Faire un choix")
    if(Table1.Row1.directorate.rawValue == "1")
    division.clearItems();
    division.addItem("Faire un choix")
    Any help would be appreciated
    Chomp

    You're missing a semicolon at the end of the addItem line, and on the second code sample you've got no periods in the SOM reference (Table1 Row1 directorate). 
    The easiest way to get the path to another field is to ctrl-click on the field while you are in the script editor.

  • How to populate data in the same table based on different links/buttons

    Hi
    I'm using jdeveloper 11.1.4. I have a use case in which i need to populate data in the same table based on click of different links.
    Can anyone please suggest how can this be achieved.
    Thanks

    I have a use case in which i need to populate data in the same table based on click of different linksDo you mean that you need to edit existing rows ?
    What format do you have the date in - table / form ?

  • Single row editing for multiple tables in a single page

    Hi!
    I have split a table with many many columns into more tables with a lower number of columns. There is an ID column (sequence generated) that is Primary Key common for all tables. Obviously, the relationship between these tables is 1 to 1, so it’s not about having to build master-detail pages.
    What I need now is to edit all these tables in a single page: one single row from each table. The Automated Row Fetch & Automatic Row Processing (DML) processes used for the old table must be replaced by something else.
    Is there a way to use in a single page more pairs of such processes for more tables?
    I want to avoid manually writing processes with lot of PL/SQL code to handle row fetch & update.
    Keep in mind that the page will have an ID item that can be used to identify unique rows in all my tables.
    Thanks,
    Sorin

    I have split a table with many many columns into more tables with a lower number of columns
    IMHO that is a very bad idea. There is nothing wrong with having many columns in a table. If you would like to split them to better "categorize" them, just create views on the table and expose different subsets of the columns.
    I want to avoid manually writing processes with lot of PL/SQL code to handle row fetch & update.
    That is unavoidable given how you have designed the underlying tables.
    You could try creating a view that joins all the tables by the PK and creating a form based on that view. Then write a INSTEAD OF trigger on the view that "doles out" the DML on the view to each of the underlying tables.

  • Error updating tables based on schema

    Hello,
    I'm trying to update a table based on the next schema:
    <?xml version="1.0" encoding="UTF-8"?>
    <xs:schema xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" attributeFormDefault="unqualified">
         <xs:element name="HILO" xdb:SQLType="HILO_TYPE" xdb:defaultTable="HILO_TABLE">
              <xs:complexType>
                   <xs:sequence>
                        <xs:element name="MENSAJE" maxOccurs="unbounded" xdb:SQLType="MENSAJE_TYPE" xdb:maintainOrder="false">
                             <xs:complexType>
                                  <xs:sequence>
                                       <xs:element name="FECHA" type="xs:date" xdb:SQLType="DATE"/>
                                       <xs:element name="TITULO" xdb:SQLType="VARCHAR2">
                                            <xs:simpleType>
                                                 <xs:restriction base="xs:string">
                                                      <xs:maxLength value="200"/>
                                                 </xs:restriction>
                                            </xs:simpleType>
                                       </xs:element>
                                       <xs:element name="CUERPO" type="xs:string" xdb:SQLType="VARCHAR2"/>
                                       <xs:element name="DNI_CREADO_POR" xdb:SQLType="VARCHAR2">
                                            <xs:simpleType>
                                                 <xs:restriction base="xs:string">
                                                      <xs:maxLength value="9"/>
                                                 </xs:restriction>
                                            </xs:simpleType>
                                       </xs:element>
                                       <xs:element name="ASIGNATURA" xdb:SQLType="VARCHAR2">
                                            <xs:simpleType>
                                                 <xs:restriction base="xs:string">
                                                      <xs:maxLength value="3"/>
                                                 </xs:restriction>
                                            </xs:simpleType>
                                       </xs:element>
    <xs:element name="APROBADO" xdb:SQLType="VARCHAR2">
    <xs:simpleType>
    <xs:restriction base="xs:string">
    <xs:enumeration value="APROBADO"/>
    <xs:enumeration value="RECHAZADO"/>
    <xs:enumeration value="PENDIENTE"/>
    </xs:restriction>
    </xs:simpleType>
                                       </xs:element>
                                  </xs:sequence>
                                  <xs:attribute name="NUMERO" type="xs:int" use="required" xdb:SQLType="INTEGER"/>
                             </xs:complexType>
                        </xs:element>
                   </xs:sequence>
                   <xs:attribute name="CONTADOR" type="xs:int" use="required" xdb:SQLType="INTEGER"/>
              </xs:complexType>
         </xs:element>
    </xs:schema>
    And the update that i'm trying to do is the next one:
    UPDATE hilo_table p
    SET value(p) =
    updatexml(value(p),'/HILO/MENSAJE/CUERPO/text()', 'Edit' )
    where existsnode(VALUE(p), 'HILO[@CONTADOR="1"]') = 1;
    ERROR en línea 1:
    ORA-01732: operación de manipulación de datos no válida en esta vista
    I have updated another tables based on schema and it works fine, any idea?

    OK this is your decision. However If you are building a production system that is important to your orgnanization as the product manager I strongly recommend that you either upgrade to a least 9.2.0.3.0 or discontinue using XML DB technology completely
    There are probably somewhere in the order of 500 serious XML DB related bugs fixed between 9.2.0.1.0 and 9.2.0.7.0, all of which have been regarded as serious enough to impossible for a customer to develop or deploy a production system. None of these will EVER be fixed or available as patches for 9.2.0.1.0.
    The way in which we store the data on the disc is different in 9.2.0.3.0, and while in theory we migrate the on disc format when you upgrade in practice I know that is has never been tested with any significant amount of data present.
    Also you really want to take the support situation into account. Image this, it's 3:00am in the morning and your production system fails due one of the bugs that have been fixed in a later release of the product. You cannot find a workaround and you call oracle support for help. They WILL say, sorry there is nothing we can do until you upgrade to 9.2.0.3.0. Now you have to upgrade in hurry and then re-test everything you have done before you can even start working on a fix.
    From a business perspective staying on 9.2.0.1.0 and continuing to use the XML DB technology makes no sense. I hope I have made this clear. If you want I will be more than happy to discuss this issue with your development managers.

  • CM25: Sort standard table based on custom table.

    Hi Experts,
    I need to sort the CM25 capacity table based on a ZTABLE where we will define the sequence number of each material. So when CM25 is executed the material should get sorted based on sequence number maintained in Ztable. Now the challenge is how to achieve this sorting before we display the capacity table.
    anybody has faced such scenerio please help us.
    There are few user exits available but not able to find out how to achieve the required functionality.
    Regards,
    Raghav
    Edited by: Julius Bussche on Jul 30, 2009 9:29 AM
    In future threads with meaningless subject titles will simply be deleted as you appear to be doing this intentionally

    First, let me say that I have no experience with this CM25 table and where/how it is used or displayed, but here's how I look at it:
    But what is the real problem?
    1. Don't know the user exit / BAdI to be used?
    2. Don't know how to do the sorting?
    3. .....?
    Answer:
    1. This will be a matter of trying I would say and reading the documentation of the exit/BAdI.
    2. You can do dynamic sorting of an internal table (if it is an internal table that is used before displaying it).
    DATA: lv_sort1 TYPE CHAR10 VALUE 'NAME_OF_COLUMN_FROM_ZTABLE',
               lv_sort2 TYPE CHAR10 VALUE 'NAME_OF_OTHER_COLUMN_FROM_ZTABLE'.
    SORT itab BY (lv_sort1) ASCENDING (lv_sort2) DESCENDING.
    Edited by: Micky Oestreich on Jul 30, 2009 7:34 AM

  • Is it possible to find the  table based on the Date ?

    Dear Team ,
    Is it possible to find the table based on the Date ?
    I have created an table ,But forgot the Table Name .
    Is it possible to find the Tables created on particular Date .
    Regards ,
    Augustine

    as date is record the time also below query will work.
    select * from user_objects
    where
    object_type = 'TABLE' and
    to_date(created,'DD-MON-YYYY') =to_date('<your date value in DD-MON-YYYY format>','DD-MON-YYYY');
    Edited by: shaileshM on Feb 24, 2010 9:39 PM

  • Update table based on collection

    Hello friends,
    I have two tables:
    1- PHOTOS (img_id number (5,0),Product_id number (5,0), Content Blob ....)
    2- PRODUCTS (Product_id number (5,0), product_type .... )
    each product has 1 to 6 images.
    I need to watermark the uploaded images in the memory then update the original images for the watermarked images.
    I used this code, but the problem is how to update the images in the photos table based on the product_id ???
    DECLARE
    type source_col is table of blob index by pls_integer ;
    V_source source_col;
    cursor c1 is select CONTENT from photos where Product_id = :P22_Product_id;
    counter number :=1;
    added_image       BLOB;
    prop ordsys.ord_str_list;
      logging VARCHAR2(2000);
    begin
    --- Here we choose a pattern for watermarking from a table called WATERMARK_PHOTOS
    select img INTO added_image FROM WATERMARK_PHOTOS WHERE N = 1;
    for rec in c1 loop
    V_source(counter) := rec.CONTENT;
    ORDSYS.ORDImage.process(V_source(counter), 'fixedScale=900 500');
    ORDSYS.ORDImage.applyWatermark(V_source(counter), added_image, V_source(counter), logging, prop);
    --- The problem in the following statement: How to update the images
    UPDATE photos SET CONTENT = V_source(counter) where Product_id = :P22_Product_id;
    Counter := counter + 1 ;
    end loop;
    COMMIT;
    EXCEPTION
       WHEN OTHERS THEN
       RAISE;
    END;

    Thanks Sybrand,
    I am using Oracle 11g R2 Standard One edition.
    the DDL of the photos table is
    ID     NUMBER     5     0     
    product_id     NUMBER     5     0     
    FILENAME     VARCHAR2     100          
    MIMTYPE     VARCHAR2     250          
    FILESIZE     VARCHAR2     20          
    CONTENT     BLOB          in my application I do not know the image id in advance, but i know the id of the product of which I want to edit the images. So:
    in the following procedure :p22_product_id is the value of of the primary key of Products table.
    I followed your tips, and it worked out. Can you please check and assure that it is OK :
    DECLARE
    type source_col is table of blob index by pls_integer ;
    V_source source_col;
    type id_col is table of number index by pls_integer ;
    V_id id_col;
    added_image       BLOB;
    prop ordsys.ord_str_list;
      logging VARCHAR2(2000);
    begin
    select content bulk collect into V_source from photos where product_id = :p22_product_id order by id ;
    select id bulk collect into V_id from photos where product_id = :p22_product_id order by id ;
    SELECT img INTO added_image FROM timg WHERE N = 1;
    for i in V_source.first .. V_source.last
    loop
    ORDSYS.ORDImage.process(V_source(i), 'fixedScale=900 500');
    ORDSYS.ORDImage.applyWatermark(V_source(i), added_image, V_source(i), logging, prop);
    UPDATE photos SET CONTENT = V_source(i) where id = V_id(i);
    end loop;
    COMMIT;
    EXCEPTION
       WHEN OTHERS THEN
       RAISE;
    END;Best Regards,
    Fateh

Maybe you are looking for