Sponsored Content
Top Forums Shell Programming and Scripting use awk to read variable length csv Post 302121203 by shweta_d on Tuesday 12th of June 2007 11:31:14 AM
Old 06-12-2007
Thanks a ton.... Smilie
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

creating a fixed length output from a variable length input

Is there a command that sets a variable length? I have a input of a variable length field but my output for that field needs to be set to 32 char. Is there such a command? I am on a sun box running ksh Thanks (2 Replies)
Discussion started by: r1500
2 Replies

2. Shell Programming and Scripting

Using awk to search variable length records

New to awk and need some help. I have a script that I would like to make more compact. I want to read a file and grab every field, from every record, except the last field. The records are variable length and have varying number of fields. A record will have at least two fields, but can have... (9 Replies)
Discussion started by: synergy_texas
9 Replies

3. Shell Programming and Scripting

Read the csv file and assign the values in to variable

I have a csv file with the values seperated by commas.I want to extract these values one by one and assign to a variable using shell script.Any ideas or code? (11 Replies)
Discussion started by: rajbal
11 Replies

4. Shell Programming and Scripting

Split variable length and variable format CSV file

Dear all, I have basic knowledge of Unix script and her I am trying to process variable length and variable format CSV file. The file length will depend on the numbers of Earnings/Deductions/Direct Deposits. And The format will depend on whether it is Earnings/Deductions or Direct Deposits... (2 Replies)
Discussion started by: chechun
2 Replies

5. Shell Programming and Scripting

changing a variable length text to a fixed length

Hi, Can anyone help with a effective solution ? I need to change a variable length text field (between 1 - 18 characters) to a fixed length text of 18 characters with the unused portion, at the end, filled with spaces. The text field is actually field 10 of a .csv file however I could cut... (7 Replies)
Discussion started by: dc18
7 Replies

6. UNIX for Dummies Questions & Answers

Writing awk script to read csv files and split them

Hi Here is my script that calls my awk script #!/bin/bash set -x dir="/var/local/dsx/csv" testfile="$testfile" while getopts " f: " option do case $option in f ) testfile="$OPTARG";; esac; done ./scriptFile --testfile=$testfile >> $dir/$testfile.csv It calls my awk... (1 Reply)
Discussion started by: ladyAnne
1 Replies

7. Shell Programming and Scripting

Parse variable length status,timestamp CSV

I have the output of a process which on status change of the object being processed appends status,timestamp to the record in the text file... so i end up with output something like: task123,TERMINAL,glob,5,INITIAL,2012-02-27 16:48:07,PREPARING,2012-02-27 16:49:06,SCHEDULED,2012-02-27... (2 Replies)
Discussion started by: KarmaPoliceT2
2 Replies

8. Shell Programming and Scripting

awk read column csv and search in other csv

hi, someone to know how can i read a specific column of csv file and search the value in other csv columns if exist the value in the second csv copy entire row with all field in a new csv file. i suppose that its possible using awk but i m not expertise thanks in advance (8 Replies)
Discussion started by: giankan
8 Replies

9. UNIX for Advanced & Expert Users

How to read variable length file on UNIX generated by Mainframe?

Hi All, We have variable block file generated on Mainframe. We have to process the file on unix. So we FTPed the file on binary (as it has packed decimal fields). but i don't know how to read the file on unix. As you know variable block file will have a data like record length followed by... (2 Replies)
Discussion started by: SundarGampa
2 Replies

10. UNIX for Dummies Questions & Answers

Help with awk, where line length and field position are variable

I have several questions about using awk. I'm hoping someone could lend me a hand. (I'm also hoping that my questions make sense.) I have a file that contains pipe separated data. Each line has similar data but the number of fields and the field position on each line is variable. ... (3 Replies)
Discussion started by: Cheese64
3 Replies
MPIL_Trace_off(3)						      LAM/MPI							 MPIL_Trace_off(3)

NAME
MPIL_Trace_off - LAM/MPI-specific function to disable run-time tracing SYNOPSIS
#include <mpi.h> int MPIL_Trace_off(void) NOTES
These functions give the application the flexibility to generate traces only during certain interesting phases of the application's execu- tion. This technique can considerably reduce the size of the trace files and burden of displaying them. Both functions are collective over the MPI_COMM_WORLD communicator. In typical usage, the -toff option of mpirun (1) would be used to enable tracing, but start with the runtime switch in the off position. At the beginning of an interesting phase of program execution, MPIL_Trace_on would be called. MPIL_Trace_off would be called after the interesting phase. Tracing can be turned on and off many times. Each period of tracing eventually forms a trace segment in the trace file extracted by lamtrace (1). If the on/off functions are never used and tracing is enabled with the -ton option of mpirun (1), a single trace segment is produced. The on/off functions have no effect if tracing is not enabled by mpirun (1) with either the -ton or -toff switches. Thus, an application can be littered with these functions but run without trace collection and very little additional overhead due to the no-operation function calls. This is a LAM/MPI-specific function and is intended mainly for debugging. If this function is used, it should be used in conjunction with the LAM_MPI C preprocessor macro #if LAM_MPI MPIL_Trace_off(); #endif LIMITATIONS
After the volume of generated traces exceeds a preset limit, the oldest traces are discarded in favour of new traces. Avoiding discarded traces is further incentive to use MPIL_Trace_on and MPIL_Trace_off . NOTES FOR FORTRAN
All MPI routines in Fortran (except for MPI_WTIME and MPI_WTICK ) have an additional argument ierr at the end of the argument list. ierr is an integer and has the same meaning as the return value of the routine in C. In Fortran, MPI routines are subroutines, and are invoked with the call statement. All MPI objects (e.g., MPI_Datatype , MPI_Comm ) are of type INTEGER in Fortran. ERRORS
If an error occurs in an MPI function, the current MPI error handler is called to handle it. By default, this error handler aborts the MPI job. The error handler may be changed with MPI_Errhandler_set ; the predefined error handler MPI_ERRORS_RETURN may be used to cause error values to be returned (in C and Fortran; this error handler is less useful in with the C++ MPI bindings. The predefined error handler MPI::ERRORS_THROW_EXCEPTIONS should be used in C++ if the error value needs to be recovered). Note that MPI does not guarantee that an MPI program can continue past an error. All MPI routines (except MPI_Wtime and MPI_Wtick ) return an error value; C routines as the value of the function and Fortran routines in the last argument. The C++ bindings for MPI do not return error values; instead, error values are communicated by throwing exceptions of type MPI::Exception (but not by default). Exceptions are only thrown if the error value is not MPI::SUCCESS . Note that if the MPI::ERRORS_RETURN handler is set in C++, while MPI functions will return upon an error, there will be no way to recover what the actual error value was. MPI_SUCCESS - No error; MPI routine completed successfully. MPI_ERR_OTHER - Other error; use MPI_Error_string to get more information about this error code. SEE ALSO
MPI_Trace_on, mpirun LOCATION
mpil_trace.c LAM
/MPI 7.1.4 6/24/2006 MPIL_Trace_off(3)
All times are GMT -4. The time now is 01:59 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy