ECC Projects, Projects Costing: Budget Results, SQL1

Description
Columns: Record Type, Ecc Spec Id, Record Identifier, Project Id, Project Name, Project Number, Budget Version Id, Budget Type Code, Budget Type, Periodicity ...
Imported from ECC
select * from (
SELECT
RECORD_TYPE,
ECC_SPEC_ID,
RECORD_IDENTIFIER,
PROJECT_ID,
PROJECT_NAME,
PROJECT_NUMBER,
BUDGET_VERSION_ID,
BUDGET_TYPE_CODE,
BUDGET_TYPE,
PERIODICITY,
BC_COMMITMENT_EI_ID,
FC_START_DATE,
FC_END_DATE,
TASK_ID,
TASK_NUMBER,
TASK_NAME,
TOP_TASK_ID,
SUPPLIER_NAME,
SUPPLIER_ID,
SUPPLIER_NUMBER,
JE_SOURCE_NAME,
JE_CATEGORY_NAME,
DOCUMENT_TYPE_CODE,
DOCUMENT_TYPE_DESC,
DOCUMENT_NUMBER,
LINE_NUMBER,
DISTRIBUTION_NUMBER,
PA_DATE,
GL_DATE,
RESOURCE_LIST_MEMBER_ID,
BUDGET_CCID,
TXN_CCID,
BC_PACKET_ID,
PARENT_BC_PACKET_ID,
BUD_RESOURCE_LIST_MEMBER_ID,
BUD_TASK_ID,
EXPENDITURE_TYPE,
EXPENDITURE_CATEGORY,
EXPENDITURE_ITEM_DATE,
PA_PERIOD_NAME,
GL_PERIOD_NAME,
DOCUMENT_HEADER_ID,
DOCUMENT_DISTRIBUTION_ID,
DOCUMENT_LINE_ID,
ENTERED_DR,
ENTERED_CR,
TXN_CURRENCY,
ACCOUNTED_DR,
ACCOUNTED_CR,
NET_AMOUNT,
REJ_ENTERED_DR,
REJ_ENTERED_CR,
REJ_ACCOUNTED_DR,
REJ_ACCOUNTED_CR,
REJ_NET_AMOUNT,
FUNDS_PROCESS_MODE,
STATUS_CODE,
STATUS_CODE_DESC,
RESULT_CODE,
ALERT_TYPE,
ALERT_TEXT,
RAW_COST,
BURDEN_COST,
FUNC_CURRENCY,
PROJECT_CURRENCY,
PROJECT_RATE_TYPE,
PROJECT_RATE_DATE,
PROJFUNC_CURRENCY_CODE,
PROJFUNC_COST_RATE_DATE,
PROJFUNC_COST_RATE_TYPE,
EXPENDITURE_ORGANIZATION_ID,
EXPENDITURE_ORGANIZATION,
PARENT_DOC_HEADER_ID,
PARENT_DOC_LINE_ID,
PARENT_DOC_DIST_ID,
PARENT_DOC_TYPE_CODE,
PARENT_DOC_TYPE_DESC,
PARENT_DOC_NUMBER,
PARENT_LINE_NUMBER,
PARENT_DIST_NUMBER,
COST_DISTRIBUTED_FLAG,
ACCOUNTING_STATUS,
QUANTITY,
UNIT_OF_MEASURE,
RAW_COST_RATE,
DEBIT_ACCOUNT,
CREDIT_ACCOUNT,
project_id || task_id || GL_PERIOD_NAME ASSC_ID,
LANGUAGE
FROM PA_ECC_COST_BC_RESULTS where language in ('US'))PIVOT ( max(DOCUMENT_TYPE_DESC) as DOCUMENT_TYPE_DESC,
max(EXPENDITURE_ORGANIZATION) as EXPENDITURE_ORGANIZATION,
max(STATUS_CODE_DESC) as STATUS_CODE_DESC,
max(ALERT_TEXT) as ALERT_TEXT,
max(PARENT_DOC_TYPE_DESC) as PARENT_DOC_TYPE_DESC,
max(COST_DISTRIBUTED_FLAG) as COST_DISTRIBUTED_FLAG,
max(ACCOUNTING_STATUS) as ACCOUNTING_STATUS,
max(UNIT_OF_MEASURE) as UNIT_OF_MEASURE
for LANGUAGE in ('US' "US"))