Loading

Monday, January 31, 2011

API to get combination id based on segment info (FND_FLEX_EXT.GET_COMBINATION_ID)


                                                                                                                         
This API FND_FLEX_EXT.GET_COMBINATION_ID is used to get the code combination id based on the segment data. Returns NULL if structure not found.  

set serveroutput on;
DECLARE
  application_short_name   VARCHAR2(200);
  key_flex_code            VARCHAR2(200);
  structure_number         NUMBER;
  validation_date          DATE;
  n_segments               NUMBER;
  segments                 APPS.FND_FLEX_EXT.SEGMENTARRAY;
  combination_id           NUMBER;
  data_set                 NUMBER;
  v_return                 BOOLEAN;
BEGIN
  application_short_name := 'SQLGL';
  key_flex_code          := 'GL#';
  structure_number       := 60408;
  validation_date        := SYSDATE;
  n_segments             := 7;
  segments(1)            := '210';
  segments(2)            := '7001499';
  segments(3)            := '40460';
  segments(4)            := '81010';
  segments(5)            := '02000';
  segments(6)            := '010';
  segments(7)            := '00000';
  DATA_SET               := NULL;

  v_Return := FND_FLEX_EXT.GET_COMBINATION_ID(
               APPLICATION_SHORT_NAME => application_short_name,
               KEY_FLEX_CODE          => key_flex_code,
               STRUCTURE_NUMBER       => structure_number,
               VALIDATION_DATE        => validation_date,
               N_SEGMENTS             => n_segments,
               SEGMENTS               => segments,
               COMBINATION_ID         => combination_id,
               DATA_SET               => data_set
  );
  DBMS_OUTPUT.PUT_LINE('COMBINATION_ID = ' || combination_id);
  IF v_return THEN
  DBMS_OUTPUT.PUT_LINE('v_Return = TRUE'); 
  ELSE
  DBMS_OUTPUT.PUT_LINE('v_Return = FLASE'); 
  END IF;
END;


2 Responses to “API to get combination id based on segment info (FND_FLEX_EXT.GET_COMBINATION_ID)”

Anonymous said...
May 21, 2012 at 12:29 AM

its working


Sridevi Koduru said...
July 7, 2016 at 12:47 AM

Regards
Sridevi Koduru (Senior Oracle Apps Trainer Oracleappstechnical.com)
LinkedIn profile - https://in.linkedin.com/in/sridevi-koduru-9b876a8b


Post a Comment

Disclaimer

The ideas, thoughts and concepts expressed here are my own. They, in no way reflect those of my employer or any other organization/client that I am associated. The articles presented doesn't imply to any particular organization or client and are meant only for knowledge Sharing purpose. The articles can't be reproduced or copied without the Owner's knowledge or permission.