I have below file with me :-
====== 20160606:034441 ====== Mango(Test)
TestName MangoT
Row 0
Season N
Name Safeda
Location Delhi
====== 20160606:034441 ====== Mango(Result)
TestName MangoR
Result 0
No_of_Mango 13
Quantity 2
Quantity 3
Quantity 6
Quantity 0
Quantity 1
Quantity 9
Quantity 54
Quantity 2
Quantity 4
Quantity 6
Quantity 76
Quantity 0
Quantity 99
Price 50
Price 70
Price 40
Price 30
Price 40
Price 30
Price 20
Price 60
Price 70
Price 80
Price 90
Price 30
Price 30
====== 20160606:034441 ====== Mango(Test)
TestName MangoT
Row 0
Season N
Name Alphonso
Location Mumbai
====== 20160606:034441 ====== Mango(Result)
TestName MangoR
Result 0
No_of_Mango 13
Quantity 5
Quantity 3
Quantity 1
Quantity 0
Quantity 7
Quantity 8
Quantity 70
Quantity 3
Quantity 23
Quantity 43
Quantity 734
Quantity 2
Quantity 929
Price 50
Price 70
Price 40
Price 30
Price 40
Price 30
Price 20
Price 60
Price 70
Price 80
Price 90
Price 30
Price 30
Now i need two input files from above file based on Mango Name like :-
FileName :- safeda.txt
TestName MangoR
Result 0
No_of_Mango 13
Quantity 2
Quantity 3
Quantity 6
Quantity 0
Quantity 1
Quantity 9
Quantity 54
Quantity 2
Quantity 4
Quantity 6
Quantity 76
Quantity 0
Quantity 99
Price 50
Price 70
Price 40
Price 30
Price 40
Price 30
Price 20
Price 60
Price 70
Price 80
Price 90
Price 30
Price 30
2nd FileName :- Alphonso.txt
TestName MangoR
Result 0
No_of_Mango 13
Quantity 5
Quantity 3
Quantity 1
Quantity 0
Quantity 7
Quantity 8
Quantity 70
Quantity 3
Quantity 23
Quantity 43
Quantity 734
Quantity 2
Quantity 929
Price 50
Price 70
Price 40
Price 30
Price 40
Price 30
Price 20
Price 60
Price 70
Price 80
Price 90
Price 30
Price 30
I need to create these 2 files using shell script.