Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Accessing huge file from the file system..

Status
Not open for further replies.

vrs1008

Programmer
Sep 16, 2003
62
US
I have a huge file to get from the file system (file name decided at run time). I need to pass it to the functional map which will call the Run Map. Functional map will not do anything with the file. It will simply call the run map by passing the file to it.

Which of the following approch works good and consumes less resources??

1. Use Get the file command once to get the file from the File system. Pass it to the functional map.

GET("FILE","/uat/277/trans.txt")

Here file will be fetched once form the file system and referred as many times as the functional map executes.


2. Use Get file command within the functional map to get the file from the File system.

GET("FILE","/uat/277/trans.txt")

Here file will be fetched as many times as the functional map executes.


3. Use -IF1 command while calling the Run map.

RUN("277_exec.mmc","-IF1 /uat/277/trans.txt.....")

Here file will be accessed/fetched as many times as the Run map get called.

We are using Mercator 6.5 on AIX box.

If you have better idea then above 3, then let me know.

Regards,
Vibhav1008
 
Not sure it makes much difference, get verses run.

I assume that you have multiple maps that can be executed from the f_map and you look at the data to determine what you need. Do you need to pass the file to functional map? Unless your interigating chunks of data and running multple maps based on your findings why not execute the runmap right away....

If you are passing the entire file to the f_map and then executing a runmap your sucking up huge amounts of resources. A minimum of 3x the size of the original file.

Can you:

1. create a new event for the maps that need to run and rename the file based on its unique trigger?

2. create a new event (control file) file that contains the information needed by the runmap? (input_path_and_file_name ~ runmap_path_and_name ~ other information). That file is read by a cntl map which will run whatever map is in the cntl file. This will provide you will all sorts of opportunities for executing maps outside the eventserver.


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top