BookmarkSubscribeRSS Feed
gyambqt
Obsidian | Level 7

For example I have two log files: A and B

A has

a

b

c

 

B has

c

b

c

 

So I want to compare the two files line by line and put the difference in another table such as

 

tablename=Compare_result

line_no      records_from_a   records_from_b   

1                          a                      c                

6 REPLIES 6
Patrick
Opal | Level 21

SAS logs are unstructured text and will differ between executions starting with the execution date. Any small change in logging options will cause changes to the SAS log and especially on which line log messages appear. 

 

I suggest you take a more targeted approach for what you want to collect and let us know. 

 

Below links should be of interest for you.

Track Performance in SAS with the LOGPARSE Macro

SAS® 9.4 Logging: Configuration and Programming Reference, Second Edition

SCAPROC Procedure

SAS® 9.4 Interface to Application Response Measurement (ARM): Reference

 

Ksharp
Super User
Using the third side software, like : WinMerge
Quentin
Super User
Looks for any utility that does comparison of text files. Notepad++, UltraEdit, DIFF, I'm a big fan of BeyondCompare.
BASUG is hosting free webinars Next up: Mark Keintz presenting History Carried Forward, Future Carried Back: Mixing Time Series of Differing Frequencies on May 8. Register now at the Boston Area SAS Users Group event page: https://www.basug.org/events.
Patrick
Opal | Level 21

@Quentin wrote:
Looks for any utility that does comparison of text files. Notepad++, UltraEdit, DIFF, I'm a big fan of BeyondCompare.

Me too! I'm a long time BeyondCompare user and never seen a "better" utility for text comparison that's so rich in functionality yet so intuitive to use.

SASKiwi
PROC Star

For what purpose do you want to compare log files?

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 6 replies
  • 577 views
  • 0 likes
  • 5 in conversation