tru64-unix-managers (formerly alpha-osf-managers) (1994-2012)
 help / color / mirror / Atom feed
* Text manipulation -Howto
@ 1999-10-20 10:56 Mark.Cuthbert
  0 siblings, 0 replies; only message in thread
From: Mark.Cuthbert @ 1999-10-20 10:56 UTC (permalink / raw)
  To: tru64-unix-managers


Hi guys,

I could do with some help with a script to manipulate a data-file so I can
substitute values "@" for "" (null).

The following is example output from dumping a database, where the dump
command does the opposite, ie where tha value is null in the database the
output has an @.

<snip>
2|10158086|34|21502169000342X|AU6|1|19950313|13/03/95,00001|C|1|94000000|@|
Y||@|@|19691231|0|@|
2|10158086|35|486191270001536|AU6|1|19950313|13/03/95,00001|C|1|94000001|@|
Y||@|@|19691231|0|@|
2|10158086|36|192070110001719|AU6|1|19950313|13/03/95,00001|C|1|94000002|@|
Y||@|@|19691231|0|@|
2|10158086|37|372011910003150|AU6|1|19950313|13/03/95,00001|C|1|94000003|@|
Y||@|@|19691231|0|@|
<snip>
1|10158086|80781|520449921000000|@|@|19950320|20/03/95,00237,SCAN &
DES|C|1|94080698|@|Y||@|@|19691231|0|@|
1|10158086|80782|206017190001215|Z|@|19950420|YORK,20/04/95,0003|C|1|940806
99|@|Y||@|@|19691231|0|@|
<snip>



I guess this should be simple  using sed/awk/perl etc. but I have not done
much text manipulation under UNIX.  One problem is that it may not be the
same field that has an @ in each record


Sorry for seeming dumb!


Regards

Mark Cuthbert
Yorkshire Water
UK


The information in this e-mail is confidential and may also be legally
privileged. The contents are intended for recipient only and are subject 
to the legal notice available at http://www.keldagroup.com/email.htm	
Kelda Group plc and its subsidiaries, UK 
Registered in England and Wales No 2366627

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1999-10-20 10:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1999-10-20 10:56 Text manipulation -Howto Mark.Cuthbert

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox