sed and recognizing a runtime parameter

I thought I posted this before, but cannot see the post, so will re-post.
Apologies if it now appears twice !

My script prompts for a 7 digit parameter : read f1
I then run a find command to search for files with $f1 in its contents :
find . -print | grep $f1 {file} > temp1
I then run a cut to extract only the characters I want :
cut -c25-33,47-62 temp1 > temp2.
temp2 should no longer have $f1 in its contents, as it was in columns 18-24 prior to the cut.
However, if I look at temp2, I can see the contents of $f1 in columns 20-26.
This is because there is a date/time combination at the row end, & the format of jobno can fit .
Eg jobno 8100029
A row from temp2 : Z12345678ZZZ07012008100029

Is there a sed command that will allow me to delete these rows if I find pattern $f1 present ?

I tried export f1 and then sed �s/${f1}/d�
but got a garbled command message.

Many thanks !

There is a variety of ways to remove a record with a specific pattern.

One of them is:

egrep -v "${f1}" inp_file