Friday 17 April 2020

API to create lookup values in oracle apps

API to create lookup values in oracle apps

In this post , we will be discuss about API to create lookup values in oracle apps.Oracle has provided the standard API's to create lookup and lookup values in oracle apps. Using these API , we can create the new lookup and upload the mass lookup values in oracle apps. API helps to create the bulk lookup values in oracle apps from bank end. It helps to minimize the manual effort to create the lookup values in oracle apps. In this post , I will share the complete script to create the lookup values through API in oracle apps. Here below is the detail about API to create lookup values in oracle apps.

API to create lookup values in oracle apps
API to create lookup values in oracle apps

2 Important API's about lookup values in oracle apps

1. FND_LOOKUP_TYPES_PKG.INSERT_ROW for inserting new lookup type,
2. FND_LOOKUP_VALUES_PKG.INSERT_ROW for inserting new lookup value.

Detail PLSQL Script to create lookup values in oracle apps

DECLARE
   v_rowid    VARCHAR2 (400);
   v_rowid1   VARCHAR2 (400);
BEGIN
   fnd_lookup_types_pkg.insert_row (x_rowid                    => v_rowid,
                                    x_lookup_type              => 'XX_NEW_LOOKUP',
                                    x_security_group_id        => 0,
                                    x_view_application_id      => 0,
                                    x_application_id           => 0,
                                    x_customization_level      => 'U',
                                    x_meaning                  => 'XX_NEW_LOOKUP',
                                    x_description              => 'XX_NEW_LOOKUP',
                                    x_creation_date            => SYSDATE,
                                    x_created_by               => 0,
                                    x_last_update_date         => SYSDATE,
                                    x_last_updated_by          => 0,
                                    x_last_update_login        => -1
                                   );
   DBMS_OUTPUT.put_line (v_rowid);
   fnd_lookup_values_pkg.insert_row (x_rowid                    => v_rowid1,
                                     x_lookup_type              => 'XX_NEW_LOOKUP',
                                     x_security_group_id        => 0,
                                     x_view_application_id      => 0,
                                     x_lookup_code              => 'lookupvalue1',
                                     x_tag                      => NULL,
                                     x_attribute_category       => NULL,
                                     x_attribute1               => NULL,
                                     x_attribute2               => NULL,
                                     x_attribute3               => NULL,
                                     x_attribute4               => NULL,
                                     x_enabled_flag             => 'Y',
                                     x_start_date_active        => TO_DATE ('01-JAN-1951',
                                                                            'DD-MON-YYYY'
                                                                           ),
                                     x_end_date_active          => NULL,
                                     x_territory_code           => NULL,
                                     x_meaning                  => 'lookupvalue1 desc',
                                     x_description              => NULL,
                                     x_creation_date            => SYSDATE,
                                     x_created_by               => 0,
                                     x_last_update_date         => SYSDATE,
                                     x_last_updated_by          => 0,
                                     x_last_update_login        => -1
                                    );
   DBMS_OUTPUT.put_line (v_rowid1);
   COMMIT;
END;

API to create lookup values in oracle apps
API to create lookup values in oracle apps

0 comments:

Post a Comment

Contact us for any Collaboration, Project Support & On Job Support Work

Name

Email *

Message *