Sunday, September 9, 2012

Dependent LOV(List of Values) in Oracle Web ADI with steps and source code

Hello,

Achieving Dependent LOV in Oracle Web ADI is quite tedious task. But don't worry, I am sharing the steps to create one.

You must know basics of Oracle Web-ADI before trying below steps.

Dependent LOV in Oracle Web ADI is created by writing 3 Java Classes as,
1)SQL Class
2)Validator Class
3)Component Class
The Java Source Code of these classes is present below,


Scenario-
Consider we have two columns in Web-ADI,
1)Supplier
2)Supplier Site

We want to show only Supplier Sites of selected Supplier, i.e., we want to filter Supplier Sites as per the Supplier selection.

We will create Supplier as static LOV.We can also create Supplier as static pop-list.

The steps are as below,
(1)Create Web-ADI containing Supplier and Supplier Site as plain enterable columns, i.e., on which LOV is not set yet.

(2)Create Static LOV (Table LOV) for Supplier using following API,
begin
BNE_INTEGRATOR_UTILS.CREATE_TABLE_LOV
 (P_APPLICATION_ID => 200,
 P_INTERFACE_CODE => 'GENERAL_1_INTF', --BNE_INTERFACE_COLS_B.INTERFACE_CODE
 P_INTERFACE_COL_NAME => 'P_SUP', --BNE_INTERFACE_COLS_B.INTERFACE_COL_NAME
 P_ID_COL => 'SEGMENT1',
 P_MEAN_COL => 'VENDOR_NAME',
 P_DESC_COL =>NULL,
 P_TABLE => 'AP_SUPPLIERS',
 P_ADDL_W_C => null,
 P_WINDOW_CAPTION => 'Suppliers',
 P_WINDOW_WIDTH => 400,
 P_WINDOW_HEIGHT => 300,
 P_TABLE_BLOCK_SIZE => 10,
 P_TABLE_SORT_ORDER => 'ascending',
 P_USER_ID => -1
 ,P_TABLE_COLUMNS =>NULL,
 P_TABLE_SELECT_COLUMNS =>NULL,
 P_TABLE_COLUMN_ALIAS   =>NULL,
 P_TABLE_HEADERS        =>NULL,
 P_POPLIST_FLAG         =>'N'
 );
 commit;
 end;

(3)Copy below 3 java files to JAVA_TOP and compile in given order only

a)SagarSupplierSiteNameSQL.java-below is source code


package sagar.oracle.apps.lovtest.sql;

import java.sql.Connection;
import java.sql.SQLException;

import oracle.apps.bne.exception.BneException;
import oracle.apps.bne.framework.BneWebAppsContext;
import oracle.apps.bne.utilities.sql.BneBaseSQL;

public class SagarSupplierSiteNameSQL extends BneBaseSQL {
    public SagarSupplierSiteNameSQL(BneWebAppsContext paramBneWebAppsContext, 
                                    String paramString) throws SQLException, 
                                                               BneException {
        Connection connection = paramBneWebAppsContext.getJDBCConnection();
        StringBuffer stringBuffer = new StringBuffer();

        stringBuffer.append("SELECT ss.vendor_site_code, ss.address_line1 || ',' || ss.city || ',' || ss.state address FROM ap_suppliers s,ap_supplier_sites_all ss WHERE ss.vendor_id = s.vendor_id AND s.vendor_name = :1");


        if ((paramString != null) && (!paramString.trim().equals(""))) {
            stringBuffer.append("AND " + paramString);
        }

        //stringBuffer.append(" ORDER BY VENDOR_SITE_CODE, ADDRESS ");

        setQuery(connection, stringBuffer.toString());
    }
}

b)SagarSupplierSiteNameValidator.java-below is source code


package sagar.oracle.apps.lovtest.validator;


import java.util.Hashtable;

import oracle.apps.bne.exception.BneException;
import oracle.apps.bne.exception.BneFatalException;
import oracle.apps.bne.exception.BneMissingParameterException;
import oracle.apps.bne.framework.BneWebAppsContext;
import oracle.apps.bne.integrator.validators.BneUploadValidator;
import oracle.apps.bne.utilities.sql.BneCompositeSQLCriteria;
import oracle.apps.bne.utilities.sql.BneResultSet;
import oracle.apps.bne.utilities.sql.BneSQLStatement;

import sagar.oracle.apps.lovtest.sql.SagarSupplierSiteNameSQL;

public class SagarSupplierSiteNameValidator extends BneUploadValidator {

    public String[] getDomainParameters() {
        return new String[] { "P_SUP" };
    }

    public BneResultSet getDomainValues(BneWebAppsContext paramBneWebAppsContext, 
                                        Hashtable paramHashtable, 
                                        BneCompositeSQLCriteria paramBneCompositeSQLCriteria) throws BneException {

        SagarSupplierSiteNameSQL sagarSupplierSiteNameSQL = null;
        BneResultSet bneResultSet = null;
        BneSQLStatement bneSQLStatement1 = new BneSQLStatement();

        if (paramBneCompositeSQLCriteria != null) {
            bneSQLStatement1 = 
                    paramBneCompositeSQLCriteria.evaluate(bneSQLStatement1);
        }

        String str1 = (String)paramHashtable.get("P_SUP");

        if (str1 == null) {
            throw new BneMissingParameterException("Supplier Field Error");
        }


        try {
            sagarSupplierSiteNameSQL = 
                    new SagarSupplierSiteNameSQL(paramBneWebAppsContext, 
                                                 bneSQLStatement1.getStatement());
            BneSQLStatement bneSQLStatement2 = 
                new BneSQLStatement(sagarSupplierSiteNameSQL.getQuery(), 
                                    new Object[] { str1 });

            bneSQLStatement2.append("", bneSQLStatement1.getBindValues());
            bneResultSet = 
                    sagarSupplierSiteNameSQL.getBneResultSet(bneSQLStatement2.getBindValuesAsArray());
        } catch (Exception exception) {
            throw new BneFatalException(exception.toString());
        }


        return bneResultSet;
    }


}




(c)SagarSupplierSiteNameComponent.java-below is source code


package sagar.oracle.apps.lovtest.component;


import java.sql.ResultSetMetaData;
import java.sql.SQLException;

import java.util.Hashtable;
import java.util.Vector;

import oracle.apps.bne.exception.BneException;
import oracle.apps.bne.exception.BneMissingParameterException;
import oracle.apps.bne.exception.BneParameterException;
import oracle.apps.bne.exception.BneSQLException;
import oracle.apps.bne.framework.BneBajaContext;
import oracle.apps.bne.framework.BneBajaPage;
import oracle.apps.bne.framework.BneWebAppsContext;
import oracle.apps.bne.integrator.component.BneAbstractListOfValues;
import oracle.apps.bne.parameter.BneParameter;
import oracle.apps.bne.repository.BneResourceString;
import oracle.apps.bne.utilities.BneUIXUtils;
import oracle.apps.bne.utilities.sql.BneCompositeSQLCriteria;
import oracle.apps.bne.utilities.sql.BneResultSet;
import oracle.apps.bne.utilities.sql.BneSimpleSQLCriteria;
import oracle.apps.bne.webui.control.BneLOVControlBean;

import sagar.oracle.apps.lovtest.validator.SagarSupplierSiteNameValidator;

import oracle.cabo.servlet.Page;
import oracle.cabo.servlet.event.PageEvent;
import oracle.cabo.ui.data.DictionaryData;

public class SagarSupplierSiteNameComponent extends BneAbstractListOfValues {

    private SagarSupplierSiteNameValidator VALIDATOR = null;
    private String[] VALIDATOR_PARAMS = null;

    private String FILTERFIELD = null;
    private String FILTERVALUE = null;

    public String getLOVProcessorType() {
        return "TABLE";
    }

    public void init(BneBajaContext paramBneBajaContext, Page paramPage, 
                     PageEvent paramPageEvent) {
        if (VALIDATOR == null) {
            VALIDATOR = new SagarSupplierSiteNameValidator();
            VALIDATOR_PARAMS = VALIDATOR.getDomainParameters();
        }
    }

