Midrange News for the IBM i Community


Posted by: Jeff Masak
IT Developer
The Boldt Co
Appleton, WI
Determining Folder Size on the IFS
has no ratings.
Published: 01 May 2012
Revised: 23 Jan 2013 - 4108 days ago
Last viewed on: 22 Apr 2024 (10742 views) 

Using IBM i? Need to create Excel, CSV, HTML, JSON, PDF, SPOOL reports? Learn more about the fastest and least expensive tool for the job: SQL iQuery.

Determining Folder Size on the IFS Published by: Jeff Masak on 01 May 2012 view comments(3)

Is there a way to determine Folder Sizes on the IFS?  Any Help appreciated.  Jeff

Return to midrangenews.com home page.
Sort Ascend | Descend

COMMENTS

(Sign in to Post a Comment)
Posted by: bobcozzi
Site Admin ****
Chicagoland
Comment on: Determining Folder Size on the IFS
Posted: 11 years 11 months 23 days ago

You mean total size of all the files in that folder?

If you have the ifsFileSize API I wrote or using the STAT api in the C runtime, you can determine each file's size within a directory. I've also written articles on recursing directories and reading each file name as if you were processing a database file's records. Then you could apply the STAT APi to each file that's read. But there's also Directory/Folder overhead.

What is your specific goal?

Posted by: bobcozzi
Site Admin ****
Chicagoland
Comment on: Determining Folder Size on the IFS
Posted: 11 years 11 months 22 days 23 hours 15 minutes ago

Gosh, what a dope I am!

RTVDIRINF DIR('/home/cozzi')

PRTDIRINF *DIR

Posted by: jmasak
Premium member *
Appleton, WI
Comment on: Determining Folder Size on the IFS
Posted: 11 years 11 months 22 days 5 hours 18 minutes ago

Did a BING/GOOGLE Search for IFS Folder Size and found the Command QRYIFSLIB from

http://www.itjungle.com/fhg/fhg111407-story03.html

 

And followed the how to in there. 

 

Note, best to submit the command

CALL PGM(QRYIFSLIB) PARM('/*' '\s' '\X:*NONLOCAL') as it may take awhile for it to run.

 

Jeff