6 Replies Latest reply on Sep 3, 2015 5:41 AM by Jagadekara

    Cannot replace group; columns don't match LOV in Personalize

    Arip

      Hi all.

       

      i get Error, "Cannot replace group; columns don't match LOV in Personalize"

       

      in form Transaction receivable i create Personalize for change LOV.

      i want to change LOV in column Bill To.

      i try open form ARXTWMAI and then i see LOV for column Bill To. And i get LOV = AR_CUSTOMER_NAME_NOSKIP1

      i copy this query :

       

      select cust_acct.account_number account_number,

             substrb(party.party_name,1,50) party_name,

             party.jgzz_fiscal_code jgzz_fiscal_code,

             party.tax_reference tax_reference,

             cust_acct.cust_account_id customer_id,

             cust_acct.fob_point fob_point,

             null fob_point_meaning,

             cust_acct.ship_via ship_via,

             null ship_via_meaning,

             cust_acct.primary_salesrep_id primary_salesrep_id,

             null primary_salesrep_name,

             null primary_salesrep_num,

             cust_acct.account_name account_description

      from  hz_cust_accounts cust_acct,

            hz_parties party

      where cust_acct.party_id = party.party_id

      order by party_name

       

      And then i create Personalize :

      Condition :

      - Event = WHEN-NEW-FORM-INSTANCE

       

      Actions :

      - Seq 1 : Type Builtin

        Builtin Type = Create Record Group from Query

        Argument = i add one column

       

      select cust_acct.account_number account_number,

             substrb(party.party_name,1,50) party_name,

             party.address1,

             party.jgzz_fiscal_code jgzz_fiscal_code,

             party.tax_reference tax_reference,

             cust_acct.cust_account_id customer_id,

             cust_acct.fob_point fob_point,

             null fob_point_meaning,

             cust_acct.ship_via ship_via,

             null ship_via_meaning,

             cust_acct.primary_salesrep_id primary_salesrep_id,

             null primary_salesrep_name,

             null primary_salesrep_num,

             cust_acct.account_name account_description

      from  hz_cust_accounts cust_acct,

            hz_parties party

      where cust_acct.party_id = party.party_id

      order by party_name

       

      Group Name = TEM_BILL_TO

       

      - Seq 2 : Type Property

        Object Type = LOV

        Target Object = AR_CUSTOMER_NAME_NOSKIP1

        Property Name = GROUP NAME

        Value = TEM_BILL_TO

       

       

      and then i save and Apply Now.

      close form and open again.

      i get Error, "Cannot replace group; columns don't match LOV in Personalize".

       

      And if i open LOV Bill To, i not see new column Address.

       

      Please help.

      Thanks

        • 1. Re: Cannot replace group; columns don't match LOV in Personalize
          Jagadekara

          Hi,

           

          through form personalization we can't add new column to LOV.

           

          because standard query (.fmb) and our form personalization query should have same no of columns and same data types.

          • 2. Re: Cannot replace group; columns don't match LOV in Personalize
            Arip

            Thank Jagadekara.

             

            OK, i not add new column.

            But, i try add condition.

            Example :

             

            select cust_acct.account_number account_number,

                   substrb(party.party_name,1,50) party_name,

                   party.jgzz_fiscal_code jgzz_fiscal_code,

                   party.tax_reference tax_reference,

                   cust_acct.cust_account_id customer_id,

                   cust_acct.fob_point fob_point,

                   null fob_point_meaning,

                   cust_acct.ship_via ship_via,

                   null ship_via_meaning,

                   cust_acct.primary_salesrep_id primary_salesrep_id,

                   null primary_salesrep_name,

                   null primary_salesrep_num,

                   cust_acct.account_name account_description

            from  hz_cust_accounts cust_acct,

                  hz_parties party

            where cust_acct.party_id = party.party_id and cust_acct.account_number = '001624'

            order by party_name

             

            No Error, But if i click LOV nothing change, i see all customer number.

            What's wrong.

             

            Thanks...

            • 4. Re: Cannot replace group; columns don't match LOV in Personalize
              Jagadekara

              Hi,

               

              Yes, I too tried last time but not working.

               

              That is the form personalization limitation. It will not work for all forms.

               

              So try through custom.pll

              • 5. Re: Cannot replace group; columns don't match LOV in Personalize
                Arip

                Thank Jagadekara..

                 

                i try use custom.pll.

                 

                  PROCEDURE EVENT(EVENT_NAME VARCHAR2) IS

                  FORM_NAME      VARCHAR2(30) := NAME_IN('system.current_form');

                  BLOCK_NAME     VARCHAR2(30) := NAME_IN('system.cursor_block');

                  V_LOV LOV;

                  RG_NAME VARCHAR2(40) :='AR_CUSTOMER1';

                  RG_ID RECORDGROUP;

                  V_SQL VARCHAR2(5000);

                  RESULT NUMBER;

                  REC_ID RECORDGROUP;

                 

                  BEGIN

                      IF (EVENT_NAME = 'WHEN-NEW-FORM-INSTANCE' AND FORM_NAME= 'ARXTWMAI') THEN

                          IF (BLOCK_NAME = 'TGW_HEADER') THEN

                        RG_ID := FIND_GROUP(RG_NAME);

                        V_LOV := FIND_LOV('AR_CUSTOMER_NAME_NOSKIP1');

                       

                        V_SQL := 'select cust_acct.account_number account_number,

                                substrb(party.party_name,1,50) party_name,

                                party.address1 address,

                                party.jgzz_fiscal_code jgzz_fiscal_code,

                                party.tax_reference tax_reference,

                                cust_acct.cust_account_id customer_id,

                                cust_acct.fob_point fob_point,

                                null fob_point_meaning,

                                cust_acct.ship_via ship_via,

                                null ship_via_meaning,

                                cust_acct.primary_salesrep_id primary_salesrep_id,

                                null primary_salesrep_name,

                                null primary_salesrep_num,

                                cust_acct.account_name account_description

                          from  hz_cust_accounts cust_acct,

                                 hz_parties party

                          where cust_acct.party_id = party.party_id

                          order by party_name';

                             

                     REC_ID := CREATE_GROUP_FROM_QUERY('TEM_BILL_TO', V_SQL );

                     RESULT := POPULATE_GROUP(FIND_GROUP('TEM_BILL_TO'));

                     SET_LOV_PROPERTY('AR_CUSTOMER_NAME_NOSKIP1', GROUP_NAME, 'TEM_BILL_TO' );

                 

                          END IF;

                         END IF;

                  END EVENT; 


                And then i compile this custom.pll and i try open form and clik LOV Bill To but same, not change in LOV.

                 

                And then i try change Label in LOV for test this custom.pll.

                 

                  PROCEDURE EVENT(EVENT_NAME VARCHAR2) IS

                  FORM_NAME      VARCHAR2(30) := NAME_IN('system.current_form');

                  BLOCK_NAME     VARCHAR2(30) := NAME_IN('system.cursor_block');

                  V_LOV LOV;

                  RG_NAME VARCHAR2(40) :='AR_CUSTOMER1';

                  RG_ID RECORDGROUP;

                 

                  BEGIN

                      IF (EVENT_NAME = 'WHEN-NEW-FORM-INSTANCE' AND FORM_NAME= 'ARXTWMAI') THEN

                          IF (BLOCK_NAME = 'TGW_HEADER') THEN

                        RG_ID := FIND_GROUP(RG_NAME);

                        V_LOV := FIND_LOV('AR_CUSTOMER_NAME_NOSKIP1');

                       

                       SET_LOV_COLUMN_PROPERTY(v_lov, 4, TITLE, 'No Display');

                 

                         END IF;

                         END IF;

                  END EVENT;

                 

                And this is succesfull.

                But why if i add new column cannot success.

                 

                Thanks...

                • 6. Re: Cannot replace group; columns don't match LOV in Personalize
                  Jagadekara

                  Hi,

                   

                  I don't have knowledge about custom.pll.

                  I guess column addition is possible in custom .pll.

                   

                  Let us know if you resolve this issue.