Hi..

I have 2 files of data..

File 1 = id,name

eg:

0001, J Smith
0002, J Smithers
0003 J Smith Thomas


File 2 = general text, with names recorded at different locations..

eg.

This is random text for with J Smith, J Smithers and J Smith Thomas

I am trying to replace all J Smiths with J Smith 0001 and J Smithers with J
Smithers 0002, etc...

I cannot use:

for ($i=0;$i<=$#id;$i++) {
    $randomtext =~ s/$name[$i]/$name[$i] $id[$i]/g
}

This does not give the desired result... Gives names with dual IDs, or
incorrect IDs..

Any hints on how I can solve this..

Thanks
Ash

--
Ash Varma
[EMAIL PROTECTED]
[EMAIL PROTECTED]

The browser you can trust! Get Firefox and rediscover the web!
http://www.getfirefox.com/

Reply via email to