Results 1 to 4 of 4
  1. #1
    Join Date
    Jun 2010
    Posts
    2

    Default Selecting list of columns to ignore in csv file

    Hi,
    I was wondering if anyone can help me with this issue. I tried to search and found following page which is not helpful as Comma Separated format which is inbuilt to beyond compare does not have grammer tab and then if I create a new format it is unclear how that really works and how do I tell it to specify that the files are in csv format.
    Anyways my problem is simple and is in two parts. I have following two files:

    File1.txt
    Country,Time,GMTOffset,Value
    US,10:30:10,+5,50
    UK,20:30:20,+0,50
    AUS,9:30:30,+10,80


    File2.txt
    Country,Time,GMTOffset,Value
    US,10:30:40,+4,50
    UK,20:30:60,+1,50
    AUS,9:30:20,+11,80

    So, differences are the 3rd column (GMTOffset) and the seconds in the Time column.

    Problem 1:
    When I compare the two files how can I specify that I want to ignore column 3 (GMTOffset) when doing the comparison.

    Problem 2:
    When I compare the two files how can I specify to ignore seconds field i.e. in column 2 of csv file ignore the 3rd field in the value which is seperated by ':'. Or something along that sort.

    So, basically when I apply this rules beyondcompare will tell me that the two files are identical.

    Help would be very much appreciated as I am pretty sure that BeyondCompare supports features like that.

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

    Default

    Hello,

    This can be done using our Data Compare session type, with one minor change. In one of your sample files, you list the seconds as :60. This is not a supported time format. If you change your seconds to range from 00 to 59, then these files will work automatically in the Data Compare.

    First, load your pair of files in our Data Compare. Right click the column header for column 3, and change it from a Standard Column to an Unimportant column.

    Then go to the Session Settings, select a cell in the Time row, and Edit it. Set the date tolerance to 59 seconds.

    How does that work for you?
    Aaron P Scooter Software

  3. #3
    Join Date
    Jun 2010
    Posts
    2

    Default

    thanks a lot for that. I knew it was something trivial. I was using Text Compare to do all our comparisons. Thanks about the time as well. This is a great tool.

  4. #4
    Join Date
    Oct 2007
    Location
    Madison, WI
    Posts
    11,616

    Default

    If you needed any particular Text Compare functionality, we may be able to get this setup in there as well. However, our Data Compare was built to handle files like this and is pretty easy to setup.
    Aaron P Scooter Software

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
  •