Tags

,

Recently I had to to compare data created by two software applications. While each stores data in a native, binary format, they are capable of exporting it to CSV as well as XML formats. I had started using one application for storing data, but wanted to shift to another application. So I wrote a simple converter for this purpose. In order to ensure that the data was correctly transferred, I had to manually compare the data.

For this purpose, I exported the data to XML format and started comparing data from each file. As the XML files are generated by different applications, they generate data in differing formats and direct file difference is not possible.

While comparing the files in Notepad++, I noted that due to the XML format, Notepad++ puts markers in the left border of the editor, where blocks can be collapsed and expanded. This particular feature turned out to be a boon. This is what i did.

After identifying the element to be compared in both files, I manually verified the data. If the data was found to be same, I collapsed the block in each of the files and deleted it in one shot. Without the collapse facility, I would have had to select multiple lines in each file before deleting them. With this feature, I had to use one mouse click to collapse the block and then one selection followed by a delete command.

I found it to be very convenient.

Advertisements