<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Using hint values from rms to get filesize in Operating System - OpenVMS</title>
    <link>https://community.hpe.com/t5/operating-system-openvms/using-hint-values-from-rms-to-get-filesize/m-p/4750190#M19339</link>
    <description>Tom,&lt;BR /&gt;&lt;BR /&gt;  Depends on what you mean by "filesize"&lt;BR /&gt;&lt;BR /&gt;  From DCL, F$FILE_ATTRIBUTES ALQ will give you the allocated disk space, some of which will probably be unused. &lt;BR /&gt;&lt;BR /&gt;&amp;gt; (2*record_count + data_count) for getting &lt;BR /&gt;&amp;gt;file size ... but then will it hold good &lt;BR /&gt;&amp;gt;for all the cases?&lt;BR /&gt;&lt;BR /&gt;  No. Metadata size depends on the record format, and record lengths as odd lengths are padded.&lt;BR /&gt;&lt;BR /&gt;  For sequential files, EOF and FFB can be used to find the space in use (including both data and metadata).&lt;BR /&gt;&lt;BR /&gt;  If positive, FILE_LENGTH_HINT should be accurate to give you the data size, but if it's negative (invalid) you'll need to count.</description>
    <pubDate>Tue, 08 Feb 2011 21:24:13 GMT</pubDate>
    <dc:creator>John Gillings</dc:creator>
    <dc:date>2011-02-08T21:24:13Z</dc:date>
    <item>
      <title>Using hint values from rms to get filesize</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/using-hint-values-from-rms-to-get-filesize/m-p/4750188#M19337</link>
      <description>Hi all,&lt;BR /&gt;&lt;BR /&gt;I was wondering, how do i use the hint values provided by VMS for FIX and VFC files.&lt;BR /&gt;The data part is said to be with out any extra paddings ... &lt;BR /&gt;So how can we get the file size?&lt;BR /&gt;record_count + data_count or as every record is terminated with CRLF, shouldn't it be appropriate to use (2*record_count + data_count) for getting file size ... but then will it hold good for all the cases?</description>
      <pubDate>Tue, 08 Feb 2011 19:22:31 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/using-hint-values-from-rms-to-get-filesize/m-p/4750188#M19337</guid>
      <dc:creator>Tom Gates</dc:creator>
      <dc:date>2011-02-08T19:22:31Z</dc:date>
    </item>
    <item>
      <title>Re: Using hint values from rms to get filesize</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/using-hint-values-from-rms-to-get-filesize/m-p/4750189#M19338</link>
      <description>&lt;!--!*#--&gt;&amp;gt; [...] the hint values [...]&lt;BR /&gt;&lt;BR /&gt;The what?&lt;BR /&gt;&lt;BR /&gt;&amp;gt; [...] said to be [...]&lt;BR /&gt;&lt;BR /&gt;Who says what, exactly?&lt;BR /&gt;&lt;BR /&gt;&amp;gt; So how can we get the file size?&lt;BR /&gt;&lt;BR /&gt;Define "file size".  VMS normally keeps track&lt;BR /&gt;of the disk space occupied by a file, but&lt;BR /&gt;whether that can be translated into a useful&lt;BR /&gt;byte count can depend on what's in the file.&lt;BR /&gt;&lt;BR /&gt;To see what's really in a file:&lt;BR /&gt;&lt;BR /&gt;      HELP DUMP&lt;BR /&gt;&lt;BR /&gt;Don't expect to see actual CR or LF&lt;BR /&gt;characters in a non-stream record format&lt;BR /&gt;file.&lt;BR /&gt;&lt;BR /&gt;Is there some actual problem which you are&lt;BR /&gt;trying to solve?</description>
      <pubDate>Tue, 08 Feb 2011 20:15:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/using-hint-values-from-rms-to-get-filesize/m-p/4750189#M19338</guid>
      <dc:creator>Steven Schweda</dc:creator>
      <dc:date>2011-02-08T20:15:28Z</dc:date>
    </item>
    <item>
      <title>Re: Using hint values from rms to get filesize</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/using-hint-values-from-rms-to-get-filesize/m-p/4750190#M19339</link>
      <description>Tom,&lt;BR /&gt;&lt;BR /&gt;  Depends on what you mean by "filesize"&lt;BR /&gt;&lt;BR /&gt;  From DCL, F$FILE_ATTRIBUTES ALQ will give you the allocated disk space, some of which will probably be unused. &lt;BR /&gt;&lt;BR /&gt;&amp;gt; (2*record_count + data_count) for getting &lt;BR /&gt;&amp;gt;file size ... but then will it hold good &lt;BR /&gt;&amp;gt;for all the cases?&lt;BR /&gt;&lt;BR /&gt;  No. Metadata size depends on the record format, and record lengths as odd lengths are padded.&lt;BR /&gt;&lt;BR /&gt;  For sequential files, EOF and FFB can be used to find the space in use (including both data and metadata).&lt;BR /&gt;&lt;BR /&gt;  If positive, FILE_LENGTH_HINT should be accurate to give you the data size, but if it's negative (invalid) you'll need to count.</description>
      <pubDate>Tue, 08 Feb 2011 21:24:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/using-hint-values-from-rms-to-get-filesize/m-p/4750190#M19339</guid>
      <dc:creator>John Gillings</dc:creator>
      <dc:date>2011-02-08T21:24:13Z</dc:date>
    </item>
    <item>
      <title>Re: Using hint values from rms to get filesize</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/using-hint-values-from-rms-to-get-filesize/m-p/4750191#M19340</link>
      <description>Like this?&lt;BR /&gt;&lt;BR /&gt;$ filesize = F$FILE_ATTRIBUTES("LOGIN.COM","EOF") * 512 + F$FILE_ATTRIBUTES("LOGIN.COM","FFB") - 1&lt;BR /&gt;$ SHOW SYMBOL filesize&lt;BR /&gt;  FILESIZE = 2019   Hex = 000007E3&lt;BR /&gt;&lt;BR /&gt;This gives you the used space of a file with file organization = SEQ (=sequential).&lt;BR /&gt;&lt;BR /&gt;You didn't tell which file organization nor did you tell whether this is needed in a program or a command procedure. And then you didn't tell what you need that number for at all.&lt;BR /&gt;&lt;BR /&gt;I would give you 3 lemons for a poorly asked question. ;-)&lt;BR /&gt;&lt;BR /&gt;/Guenther</description>
      <pubDate>Wed, 09 Feb 2011 00:34:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/using-hint-values-from-rms-to-get-filesize/m-p/4750191#M19340</guid>
      <dc:creator>GuentherF</dc:creator>
      <dc:date>2011-02-09T00:34:26Z</dc:date>
    </item>
  </channel>
</rss>

