Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Open Source > Linux
| Search | Today's Posts | Mark Forums Read
Linux General discussion of programming the various flavors of Linux operating systems.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Linux section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 2nd, 2007, 04:50 PM
Registered User
 
Join Date: Aug 2007
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Masking flat file

Hello,
I have a typical requirement.
I have a flat file which is a fixed length one.
In this flat file from 3rd position to 21st position (i.e 19 characters) is allocated for the acc #. The acc # may not be of full length. The length can vary from 10-19 characters.

Now my requirement is that I need to replace this acc # in such a way that leaving the first 6 digits and last 4 digits the remaining digits should be 0.

Eg.
123456789108738
8399456789911117386
5734567893333333

output
123456000008738
8399450000000007386
5734560000003333

As i posted something similar to this few days back at that time the requirement was different; sed work for me
Now as far as my knowledge goes first of all we need to find out the length of the acc #


Thanks to all for their help






Similar Threads
Thread Thread Starter Forum Replies Last Post
Fetching fields from Flat File praveennk84 SQL Server 2000 14 November 22nd, 2006 01:13 AM
How to open up a flat file daniel_arney Beginning VB 6 1 September 27th, 2006 02:40 PM
Need help with my Flat File Schema cmiller66 Biztalk 0 August 21st, 2006 10:48 PM
flat file login new2php PHP How-To 0 February 7th, 2006 07:02 AM
Problem using positional flat file Sameer_Borikar Biztalk 0 March 3rd, 2005 08:11 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.