Announcement

Collapse
No announcement yet.

Rule on numeric digit

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Rule on numeric digit

    Hello !

    I have 2 folders with csv files and I have some diff.

    It's is possible to apply a rules to round numeric ?

    For example :

    File1:
    Hello,123456.456789,Bye

    File2:
    Hello,123456.456123,Bye

    I want to apply a round numeric after the 3 digit after the point "."

    Thanks

  • #2
    Hello,

    We do not support "rounding" in the text comparison, but you could open these files in the Data Compare, and set the numerical columns tolerance to mark that difference as unimportant.

    Depending on the structure of your files, you may need to define a Key column(s), which defaults to column 1 or can be disabled. And enable or disable sorting in the Session Settings dialog, under Columns: "Unsorted alignment".

    Let us know if you have any questions.
    Aaron P Scooter Software

    Comment


    • #3
      Similar issue

      I have a few fields that I'm trying to set up a default on and it's giving me some issues.

      I've set up a tolerance but the problem is the precision on the numbers vary.

      So in one instance I may have 0.505 vs 0.51 and somtimes I have 0.50515 vs 0.5052

      Usually it's part of the orignal number having a precision greater then the number we're comparing. Both numbers are correct, it's just the original version went out more decimals than we wanted.

      I have a feeling it's not possible as the decimal length changes (some are 2 vers 3, sometimes 4 vers 5 etc).

      THanks in advance.

      Comment


      • #4
        Hello,

        A difference in decimal does not matter for the Numeric Tolerance that can be defined for a Numeric column. Numbers should be treated as such and as long as the difference value is within the tolerance, it should be unimportant. Is it blue? Blue text is Unimportant, but treated as a Difference until Ignore Unimportant Differences (toggle) is enabled, hiding blue text as black.

        If you could email in:
        -a pair of sample files
        -a full screen screenshot
        -Your BCSupport.zip from the Help menu -> Support; Export (preferably with a saved session of the two example files)

        to [email protected] we can help analyze and compare your files. If you email, please include a link back to this forum thread for our reference. Thanks.
        Aaron P Scooter Software

        Comment


        • #5
          Regex approach

          What about using a regex rule to use first column (any data), second column that ends in the decimal point(integer portion), third column (important decimal portion), fourth (non-important decimal portion), fifth column, etc. ??


          Hello,123456.456789,Bye
          -----,------.+++---,---
          -1C--,---2C-.+3C-4C,-5C


          In the sample the fourth clolumn is the unimportant data (or discardable).
          Last edited by gmolleda; 28-Sep-2012, 08:51 PM.

          Comment


          • #6
            Hello,

            RegEx definitions in the Text Compare do not have conditions or layers. You can define the first column as Beginning of Line to the first delimiter, but defining the second column or third column would be tricky to do without also swallowing important data as part of the definition.

            What type of RegEx do you think would work to match on only the unimportant section of the 4th column? Or to match on only the Important section of the 4th column and Important sections of all other columns (the inverse, at which point Everything Else can be Unimportant).
            http://www.scootersoftware.com/suppo..._unimportantv3
            Aaron P Scooter Software

            Comment

            Working...
            X