I have a flat file and need to count no of records in the file less the header and the trailer record.
I would appreciate any and all asistance
Thanks
Hadi Lalani (2 Replies)
Hello,
after 9 months of archiving 1000 files,
now, i need to change the order of fields in the header record.
some very large, space padded files.
HEADERCAS05212008D0210DOMEST01(spacepadded to record length 210)
must now be
05212008HEADERCASD0210DOMEST01(spacepadded to record length 210)
... (1 Reply)
A header record is to be inserted in the begining of a flat file without using extra file or new file. It should be inserted into same file. Advace thanks for all help... (7 Replies)
Hi All,
I have got a requirement.
I have a source file, EMPFULL.txt and I need to split the data for every 30 records
and place a Typical Header as below with system and page number too.
2012.01.03 Employee Dept Report 1... (6 Replies)
I have 2 files
"File 1" is delimited by ";" and "File 2" is delimited by "|".
File 1 below (3 record shown):
Doc1;03/01/2012;New York;6 Main Street;Mr. Smith 1;Mr. Jones
Doc2;03/01/2012;Syracuse;876 Broadway;John Davis;Barbara Lull
Doc3;03/01/2012;Buffalo;779 Old Windy Road;Charles... (2 Replies)
All,
I currently have a requirement to fetch a Date value from a table. And then insert a Header record into a file along with that date value.
ex:
echo "HDR"" "`date +%Y%j` `date +%Y%m%d`
In the above example I used julian date and standard date using Current Date. But the requirement... (0 Replies)
I'm using a shell script to manipulate a data file. I have a large file with two sets of data samples (tracking memory consumption) taken over a long period of time, so I have many samples. The problem is that all the data is in the same file so that each sample contains two sets of data.... (2 Replies)
Hi,
I have a backup report that unfortunately has some kind of hanging indent thing where the first line contains one column more than the others
I managed to get the output that I wanted using awk, but just wanting to know if there is short way of doing it using the same awk
Below is what... (2 Replies)
Hi Experts,
I have csv file with 30, 40 columns
Pasting just 2 column for problem description.
Need to print error if below combination is not present in file
check for column-1 (DocumentNumber) and filter columns where value in DocumentNumber field is same.
For all such rows, the field... (7 Replies)
Discussion started by: as7951
7 Replies
LEARN ABOUT DEBIAN
cdbmake
cdbmake(1) General Commands Manual cdbmake(1)NAME
cdbmake - create a constant database
SYNOPSIS
cdbmake cdb cdb.tmp
DESCRIPTION
cdbmake reads a series of encoded records from its standard input and writes a constant database to cdb.
cdbmake ensures that cdb is updated atomically, so programs reading cdb never have to wait for cdbmake to finish. It does this by first
writing the database to cdb.tmp and then moving cdb.tmp on top of cdb. If cdb.tmp already exists, it is destroyed. The directories con-
taining cdb.tmp and cdb must be writable to cdbmake; they must also be on the same filesystem.
cdbmake always makes sure that cdb.tmp is safely written to disk before it replaces cdb. If the input is in a bad format or if cdbmake has
any trouble writing cdb.tmp to disk, cdbmake complains and leaves cdb alone.
RECORD FORMAT
Records are indexed by keys. A key is a string. cdb is structured so that another program, starting from a key, can quickly find the rel-
evant record. cdbmake allows several records with the same key, although most readers take only the first record, and cdbmake slows down
somewhat if there are many records with the same key.
cdbmake and cdbdump(1) preserve the order of records.
A record is encoded for cdbmake as +klen,dlen:key->data followed by a newline. Here klen is the number of bytes in key and dlen is the
number of bytes in data. The end of data is indicated by an extra newline. For example:
+3,5:one->Hello
+3,7:two->Goodbye
key and data may contain any characters, including colons, dashes, newlines, and nulls.
Keys and data do not have to fit into memory. A database cannot exceed 4 gigabytes.
cdb is portable across machines.
SEE ALSO cdbdump(1), cdbget(1), cdbstats(1)cdbmake(1)