Compare two memo fields

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ivandzhurkov
    New User
    • Apr 2008
    • 2

    Compare two memo fields

    My goal is programmatically to compare two memo fields from two different records of MS SQL Database and to place the result in a HTML file. To do that I’ll put each memo in temporary text file. Then I’ll create a script file that will contain references to these files and will run BC with script file name as parameter, right?
    Can someone provide me with a sample script that does a pair of files comparison and saves the result in html file?

    Thanks in advance,
    Ivan
  • Aaron
    Team Scooter
    • Oct 2007
    • 16017

    #2
    Re: Compare two memo fields

    You probably want to use our Generating a report example. In the Help menu->Contents(F1). Then go to the Command Line and Scripting Section->Sample Scripts.

    The Text of the script is:
    file-report layout:side-by-side &
    options:ignore-unimportant,display-context &
    output-to:%3 output-options:html-color %1 %2

    Where %1,%2,%3 are parameters after the script call: "bc2.exe @scriptname <var1> <var2> <var3>

    For more information on customizing the file-report command, you can look at the reference information under the Scripting Reference section. I recommend using the application interactively to generate a report first, so you know which options you would like to use.

    If you have any other questions, just let us know.
    Aaron P Scooter Software

    Comment

    • ivandzhurkov
      New User
      • Apr 2008
      • 2

      #3
      Re: Compare two memo fields

      Thanks a lot Aaron. I've it tested and it works fine.

      Comment

      • wiramen
        New User
        • Jan 2010
        • 1

        #4
        Re: Compare two memo fields

        How do I use scripting to compare 2 database memo fields without putting them in temporary text files, I can save them in variables, clipboards, etc. I intentionally save my test results (text-based) in database instead of files to avoid any file i/o or network issues. I have BC2 & BC3 and I need to automate the comparison process (no GUI, only command lines), please let me know if I can:
        * Use any of the command line executables to compare 2 strings in memory (variables, clipboards, etc.) ?
        * Use scripting to create a diff report of the 2 strings ?

        Thanks,
        Wiramen
        p.s. GO BADGERS!!

        Comment

        • Aaron
          Team Scooter
          • Oct 2007
          • 16017

          #5
          Unfortunately, this is currently not supported in Beyond Compare 3.

          We support outputting to the clipboard, but you will need to have temp files to input from the command line or with Script.

          The graphical interface supports an "Open Clipboard" command to open the clipboard on one side of the compare, or the other.

          Script can be used to create a diff report between two files. Use the Text-Report command. Detailed documentation can be found in the Help file under Scripting Reference, or Using Beyond Compare -> Automating with Scripting.
          Aaron P Scooter Software

          Comment

          Working...