Finding CostCenter Description from GL [message #176317] |
Wed, 07 June 2006 19:03 |
pras
Messages: 57 Registered: June 2002
|
Member |
|
|
Hi
Anyone knows how to find Cost Center Name from Oracle Applications.
I know that segment2 from gl_code_combinations table gives the cost center no.But I want to know the associated name with that cost center.
thanks
prasanna
|
|
|
|
Re: Finding CostCenter Description from GL [message #177400 is a reply to message #176465] |
Wed, 14 June 2006 07:47 |
David.K.Dickson
Messages: 413 Registered: October 2005 Location: Surrey, England
|
Senior Member |
|
|
I persuaded one of our Developers to help me with the SQL and here it is:
select val.FLEX_VALUE
, valtl.DESCRIPTION
from FND_ID_FLEXS flex
, FND_ID_FLEX_SEGMENTS seg
, FND_ID_FLEX_STRUCTURES struc
, FND_FLEX_VALUES val
, FND_FLEX_VALUES_TL valtl
where flex.ID_FLEX_NAME = 'Accounting Flexfield'
and struc.ID_FLEX_STRUCTURE_CODE = &&structure
and seg.SEGMENT_NAME = &&segment
and val.FLEX_VALUE = &&flex_value
and struc.ID_FLEX_NUM = SEG.ID_FLEX_NUM
and seg.ID_FLEX_CODE = FLEX.ID_FLEX_CODE
and val.FLEX_VALUE_SET_ID = SEG.FLEX_VALUE_SET_ID
and valtl.FLEX_VALUE_ID = val.FLEX_VALUE_ID
and valtl.LANGUAGE = USERENV('LANG')
order by val.FLEX_VALUE;
You will have to enter the Structure (&&structure) and Independant Segment (&&segment) names based on the values in the "Segment Values" form:
General Ledger Super User>Setup>Financials>Flexfields>Key>Values
and enter the Cost Centre number in the Flex Value (&&flex_value).
HTH
David
[Updated on: Wed, 14 June 2006 07:52] Report message to a moderator
|
|
|