08-07-2014
Added the qoute to sample that I had provided.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I am using the following command at the Unix prompt to make my 'infile' into a fixed width file of 100 characters.
awk '{printf "%-100s\n",$0}' infile > outfile
However, there are some records with a special character "©"
These records are using 3 characters in place of one and my record... (2 Replies)
Discussion started by: alok.benjwal
2 Replies
2. Shell Programming and Scripting
Hi,
How to replace any character in a file with a newline character using sed ..
Ex:
To replace ',' with newline
Input:
abcd,efgh,ijkl,mnop
Output:
abcd
efgh
ijkl
mnop
Thnx in advance.
Regards,
Sasidhar (5 Replies)
Discussion started by: mightysam
5 Replies
3. Shell Programming and Scripting
I have some huge files that are produced daily from a production system written in basic (really). The files are fixed width records, 512 bytes, with newline field separators, newlines if the field is null, and trailing newlines for null fields. The data in the fields can be any ascii... (0 Replies)
Discussion started by: vtischuk@yahoo.
0 Replies
4. Shell Programming and Scripting
Hi All,
I have created a script which generates FIXED-WIDTH file by executing Oracle query.
SELECT RPAD(NVL(col1,CHR(9)),20)||NVL(col2,CHR(9))||NVL(col3,CHR(9) FROM XYZ
It generates the data file with proper alignment. But if same file i transfer to windows server or Mainframe... (5 Replies)
Discussion started by: Amit.Sagpariya
5 Replies
5. Shell Programming and Scripting
I have a file with different record length. The file as to be converted into fixed length by appending spaces at the end of record. The length should be calculated based on the record with maximum length in the file.
If the length is less than the max length, the spaces should be appended... (4 Replies)
Discussion started by: Amrutha24
4 Replies
6. UNIX for Dummies Questions & Answers
I have a fixed width file of length 53. when is try to get the lengh of the record of that file i get 2 different answers.
awk '{print length;exit}' <File_name>
The above code gives me length 50.
wc -L <File_name>
The above code gives me length 53.
Please clarify on... (2 Replies)
Discussion started by: Amrutha24
2 Replies
7. Shell Programming and Scripting
I have a fixed with file with header & trailer length having the same length of the detail record file.
The details record length of this file is 24, for Header and Trailer the records will be padded with spaces to match the record length of the file
Currently I am adding 3 spaces in header... (14 Replies)
Discussion started by: ginrkf
14 Replies
8. Shell Programming and Scripting
Thank u so much .Its working fine as expected.
---------- Post updated at 03:41 PM ---------- Previous update was at 01:46 PM ----------
I need one more help.
I have another file(fixed length) that will get negative value (ex:-00000000003000) in postion (98 - 112) then i have to... (6 Replies)
Discussion started by: vinus
6 Replies
9. Shell Programming and Scripting
All,
I used to use following command to replace specific location in a fixed width file.
Recently looks like my command stopped working as intended. We are on AIX unix.
awk 'function repl(s,f,t,v)
{ return substr(s,1,f-1) sprintf("%-*s", t-f+1, v) substr(s,t+1) }
NR<=10 {... (3 Replies)
Discussion started by: pinnacle
3 Replies
10. Shell Programming and Scripting
Hi Forum.
I tried searching for a solution using the internet search but I haven't been able to find any solution for what I'm trying to accomplish.
I have a fixed width column file where I need to search for any occurrences of "D0" in col pos.#1-2, 10-11, 20-21 and replaced it with "XD".
... (2 Replies)
Discussion started by: pchang
2 Replies
LEARN ABOUT DEBIAN
buildapp
BUILDAPP(1) User Commands BUILDAPP(1)
NAME
buildapp - application to create common lisp images
SYNOPSIS
buildapp --output OUTPUT-FILE [--flag1 value1 ...]
DESCRIPTION
Required flags:
--output OUTPUT-FILE
Use OUTPUT-FILE as the name of the executable to create
Entry-point flags:
--entry NAME
Use the function identified by NAME as the executable's toplevel function. Called with SB-EXT:*POSIX-ARGV* as its only argument. If
NAME has a colon, it is treated as a package separator, otherwise CL-USER is the implied package.
--dispatched-entry DNAME
Specify one possible entry function, depending on the name of the file that is used to start the application. The syntax of DNAME is
APPLICATION-NAME/ENTRY-NAME. If the name used to start the executable matches APPLICATION-NAME, use ENTRY-NAME as the entry point.
This can be used to choose one of many possible entry points by e.g. symlinking names to the application executable. If APPLICA-
TION-NAME is empty, the specified ENTRY-NAME is used as a default if no other application names match. There may be any number of
dispatched entry points, but only one default.
Action flags:
--load FILE
Load FILE. CL:*PACKAGE* is bound to the CL-USER package before loading
--load-system NAME
Load an ASDF system identified by NAME
--require NAME
Use CL:REQUIRE to load NAME
--eval CODE
Use CL:EVAL to evaulate CODE. The code is read with CL:READ-FROM-STRING in the CL-USER package
There may be any number of load/load-system/require/eval flags. Each is executed in command-line order before creating an executable.
Load path flags:
--load-path DIRECTORY
When handling a --load, search DIRECTORY for files to load
--asdf-path DIRECTORY
When handling a --load-system, search DIRECTORY for ASDF system files to load
--asdf-tree DIRECTORY
When handling a --load-system, search DIRECTORY and all its subdirectories for ASDF system files to load
There may be any number of load-path/asdf-path/asdf-tree flags. asdf-path arguments take precedence over asdf-tree arguments.
Other flags:
--help Show this usage message
--logfile FILE
Log compilation and load output to FILE
--sbcl PATH-TO-SBCL
Use PATH-TO-SBCL instead of the sbcl program found in your PATH environment variable
For the latest documentation, see http://www.xach.com/lisp/buildapp/
buildapp 1.1 July 2010 BUILDAPP(1)