in reply to Replacing spaces

Is your data maybe not "space delimited" but "fixed width records"? Then, the usual approach is to use unpack to extract the interesting parts of the data. I'm very fond of BrowserUk's Re: Fixed Position Column Records to programmatically find the columns and the unpack template for me.

Replies are listed 'Best First'.
Re^2: Replacing spaces
by apachi15 (Initiate) on Apr 07, 2009 at 12:13 UTC
    It is space delimited and always with a diiferent amount of spaces.Martin

      Looking at your original data (and not the horribly munged copy'n'paste above), it's clear to me that the data you have is fixed width data. So just use unpack, possibly together with the tool I linked to to produce the column specification.

      Let me also suggest you take a more mechanical approach to looking at your data than "I know the data so I know that there is a value missing". You need to be more exact about why you know that there is a value missing, like because every time there is a value, it appears in the same position.