    public BneBajaPage handleListOfValues(BneBajaContext paramBneBajaContext, 
                                          Page paramPage, 
                                          PageEvent paramPageEvent, 
                                          BneLOVControlBean paramBneLOVControlBean) throws BneException {
        BneWebAppsContext bneWebAppsContext = 
            paramBneBajaContext.getBneWebAppsContext();
        BneCompositeSQLCriteria bneCompositeSQLCriteria = null;
        Hashtable hashtable = new Hashtable();

        handlePageParameters(paramPageEvent);

        for (int i = 0; i < VALIDATOR_PARAMS.length; i++) {
            String str2 = 
                getParameterValue(bneWebAppsContext, VALIDATOR_PARAMS[i]);
            if (str2 == null)
                continue;
            hashtable.put(VALIDATOR_PARAMS[i], str2);
        }

        if ((FILTERVALUE != null) && (!FILTERVALUE.trim().equals(""))) {
            bneCompositeSQLCriteria = new BneCompositeSQLCriteria();
            if (FILTERFIELD != null && !FILTERFIELD.equals("")) {
                BneSimpleSQLCriteria bneSimpleSQLCriteria;
                if (FILTERFIELD.equals("VENDOR_SITE_CODE"))
                    bneSimpleSQLCriteria = 
                            new BneSimpleSQLCriteria(0, "VENDOR_SITE_CODE", 0, 
                                                     9, FILTERVALUE, 2);
                else
                    bneSimpleSQLCriteria = 
                            new BneSimpleSQLCriteria(0, "ADDRESS_LINE1 || ',' || CITY || ',' || STATE", 
                                                     0, 9, FILTERVALUE, 2);
                bneSimpleSQLCriteria.setSearchsCaseInsensitivity(true);
                bneCompositeSQLCriteria.addCriteria(bneSimpleSQLCriteria);
            }

        }

        setTableFilter(true);
        setTableData(getTableData(bneWebAppsContext, paramBneLOVControlBean, 
                                  hashtable, bneCompositeSQLCriteria));
        return null;
    }

    public void getListOfValueParameters() throws BneParameterException {
        for (int i = 0; i < VALIDATOR_PARAMS.length; i++) {
            String str1 = VALIDATOR_PARAMS[i];
            String str2 = 
                "Oracle Applications Sup Sup Site Test." + str1 + " field.";
            addComponentParameter(new BneParameter(str1, "", str2));
        }
    }

    private void handlePageParameters(PageEvent paramPageEvent) throws BneException {
        FILTERFIELD = 
                BneUIXUtils.getPageEventParameter(paramPageEvent, "listOfValues:bne:filterField");
        FILTERVALUE = 
                BneUIXUtils.getPageEventParameter(paramPageEvent, "listOfValues:bne:filterValue");
    }

    public DictionaryData[] getTableData(BneWebAppsContext paramBneWebAppsContext, 
                                         BneLOVControlBean paramBneLOVControlBean, 
                                         Hashtable paramHashtable, 
                                         BneCompositeSQLCriteria paramBneCompositeSQLCriteria) throws BneException {
        DictionaryData dictionaryData = null;
        Vector vector = new Vector();
        BneResultSet bneResultSet = null;
        ResultSetMetaData resultSetMetaData = null;
        try {
            String str = null;

            bneResultSet = 
                    VALIDATOR.getDomainValues(paramBneWebAppsContext, paramHashtable, 
                                              paramBneCompositeSQLCriteria);

            if (bneResultSet != null) {
                resultSetMetaData = bneResultSet.getResultSet().getMetaData();

                while (bneResultSet.next()) {
                    dictionaryData = new DictionaryData();

                    for (int i = 1; i <= resultSetMetaData.getColumnCount(); 
                         i++) {
                        str = bneResultSet.getString(i);

                        if (str == null) {
                            dictionaryData.put(resultSetMetaData.getColumnName(i), 
                                               "");
                        } else {
                            dictionaryData.put(resultSetMetaData.getColumnName(i), 
                                               str);
                        }
                    }

                    vector.addElement(dictionaryData);
                }
            }
        } catch (SQLException sqlException) {
            throw new BneSQLException(BneResourceString.getMlsString(-1L, -1L, 
                                                                     "Cannot get Supplier Site Name information"), 
                                      sqlException);
        } catch (BneMissingParameterException bneMissingParameterException) {
            paramBneLOVControlBean.addError(bneMissingParameterException.getMessage());
        }

        DictionaryData[] arrayOfDictionaryData = 
            new DictionaryData[vector.size()];

        for (int i = 0; i < vector.size(); i++) {
            arrayOfDictionaryData[i] = ((DictionaryData)vector.elementAt(i));
        }

        return arrayOfDictionaryData;
    }

    public String getComponentName() {
        return "SupplierSiteName";
    }

    public String getComponentVersion() {
        return "R12";
    }
}

(4)Create Dynamic LOV (JAVA LOV) for Supplier Site using following API,
begin
BNE_INTEGRATOR_UTILS.CREATE_JAVA_LOV
(P_APPLICATION_ID       => 200,
P_INTERFACE_CODE       => 'GENERAL_1_INTF', --BNE_INTERFACE_COLS_B.INTERFACE_CODE
P_INTERFACE_COL_NAME   => 'P_SUP_SITE', --BNE_INTERFACE_COLS_B.INTERFACE_COL_NAME                             
P_JAVA_CLASS           => 'sagar.oracle.apps.lovtest.component.SagarSupplierSiteNameComponent',
P_WINDOW_CAPTION       => 'Supplier Sites',
P_WINDOW_WIDTH         => 500, 
P_WINDOW_HEIGHT        => 500, 
P_TABLE_BLOCK_SIZE     => 50, 
P_TABLE_COLUMNS        => 'VENDOR_SITE_CODE,ADDRESS',  
P_TABLE_SELECT_COLUMNS => 'P_SUP_SITE',
P_TABLE_COLUMN_ALIAS   => 'P_SUP_SITE,ADDRESS',
P_TABLE_HEADERS        => 'Vendor Site Code, Address',
P_TABLE_SORT_ORDER     => 'yes, yes',
P_USER_ID              => -1);  
commit;
end;

(5)Bounce the server and test whether Dependent LOV works?

69 comments:

  1. Hi Good stuff!

    Is there any way we can debug this when things are not working straight away?
    Perhaps show messages in the WebADI sheet, or write some of our own stuff to the BNE log?

    Cheers
    Jeroen van Meenen

    ReplyDelete
    Replies
    1. Hi Jeroen van Meenan,

      Thanks.

      Yes, we can write debug messages to BNE Log using below profiles and JAVA classes,

      profiles:
      BNE Server Log Level
      BNE Server Log Filename
      BNE Server Log Directory
      classes:
      oracle.apps.bne.framework.BneLogger
      oracle.apps.bne.framework.BneTrace

      Regards,
      Sagar

      Delete
  2. Hi Sagar,
    I have did same steps but After all I can able to open dependent value set and i can see values, but when i select a value that value is not being populated in Excel sheet column - Please advise...

    Thanks,
    Mahesh

    ReplyDelete
    Replies
    1. Hello Mahesh,

      You have to set table-select-columns parameter.Also if table-columns is not equal to table-select-columns parameter, you have to set table-column-alias parameter.

      Hope this helps.

      Regards,
      Sagar

      Delete
    2. Hi Sagar,

      I tried the above steps but its still not populating in the excel sheet column. Please advice.

      Thanks,
      Pallavi

      Delete
  3. Wonderfully article, explained very neatly.
    I have did similar steps, its working fine but if enter supplir site as wrong valueas manual entry instead of lov selection still its considering. it should validate aga inst supplier?
    Any idea how to validate manually entered value?

    ReplyDelete
    Replies
    1. Hello Anil,

      Unlike OAF, in Oracle Web ADI validating as soon as we exit an LOV after manually entering value is not available.But Web ADI validates LOV values, when we upload.

      Regards,
      Sagar

      Delete
  4. Hello Sagar,
    Thanks for your reply. If i want to pass multiple parameters to supplier site how can i do that any idea? I need to pass Vendor Name and OU name to my Vendor site query? Please advise.

    Thanks,
    Mahesh

    ReplyDelete
  5. Sagar,
    Thanks for your reply. Now I need to pass two bind values to my supplier site. 1 is vendor name other is OU Name. Please share the code if you have. I dont have java knowledge.
    Here is my query:

    SELECT ss.vendor_site_code, ss.address_line1 || ',' || ss.city || ',' || ss.state address FROM apps.ap_suppliers s,apps.ap_supplier_sites_all ss,hr_operating_units hru WHERE ss.vendor_id = s.vendor_id AND s.vendor_name = :1 AND hru.organization_id = ss.org_id AND hru.name = :2

    ReplyDelete
    Replies
    1. Hi,

      Sorry for replying late.It is very much logical to handle two parameters.I hope you have got a Java resource and solved this issue.

      Let me know if you still have this question unanswered.

      Regards,
      Sagar

      Delete
    2. Hi Sagar,

      I have the same request (passing two bind values). Could you post an example of how the Component.java and Validator.java would look like?

      Much appreciated
      Jeroen

      Delete
    3. Hi Sagar,
      please provide the solution for this as soon as possible.
      It will be great help.

      Delete
    4. Hi Sagar ,I am facing the same issue..I also dont know java..Can u please share the code for component and validator?

      Delete
  6. Hi Sager,

    I want to create dependent lov for 2 lookups ..

    for example.
    if i select one value in 1st column,
    in second column only that related values should import

    ReplyDelete
    Replies
    1. Hi,

      You have to write proper query to select from fnd_lookup_values and fnd_lookup_types.Once query is ready, you have to change above code accordingly.

      Regards,
      Sagar

      Delete
  7. Hi sagar,

    We are using R12.1.3 , Is it possible for you tell us the Front end Navigation to do the same using Desktop Integration Manager responsibility.

    Regards
    Apurba k Saha

    ReplyDelete
    Replies
    1. Hi Apurba,

      Are you asking, whether we can create JAVA LOV using Desktop Integration Manager responsibility, instead of API BNE_INTEGRATOR_UTILS.CREATE_JAVA_LOV?

      If I am correct, yes we can create JAVA LOV using Desktop Integration Manager responsibility, but you need to change your integrator at lot of places.
      These changes are done by API in a single shot.


      Regards,
      Sagar

      Delete
  8. Hi,

    Your article really helps me in creating depending valueset. However selected Dependent value set value is not copied to the Excel sheet. Depending valueset showing correct values. Any idea what could be the reason.

    Thanks
    hari

    ReplyDelete
    Replies
    1. Hi Hari,

      You have to set table-select-columns parameter.Also if table-columns is not equal to table-select-columns parameter, you have to set table-column-alias parameter.


      Regards,
      Sagar

      Delete
    2. Thanks Sagar. My issue got resolved. Thanks a Lot.

      regards
      Hari

      Delete
    3. You are welcome Hari! :)

      Regards,
      Sagar

      Delete
  9. Hi Sagar,

    Thanks for your posting about webadi.

    We are able to see the LOV for Supplier Field and We had created the Java class files and complied in sequence but we are unable to get the Dependent LOV for Supplier site. Do we need to do any setups from front end after step no 4 to get the lov in supplier site field in Web adi Sheet?.

    Thanks In Advance,
    kalyan.




    ReplyDelete
    Replies
    1. Hi Kalyan,

      Have you bounced OACORE OC4J as last step? If not please do.

      If the problem still persists, write debug messages to BNE Log using below profiles and JAVA classes,

      profiles:
      BNE Server Log Level
      BNE Server Log Filename
      BNE Server Log Directory
      classes:
      oracle.apps.bne.framework.BneLogger
      oracle.apps.bne.framework.BneTrace

      Check log for errors.
      Hope this helps.

      Regards,
      Sagar

      Delete
  10. Hi,

    I would like to add a note on this topic. If you are replacing any static (table type) LOVs, please note that the validation that you normally have in the WebADI disappears and needs to be done in your PL/SQL wrapper.

    For example, if you would have a static table LOV on Supplier Site with let’s say 10 values (1 to 10), then you are not able to upload anything else that those 10 values because the WebADI would validate any value entered against the LOV when uploading.

    However, when you change the LOV to become a Dependent LOV on Supplier, then this validation is lost. You would need to add this validation in you PL/SQL wrapper (the procedure called by the WebADI).

    Cheers
    Jeroen


    ReplyDelete
    Replies
    1. Thanks a lot Jeroen for sharing this.

      Regards,
      Sagar

      Delete
    2. Hi Jeroen,
      Is it possible you could provide steps how to add validation in my PL/SQL wrapper (procedure called by WebAdi) please.

      Many Thanks
      Smita

      Delete
  11. Hi Admin,
    How to find the path of java file.I have copied these files in java top folder .First of all how to compile these files?and then path of these files?

    Cheers
    Thanks
    Faisal Abbasi

    ReplyDelete
    Replies
    1. Hi Faisal,

      The first line of java file, which starts with keyword 'package' is nothing but the folder structure in $JAVA_TOP.

      If folder structure is not present, you have to create it.
      Then you have to copy the java file in this folder structure.

      To compile you can use Putty.Using putty, connect to server using Telnet or FTP.
      Then use cd command to go to folder structure in $JAVA_TOP.

      After that use javac command to compile the java file.

      This is the most basic way to compile any Java File.

      Regards,
      Sagar

      Delete
  12. Hi Sagar,

    I am also looking for the source java file but did not get correct path . I could see the *.class file in $JAVA_TOP , but I can't read those file as they are compiled ones .
    I am trying to open a seeded(standard) Java file to get more clarity on the source code. Would you be able to provide some help.

    ReplyDelete
    Replies
    1. Hi Vijay,

      You have to use a Decompiler.

      Regards,
      Sagar

      Delete
  13. Hi Sagar,

    I follow your steps and able to compile SQL and validator file,
    however when i compiled Component files, i got error message

    .java uses unchecked or unsafe operations.
    Note: Recompile with -Xlint:unchecked for details.

    Any idea about this

    ReplyDelete
    Replies
    1. Hi Vijay,

      You can ignore this message.It is a warning, not an error!
      Let me know if you are stuck anywhere else.

      Regards,
      Sagar

      Delete
  14. Hi Sagar,
    Thanks for the article. I was able to create dependent LOV using the above code for fnd lookup meaning and code. But, when I select the value and click on Go button , the value wont get populated on excel sheet. I see an update above that we need to set Table select columns which I did, however, I am not able to get the value in the excel. Can you plz help what I am missing?


    Thanks
    Lavanya

    ReplyDelete
    Replies
    1. Hi Lavanya,

      If table-columns is not equal to table-select-columns parameter, you have to set table-column-alias parameter also.


      Regards,
      Sagar

      Delete
  15. Hi Sagar, Thanks for the post.
    Question:
    I tried to create two independent LOVs - first one works great. I tried to create another LOV on the second column [really independent on the first column], but the bind variable always looks at the first column value for the second column LOV and pulls the data. Never looks at what is given the second column. Any ideas?

    ReplyDelete
  16. Your lov works great. Someone also asked this question - do you have an example with more than one depedency values like :1 and :2? I tried to look into your java files and try to find places where I need to handle more than one bind variable, but it seems very complex.

    ReplyDelete
  17. Hi Sagar,

    Very good article Sagar.
    I have 1 query relating to Custom Integrator. I am able to develop WebADI, but while adding LOV for some columns, its not working. I am adding LOV for SEX/GENDER column.
    I am using below code:

    UPDATE bne_interface_cols_b int_col
    SET val_id_col = 'LOOKUP_CODE',
    val_mean_col = 'MEANING',
    val_desc_col = 'DESCRIPTION',
    val_type = 'TABLE',
    lov_type = 'STANDARD',
    val_obj_name = 'HR_LOOKUPS',
    val_addl_w_c = 'LOOKUP_TYPE = SEX'
    WHERE interface_col_name = 'P_SEX'
    AND interface_code =
    (SELECT ifb.interface_code
    FROM BNE_INTERFACES_B ifb, BNE_INTEGRATORS_tl int
    WHERE 1 = 1
    AND user_name = 'XXHR_Integator_Name'
    AND ifb.integrator_code = int.integrator_code);

    Can you please help me on this. Appreciate your feedback.

    Regards,
    Vinit

    ReplyDelete
  18. Hi Sagar ,
    I followed every steps. But I am getting below error.

    Fatal error: Please have your system administrator view the bne.log file.
    oracle.apps.bne.exception.BneFatalException: Unable to find component class xxinv.oracle.apps.xxinv6626.component.ItemNamesComponent6626cst.
    Please contact your support representative.

    Regards
    Priya

    ReplyDelete
    Replies
    1. Hi,

      Please bounce APACHE and try.

      Regards,
      Vinit

      Delete
  19. Hi All,

    Can any one worked on creating LOV in 11I??

    thanks

    ReplyDelete
  20. hi Sagar,
    I created dependent lov through new DIM resp. in that we create component .
    in this case we need to create a JAVA component. for this there is no option of P_SELECT_COLUMNS and due to this when we select Suplier site in lov, it's not getting populated on excel created. any idea how to achieve it?

    ReplyDelete
    Replies
    1. Hi,

      I've achieved it using API, as instructed in tutorial. It seems you cannot use application to create dependant LOV.

      Regards,
      Marko

      Delete
  21. Hi Sagar,

    Thanks for the info it was really helpful however, I'm not a java guy and my requirement is to make the activity column that I have selected dependent on the operating column. The table for this is ar_receivables_trx_all. Where in the java file do I need to make the necessary changes for the codes to work properly?? any help from your side will be deeply appreciated.

    Thanks,
    Anurag

    ReplyDelete
  22. Hi,

    Thank you for a great tutorial. I was able to create LOV according to your instructions. Now I am trying to create LOV with ID and MEANING values (MEANING is shown in Excel, while ID is sent to API parameter). This functionality exists for standard Table-type LOV.

    Could you please help?

    Thank you,
    Marko

    ReplyDelete
    Replies
    1. Hi Marko,

      I am trying to achieve the same thing (dependent LOV in webadi, MEANING is shown in Excel, while ID is sent to API parameter). Any clues?

      Thanks in advance.

      Ivan

      Delete
    2. Hi Ivan,

      I have not managed to do it so. So I am passing meaning to API, not ID.

      Regards,
      Marko

      Delete
  23. Hi Sagar,

    thanks for the information which you provided in this article. do you have any other way to create depedent lov with out java classes in 11i.

    i would appreciate if you can provide resolution for the same

    Regards
    Siva Rajesh

    ReplyDelete
  24. Hi Sagar

    Thanks for the article. Its very helpful. Can you please tell me how can we add LOV for accounting flexfield. I need it for AP Invoice interface. I would appreciate if you can provide some solution.

    Thanks
    Pallavi

    ReplyDelete
  25. Thanks Sagar, your article is very helpful.

    B Rgds,
    Balu.

    ReplyDelete
  26. Hi Sagar,
    Is there a way of accomplishing this same supplier and supplier site LOV in Web ADI 12.1.3 via the front end without having to compile java code? For example, using the Desktop Integration Manager responsibility?

    Thanks.
    Y

    ReplyDelete
  27. Hi Sagar

    I am facing an issue.

    Fatal error: Please have your system administrator view the bne.log file.
    oracle.classloader.util.AnnotatedClassFormatError: oracle/apps/lovtest/component/SagarSupplierSiteNameComponent : Unsupported major.minor version 51.0 Invalid class: oracle.apps.lovtest.component.SagarSupplierSiteNameComponent Loader: oacore.root:0.0.0 Code-Source: /tgmc5i/applmgr/common/java/classes/ Configuration: in /tgmc5i/applmgr/common/webapps/oacore/ Dependent class: oracle.apps.bne.integrator.component.BneComponentFactory Loader: oacore.root:0.0.0 Code-Source: /tgmc5i/applmgr/common/java/classes/ Configuration: in /tgmc5i/applmgr/common/webapps/oacore/ This class was compiled for a newer version of the JRE. Expected version 50.0, found 51.0.
    Please contact your support representative.

    I have installed JDK 1.7 Update 51 in local machine. In unix box it is java -version
    java version "1.6.0_43"
    Java(TM) SE Runtime Environment (build 1.6.0_43-b01)
    Java HotSpot(TM) Server VM (build 20.14-b01, mixed mode)

    I tried -source option also but it is not working. Can you help me out?

    ReplyDelete
    Replies
    1. Hi Kartheek,

      Did you get this issue resolved...?... If yes, please let us know the solution.

      Delete
    2. Try giving version in javac
      e.g.
      javac -source 1.6 -target 1.6 ./bolinf/oracle/apps/manchrg/component/bolinfCustSiteNumComponent.java
      It solved above issue for me.

      Delete
  28. Had this requirement to create LOV's dependent on 2/3 other LOV's... Your article and the comments posted by you and others were of great help in doing so... Thanks a ton Sagar... Keep up the good work... :)

    Regards,
    Anoop S

    ReplyDelete
  29. Hi Sagar,
    we have the same requirement.
    We followed the instructions give by u and used code given by u.
    But we are not getting any values in the dynamic LOV.
    We are getting the filed names (site, address) but beside that it is showing no values found.

    Could you please let us know what might be the problem.

    Regards,
    Eswar.B

    ReplyDelete
  30. Hi Sagar,
    Thanks for providing the solution for Dependent LOV. I have one question, when I enter partial value in the field , at the time of Upload, the field is not getting validated. is there any way to force the validation of the field ?

    Thanks
    Rajesh

    ReplyDelete
  31. Hi Sagar,

    Thanks for sharing very much valuable information in detailed steps.

    I need to customize existing JAVA_LOV of a seeded Web ADI. Currently it is showing Address from HZ_LOCATIONS table in a single field as below
    3784-148 AVENUE NE,,,,CALGARY,,T2Z 3V6,CA
    My requirement is to display SiteNumber||Address.

    Can you please explain how can we achieve?

    Thanks You
    -Raj

    ReplyDelete
  32. Hi Sagar,
    Thanks for the article . I am able to create the dependent LOV successfully. I have another requirement and appreciate if you help it out.

    I have two LOV. First has the source of Table. The second LOV is not directly dependent on First. The values in the First LOV actually decides which query to be executed. So no bind parameters for the actual query but instead complete Dynamic Query.

    for eg: First LOV has values like Customer,People,Order Number,etc. Based on the selection. if user selects Customer than all the customer and if people then all employees.

    I am able to generate the query through PL/SQL. Also I can manage it to bring in any of the Java class..
    The question is where to actually wirte the code and how to manage those 3 class files..

    Its a bit urgent requirement. Appreciatte if you could help out sooner.

    Thanks,
    Yadnesh

    ReplyDelete
  33. Hi,
    With respect to my earlier comment.. I am able to resolve it. I have one small issue. The number or rows get restrcited to exact filter that should be.. But i am not able to see anything in the Poplist itself Only blank columns.. But the rows filtered are proper.. I am sure i am missing something very minute.. Please help at the earliest.

    ReplyDelete
  34. Hi Sagar,

    I'm trying to doing something like this, but i have only to validate a column (ATTRIBUTE1 of GL_INTERFACE), how can i do this ??... Do you know how can i start to looking ?.. because i didn't found too much information regarding this..

    Thanks!!

    Pablo.-

    ReplyDelete
  35. Hi,

    Great work and i am new to webadi. where can we write this 3 JAVA Class in web adi?

    Thanks,
    Vamshi

    ReplyDelete
  36. I am copying a data in excel,then changed it............but while uploading that its doesn't get validated....wrong value updated to table..plz help me

    ReplyDelete
  37. I am done with creation dependent LOV,its work fine....but when i changed the data of excel after selecting data from lov,it doesn't validated........plz help me

    ReplyDelete
  38. If we have requirement of creating multiple dependent javaLOVS in the same integrator, seems BNE_INTEGRATOR_UTILS.CREATE_JAVA_LOV is not able to handle creation of multiple components.

    Is it expected to have all the different column validations in the same java validator, component and sql class files? If yes, do you have a a sample class file code to handle multiple dependent LOVs on the same integrator.

    Regards,

    ReplyDelete
  39. Hi Sagar,
    In R12.2.5 I am getting below error:
    "oracle.apps.bne.exception.BneFatalException: Unable to find component class ".
    I have followed the steps in same sequence as suggested by you.
    Could you help?

    ReplyDelete
  40. Hi All,
    I followed every steps. But I am getting below error.

    Fatal error: Please have your system administrator view the bne.log file.
    oracle.apps.bne.exception.BneFatalException: Unable to find component class
    Please contact your support representative.

    ReplyDelete
  41. LOV is working fine but When i try to search in the LOV using Search window the LOV errors out. Can you please help on this. Appreciate the Help

    ReplyDelete