This content has been marked as final. Show 5 replies
Hi,1 person found this helpful
n_tot_rec NUMBER := 0;
n_blk_cnt NUMBER := Get_Block_Property('BLK,QUERY_HITS);
n_added_count number := 0;
WHILE n_tot_rec < n_blk_cnt LOOP
if name_in('blk.added') = 'Y' then
n_added_count = n_added_count + 1;
IF :SYSTEM.last_record = 'TRUE' THEN
n_tot_rec := n_tot_rec +1;
Thanks for the response but that also wont work because n_blk_cnt = 0 because nothing has been saved, it wasnt brought back via a query. So n_blk_cnt NUMBER := Get_Block_Property('BLK,QUERY_HITS); will always = 0
Thanks anyway though, appreciate you taking the time to help out.
am not sure what r u trying to do if u want count records not inserted yet then what about using a Global temporary table ?
Edited by: Amatu Allah on Apr 18, 2013 5:51 AM
im not sure how to get the blk_cntIt is always 0, because query_hits=0.
Or do you want the number of records in the block? Just go to the last record. The record number is then the total number of records in the block.
You can do this without any code using two calculated items. The first one of type formula which calculates like
The second one of type summary which calculates the first one.
cASE WHEN :BLOCK.ITE!='Y' THEN 1 ELSE 0 END