Please need some help how to replace only "text" with "update"
Eg:
i have data as below and first record "text" need to change to "update" and not other records
input file
------------
text -> only this record need to replace
text name
text city
text address
output file
-------------
update
text name
text city
text address
I have tried with s/text/update/g; all records are updated instead of first record