Can someone tell me the behaviour of next_in_sequence() and innovation_number() in a multifile.
Suppose I have records 1,1,1,2,2,3,4,4 in a 4ways mfs file. Data in each partition is:
0th : 1,1,1
1st : 2,2
3rd : 3
4th : 4,4
What will be the sequence of these records if I pass next_in_sequence() and innovation_number() ?
Also how can I extract 3rd record from each of the 4 partitions of a 4way multifile through AbInitio? In unix we can use m_dump
Answer Posted / ram
AbInitio, next_in_sequence() function returns the next record in the sequence within a partition, while innovation_number() function returns the innovation number of the record, indicating its position in the sequence.Given the data you provided and assuming each record is numbered sequentially within each partition, the sequence of records when applying next_in_sequence() and innovation_number() would be:next_in_sequence(): 1, 1, 1, 2, 2, 3, 4, 4innovation_number(): 1, 2, 3, 1, 2, 1, 1, 2To extract the 3rd record from each of the 4 partitions of a 4-way multifile in AbInitio, you can use a combination of next_in_sequence() and conditional statements. Here's a basic outline of how you can achieve this:read_from_multifile(in = input_multifile) ->
begin
out :: output_table;
while(not end_of_file(input_multifile))
begin
record := next_in_sequence(input_multifile);
if innovation_number(input_multifile) = 3 then
out <- record;
end;
end;This script reads from the multifile and checks if the current record's innovation number is 3. If it is, the record is outputted to the output table. Repeat this process for all four partitions of the multifile.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Is data warehousing different from data mining?
What are the steps to create a repository in ab initio?
What are the co> operating system’s assorted library of integrated components?
what is the use of catlog or catlogfile?
What are differences between different gde versions(1.10,1.11,1.12,1.13and 1.15)?what are differences between different versions of co-op?
Can anyone give me an exaple of realtime start script in the graph?
What would be the next step after collecting the data?
Name the different type of processing based on the steps that you know about?
Input A 100 NUll A NUll 200 B 100 Null B Null 300 Output A 100 200 B 100 300 Do this using Ab initio
What do you mean by a transaction file and how it is different from that of a sort file?
What is publickey and private key?what is the use of this two keys?
Do you think effective communication is necessary for data processing?
Why creation of temporary files depends on the value of MAX CORE ? How to use in abinitio graph? 10. What is the diff between abinitiorc and .abinitiorc files ? How to use in abinitio graph? 11. What is the use of allocate()? How to use in abinitio graph? 12. What is use of branch in EME ? 13. How you can break a lock in EME ? How can you lock a file so that only no one other than EME admin can break it ? How to use in abinitio graph? 14. When you should be using ablocal() ? How you can use ablocal_expr? How to use in abinitio graph? 15. Why you should not keep the layout as 'default' for input table component ? How to use in abinitio graph? 16. What is dynamic lookup ? How to use in abinitio graph? 17. What is dependent parameter ? How to use in abinitio graph? 18. What is BRE ? (Business Rule Environment - This is a recent addition in abinitio package) How to use in abinitio graph? 19.What is output index ? How to use in abinitio graph? 20. How you can track the records those are not getting selected from ‘select’ in reformat component ? How to use in abinitio graph? 21. Can we have more than one launcher process for a particular graph ? How about agent ? How to use in abinitio graph? 22. There are lot of new fuctions added in 2.15 , you can ask about them ? How to use in abinitio graph? 23. How can you run multiple instances of a graph in parallel? How to use
What is the role of co-operating system in abinitio?
What is broadcasting and replicate?