07-17-2008
Quote:
Originally Posted by
joeyg
Quotes inside quoted field - yech.
Can you count comma's then, using similar logic to my 3rd option? Or, are there comma's inside the quotes also? That is quite possible.
Perhaps try the first or second options?
The 2nd will show how many lines begin with a " character - in theory, your continued lines would not begin with a quote character.
Beyond the counting... good luck trying to decipher the file!
Second option worked..Thanks alot Joey!
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi
Guys
I have downloaded a table from oracle database in .csv format. it has many fields as Title, First Name, Last Name etc. I have to download distinct titles from database and now i have to check all those titles from data of First Name one by one. and then i have to delete matched record.... (1 Reply)
Discussion started by: Rajeev Agrawal
1 Replies
2. UNIX for Dummies Questions & Answers
How do I get the record count in an EBCDIC file on a Linux Box. :confused: (1 Reply)
Discussion started by: oracle8
1 Replies
3. UNIX for Dummies Questions & Answers
HI ,
I am new to shell scripting ,
I have a requirement that
I send a file for data quality ( original.csv) & i will be getting 4 files daily into a particular directory in return with cleansed data .
the files may be clean.csv,
unclean.csv ,
... (2 Replies)
Discussion started by: sirik
2 Replies
4. Shell Programming and Scripting
i use unix command to take the record count for a file1
awk 'END{print NR}' filename
i already have a file2 which conatin the count like
...
..
rec_cnt=100
..
..
I want to replace the record in the file2 using the record i take from file1.
suggest me some simple ways of doing it... (2 Replies)
Discussion started by: er_zeeshan05
2 Replies
5. Shell Programming and Scripting
Hi
I receive a mainframe file which has very long records (1100 chars) with no field delimiters. I need to parse each record and output a comma delimited (csv) file. The record layout is fixed. If there weren't so many fields and records I would read the file into Excel, as a "fixed width"... (10 Replies)
Discussion started by: wvdeijk
10 Replies
6. Shell Programming and Scripting
Hi,
I have a script which creates and modifies a csv file.
I have managed to do everything I need to do apart from 1 thing. I need to append a trailer record to the file. I need this line to hold the total of an entire column of the csv file (skipping the 1st line which is a header).
Can... (2 Replies)
Discussion started by: mcclunyboy
2 Replies
7. Shell Programming and Scripting
HI,
I need to print the record count of a file using shell script.
If the record count of a file excluding header and trailer record if greater than zero then print 'Record count of a file is xxxx records'.
If the record count is zero print 'zero records'
Thanks
Mahendra (1 Reply)
Discussion started by: mmeda
1 Replies
8. Shell Programming and Scripting
Hi,
I have to output a new csv file from an input csv file with first unique value in the first column.
input csv file
color product id status
green 102 pass
yellow 201 hold
yellow 202 keep
green 101 ok
green 103 hold
yellow 203 ... (5 Replies)
Discussion started by: Chris LAU
5 Replies
9. Shell Programming and Scripting
Hi,
Very good wishes to all!
Please help to provide the shell script for generating the record counts in filed wise from the .csv file
My question:
Source file:
Field1 Field2 Field3
abc 12f sLm
1234 hjd 12d
Hyd 34
Chn
My target file should generate the .csv file with the... (14 Replies)
Discussion started by: Kirands
14 Replies
10. Shell Programming and Scripting
Hi All ,
We need one help on the below requirement.We have multiple pipe delimited .txt file(around 100 .txt files) present on one directory.We need the total record count of all the files present in that directory without header.File format as below :
... (8 Replies)
Discussion started by: STCET22
8 Replies
LEARN ABOUT DEBIAN
beagle_beagleimpl
beagle::BeagleImpl(3) HMSBEAGLE beagle::BeagleImpl(3)
NAME
beagle::BeagleImpl -
SYNOPSIS
Inherited by beagle::cpu::BeagleCPUImpl, and beagle::gpu::BeagleGPUImpl.
Public Member Functions
virtual int createInstance (int tipCount, int partialsBufferCount, int compactBufferCount, int stateCount, int patternCount, int
eigenBufferCount, int matrixBufferCount, int categoryCount, int scaleBufferCount, int resourceNumber, long preferenceFlags, long
requirementFlags)=0
virtual int getInstanceDetails (BeagleInstanceDetails *returnInfo)=0
virtual int setTipStates (int tipIndex, const int *inStates)=0
virtual int setTipPartials (int tipIndex, const double *inPartials)=0
virtual int setPartials (int bufferIndex, const double *inPartials)=0
virtual int getPartials (int bufferIndex, int scaleIndex, double *outPartials)=0
virtual int setEigenDecomposition (int eigenIndex, const double *inEigenVectors, const double *inInverseEigenVectors, const double
*inEigenValues)=0
virtual int setStateFrequencies (int stateFrequenciesIndex, const double *inStateFrequencies)=0
virtual int setCategoryWeights (int categoryWeightsIndex, const double *inCategoryWeights)=0
virtual int setPatternWeights (const double *inPatternWeights)=0
virtual int setCategoryRates (const double *inCategoryRates)=0
virtual int setTransitionMatrix (int matrixIndex, const double *inMatrix, double paddedValue)=0
virtual int setTransitionMatrices (const int *matrixIndices, const double *inMatrices, const double *paddedValues, int count)=0
virtual int getTransitionMatrix (int matrixIndex, double *outMatrix)=0
virtual int updateTransitionMatrices (int eigenIndex, const int *probabilityIndices, const int *firstDerivativeIndices, const int
*secondDerivativeIndices, const double *edgeLengths, int count)=0
virtual int updatePartials (const int *operations, int operationCount, int cumulativeScalingIndex)=0
virtual int waitForPartials (const int *destinationPartials, int destinationPartialsCount)=0
virtual int accumulateScaleFactors (const int *scalingIndices, int count, int cumulativeScalingIndex)=0
virtual int removeScaleFactors (const int *scalingIndices, int count, int cumulativeScalingIndex)=0
virtual int resetScaleFactors (int cumulativeScalingIndex)=0
virtual int copyScaleFactors (int destScalingIndex, int srcScalingIndex)=0
virtual int calculateRootLogLikelihoods (const int *bufferIndices, const int *categoryWeightsIndices, const int *stateFrequenciesIndices,
const int *scalingFactorsIndices, int count, double *outSumLogLikelihood)=0
virtual int calculateEdgeLogLikelihoods (const int *parentBufferIndices, const int *childBufferIndices, const int *probabilityIndices,
const int *firstDerivativeIndices, const int *secondDerivativeIndices, const int *categoryWeightsIndices, const int
*stateFrequenciesIndices, const int *scalingFactorsIndices, int count, double *outSumLogLikelihood, double *outSumFirstDerivative,
double *outSumSecondDerivative)=0
virtual int getSiteLogLikelihoods (double *outLogLikelihoods)=0
virtual int getSiteDerivatives (double *outFirstDerivatives, double *outSecondDerivatives)=0
Public Attributes
int resourceNumber
Author
Generated automatically by Doxygen for HMSBEAGLE from the source code.
Version 1.0.0 Fri May 25 2012 beagle::BeagleImpl(3)