Results 1 to 3 of 3
  1. #1
    Join Date
    Dec 2017
    Posts
    2

    Default Positional comparison for fixed-width flat files

    Is there a way of telling BC4 to compare strictly on the basis of character positions when doing a text compare of two fixed-width flat files? Sometimes the comparator identifies "sameness" which is really a change, and this is apparent to the human who knows the fixed-width nature of the file. It appears that BC is treating these changes as more of a spelling correction than anything else.

    For example, the left side of my BC session has 20171001 starting in column 1427. In the same position on the right side it reads 00000000.

    If one views this as a word, then the argument could be made that the spelling was corrected and the two adjacent zeros were common to both the left- and right-side files. If one views this positionally, then clearly the rightmost character has changed from a 1 on the left to a 0 on the right, and overall the two sides would be color-highlighted as 20171001 and 00000000.
    Last edited by Bob Gaydos; 06-Dec-2017 at 11:41 AM.

  2. #2
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,893

    Default

    Hello,

    In the Text Format, you can enable Column-based data in the Misc tab. You can click the Format button on the toolbar or in the Tools menu -> File Format dialog (then select your format or the default format, or create a new Text format). In the Misc tab, enable "column-based data".

    A file format is generally assigned to a specific file mask, such as *.ext or *.txt.
    Aaron P Scooter Software

  3. #3
    Join Date
    Dec 2017
    Posts
    2

    Default

    Thanks, Aaron - that did the trick!

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •