Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 1234,Joe,pieter,joe@gmail.com,male,22
- 1235,Shally,Jonse,shally@yahoo.com,female,24
- 1235,Harry,poter,harry@gmail.com,male,21
- 1235,Helen,Jairag,helen@gmail.com,female,21
- 2585,Dinesh,Jairag,helen@gmail.com,female,21
- 1234,Joe,pieter,joe@gmail.com,male,22
- 1235,Shally,Jonse,shally@yahoo.com,female,24
- 1235,Harry,Potter,harry@gmail.com,male,21
- 1235,Helen,Jairag,helen@gmail.com,female,21
- diff F2 F1
- 3c3
- < 1235,Harry,Potter,harry@gmail.com,male,21
- ---
- > 1235,Harry,poter,harry@gmail.com,male,21
- 4a5
- > 2585,Dinesh,Jairag,helen@gmail.com,female,21
- 1235,Harry,poter,harry@gmail.com,male,21
- 2585,Dinesh,Jairag,helen@gmail.com,female,21
- diff --changed-group-format='%<' --unchanged-group-format='' file1 file2
- diff -u File1 File2
- --- File1 2012-08-22 11:30:07.000000000 +0200
- +++ File2 2012-08-22 11:30:25.000000000 +0200
- @@ -1,5 +1,4 @@
- 1234,Joe,pieter,joe@gmail.com,male,22
- 1235,Shally,Jonse,shally@yahoo.com,female,24
- -1235,Harry,poter,harry@gmail.com,male,21
- +1235,Harry,Potter,harry@gmail.com,male,21
- 1235,Helen,Jairag,helen@gmail.com,female,21
- -2585,Dinesh,Jairag,helen@gmail.com,female,21
- diff -u data1 data2 |
- awk 'NR > 2 && $0 ~ /^+/ {print substr($0,2)}'
- 1235,Harry,Potter,harry@gmail.com,male,21
- diff -u data2 data1 |
- awk 'NR > 2 && $0 ~ /^+/ {print substr($0,2)}'
- 1235,Harry,poter,harry@gmail.com,male,21
- 2585,Dinesh,Jairag,helen@gmail.com,female,21
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement