2 Replies Latest reply on Jun 4, 2019 8:34 AM by happy10319

    grep & echo

    happy10319

      Hi,

      I have a file Addressbook.txt

      Content is:

      John Smith: 54321:john@smith.example.com

      John Abarak: 54356:john@abarak.example.com

      Timn Kith: 76321:timn@kith.example.com

       

      I run:

       

      myrow=$(grep -i John Addressbook.txt)

      echo $myrow

       

      the out put is :

      John Smith: 54321:john@smith.example.com John Abarak: 54356:john@abarak.example.com

       

      How can I have two different lines with echo?

       

      Thanks.