368: where event_id = p_event_id
369: and actual_flag = 'E'
370: and pck.ledger_id = cbc.set_of_books_id(+)
371: and exists 372: (select 1 from gl_ledgers l 373: where l.ledger_id = pck.ledger_id
374: and l.ledger_category_code = 'PRIMARY');
375:
376: l_return NUMBER := 1;