Is there a way to handle commas inside the data when generating a csv file from shell script?
I am extracting data via sql query and some of the data has commas. Output File must be csv and I cannot update the data in the db (as it is used by other application).
Example
table FavoriteThings
Sample Data
excerpt from code
Output needs to be
currently I get
which when imported into excel shows 4 columns for Kurt
Last edited by vbe; 01-24-2019 at 02:39 PM..
Reason: code tags
Since i'm new to scripting i'm findind it difficult to code a script. The script has to be an executable with 2 paramters passed to it.The Parameters are
1. The Control file name(.ctl file)
2. The Data file name(.csv file)
Does anybody have an idea about it? :confused: (3 Replies)
TEST_HEME,"SubNetwork=ONRM_RootMoR,SubNetwork=ARNC1",CELL
when I split by
FS=","
then
$0=TEST_HEME
$1="SubNetwork=ONRM_RootMoR
$2=SubNetwork=ARNC1"
but I need this will be single value
"SubNetwork=ONRM_RootMoR,SubNetwork=ARNC1" (4 Replies)
Friends...This is the first time i am trying the report generation using shell script... any suggestions are welcome.
Is there a way to set the font size & color when i am exporting the data from unix shell script as a CSV file ?
The following sample data is saved as a .csv file in the... (2 Replies)
I need to read data from a file called "test.csv" through shell script where the file contains values like name,price,descriptor etc. There are rows where descriptor (& in some rows name) are written as string & other characters like "car_+" OR "bike*" etc where it should contains strings like... (3 Replies)
Hi Guys,
I am new to shell script.I need your help to write a shell script.
I need to write a shell script to extract data from a .csv file where columns are ',' separated.
The file has 5 columns having values say column 1,column 2.....column 5 as below along with their valuesm.... (1 Reply)
Hi Guys,
I am new to shell script.I need your help to write a shell script.
I need to write a shell script to extract data from a .csv file where columns are ',' separated.
The file has 7 columns having values say column 1,column 2.....column 7 as below along with their values.
Name, Address,... (7 Replies)
Hi everyone,
I have a csv file which has data with different heading and column names as below.
Static Data Ingested
,,,,,,,,,,,,Known Explained Rejections
Column_1,column_2,Column_3,Column_4,,Column_6,Column_7,,% Column_8,,Column_9 ,Column_10 ,... (14 Replies)
Hi List,
I have a chunk of data like so:
User Account Control:
User Account Control:
User Account Control:
User Account Control:
Disabled
User Account Control:
User Account Control:
User Account Control:
Disabled
User Account Control:
User Account Control:
... (3 Replies)
i have data as below
123,"paul phiri",paul@yahoo.com,"po.box 23, BT","Eco Bank,Blantyre,Malawi"
i need an output to be
123,"paul phiri",paul@yahoo.com,"po.box 23 BT","Eco Bank Blantyre Malawi" (5 Replies)
Discussion started by: mathias23
5 Replies
LEARN ABOUT DEBIAN
gp2c
GP2C(1) PARI GP2C(1)NAME
GP2C - The GP to C compiler
DESCRIPTION
gp2c [-ghfltvydWSTGV] [-i N] [-o <file>] [-p <prefix>] [file.gp]
gp2c is a program that translate GP code to C code that use the libpari library. It tries to generate code looking like the PARI source
code.
user option:
-o <file> : Place output in file <file>.
-g : Generate automatic garbage collection code.
-iN: Set indentation level to N spaces (default 2).
-W : Output information about global variables.
-p <prefix>: Prefix user-defined symbol by <prefix> to avoid conflict.
-s <suffix>: Add suffix <suffix> to GP install names of functions.
-S: Assume strict declarations for functions.
query options:
-h : This help.
-f : Dump information about functions to stderr.
-l : Output the list of functions known to the compiler.
-t : Output the table of types known to the compiler.
-v : Output version information and exit.
debugging options:
-d : Increase debugging level.
-y : Switch parser to debug mode.
-T : Output syntactic tree in treetool format.
-TT : Output syntactic tree in VCG/GRL format.
-G : Generate GP code in place of C code. Don't smile.
-V : Do not clean up variables.
file.gp: file to be processed, default to stdin. The generated C code is output to stdout unless option -o is used.
See the script gp2c-run for an automated compilation process.
COPYING
Copyright 2000-2005 The PARI Group
GP2C is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under
certain conditions. There is absolutely no warranty for GP2C.
AUTHOR
Bill Allombert <Bill.Allombert@math.u-bordeaux.fr>
SEE ALSO gp2c-run(1), gp2c-dbg(1), gp(1), gcc(1)GP to C compiler January 2005 GP2C(1)