Page 1 of 1

How to get total sales and Total Revenue

Posted: Mon Aug 06, 2012 6:54 am
by Kapil M
Hi

In <i>Receivables Transaction</i> on line level there is invoice amount made against sales order is to calculate Total sales and In 'sales credit' section there Revenue amount,
So is it the correct way to get <i>Total Sales</i> and <i>Total Revenue</i>?
Or is there any report or query to get this?

Thanks in advance
Kapil

Posted: Fri Sep 21, 2012 3:37 am
by ata_rehman70
If this is for process enabled org you can use modify below query



select GEH.REFERENCE_NO, GEH.TRANSACTION_ID,GEH.TRANSACTION_DATE,
gel.line_number, gel.journal_line_type, gel.entered_amount,gel.accounted_amount,
FND_FLEX_EXT.GET_SEGS('SQLGL', 'GL#',gcc.chart_of_accounts_id,gcc.code_combination_id) account,GL_FLEXFIELDS_PKG.get_concat_description( gcc.chart_of_accounts_id, gcc.code_combination_id) acc_description
FROM gl_code_combinations gcc,xla_ae_lines al,
xla_distribution_links dl,gmf_xla_extract_headers geh,
gmf_xla_extract_lines gel
WHERE gcc.code_combination_id = al.code_combination_id
AND al.ae_header_id = dl.ae_header_id AND al.ae_line_num = dl.ae_line_num
AND dl.event_id = geh.event_id AND dl.application_id = 555
AND dl.source_distribution_type = geh.entity_code AND dl.source_distribution_id_num_1 = gel.line_id
and GEH.HEADER_ID = GEL.HEADER_ID and GEH.EVENT_ID = GEL.EVENT_ID
and gel.journal_line_type in ('COGS','DCOG')and geh.transaction_date >= TO_DATE('&&fromDate'||' 00:00:00','MM/DD/YYYY hh24:mi:ss') --period start date 01/01/2011 AND geh.transaction_date <= TO_DATE('&&toDate'||' 23:59:59','MM/DD/YYYY hh24:mi:ss') --Period end date 01/31/2011

regards,
Ata

Posted: Thu Sep 27, 2012 3:39 am
by hiszaki
Hi Ata

Thanks for the SQL