Sponsored Content
Full Discussion: Insert Header Name
Top Forums Shell Programming and Scripting Insert Header Name Post 302325035 by s1a2m3 on Friday 12th of June 2009 01:34:08 PM
Old 06-12-2009
full sql statement

@@\.login_JDEDB.sql
set echo off
set verify off
set feed off term off
prompt ********************************************************
prompt Todays Date
prompt ********************************************************
prompt This SQL runs every Monday prompt ********************************************************
set feedback on
set echo off head off feed off veri off trimspool on
spool /home/oracle/log/Weekly_BlueGrassCrdHld.csv
set heading on;
set linesize 200;
SELECT AIAN8 || ',' || F0101.ABALPH || ',' || AICO || ',' || AIHOLD || ',' || AIARC || ',' || AIACL || ',' || AITRAR || ',' || F0014.PNPTD || ',' || AIBADT || ',' || F0101.ABAN81
FROM PRODDTA.F0014, PRODDTA.F0101, PRODDTA.F03012
WHERE F0101.ABAN8 = AIAN8 AND F0014.PNPTC = AITRAR AND ((AICO='00271') AND (AIHOLD>'1'));
spool off
exit

What I am getting with above sql is CSV file with Header as shown within pipes || ||. I need to chage those to user friendly names like Adress Book etc.

Thanks for you help.

Akbar
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

insert header row into .xls

Hello, I am building an .xls file extracting info from a DB to be eventually emailed. All is good except how do I put in a header row.. like date, name of report etc. before the columns with the actual column name and data? Thanks for any assistance.. the below is after I have signed into... (11 Replies)
Discussion started by: Tish
11 Replies

2. Linux

Reading the header of a tar file(posix header)

say i have these many file in a directory named exam. 1)/exam/newfolder/link.txt. 2)/exam/newfolder1/ and i create a tar say exam.tar well the problem is, when i read the tar file i dont find any metadata about the directories,as you cannot create a tar containig empty directories. on the... (2 Replies)
Discussion started by: Tanvirk
2 Replies

3. Shell Programming and Scripting

insert a header in a huge data file without using an intermediate file

I have a file with data extracted, and need to insert a header with a constant string, say: H|PayerDataExtract if i use sed, i have to redirect the output to a seperate file like sed ' sed commands' ExtractDataFile.dat > ExtractDataFileWithHeader.dat the same is true for awk and... (10 Replies)
Discussion started by: deepaktanna
10 Replies

4. Shell Programming and Scripting

Renaming all header to specific header pattern

Input #HAC0253 EFVHIJHIJEFVTHIJOPKOPKTEFVEFVEFVOPKHIJOPKOPKHIJTTEFVEFVTEFV #BASFS12 EFVEFVHIJEFVEFVTOPKEFVOPKTHIJTTHIJOPK #ACG5115 TEFVEFVOIJEFVHIJHIJOPKOPKHIJHIJTTEFVEFVOPKTTEFVEFVOPKHIJOPKOPKOPK #ECG5114 IJTOPKHIJEFVOEFVEFVOPKTTEFVEFVOPKHIJOPKOPKOPK . . Output (5 Replies)
Discussion started by: patrick87
5 Replies

5. UNIX for Dummies Questions & Answers

Merge all csv files in one folder considering only 1 header row and ignoring header of all others

Friends, I need help with the following in UNIX. Merge all csv files in one folder considering only 1 header row and ignoring header of all other files. FYI - All files are in same format and contains same headers. Thank you (4 Replies)
Discussion started by: Shiny_Roy
4 Replies

6. Shell Programming and Scripting

Insert a header record (tab delimited) in multiple files

Hi Forum. I'm struggling to find a solution for the following issue. I have multiple files a1.txt, a2.txt, a3.txt, etc. and I would like to insert a tab-delimited header record at the beginning of each of the files. This is my code so far but it's not working as expected. for i in... (2 Replies)
Discussion started by: pchang
2 Replies

7. Shell Programming and Scripting

Insert date/time header at top of file

I'm trying to take mrt output and put it at the top of a file along with the date and time. I was able to do it at the bottom of the file with the following printf "********** $(date) **********\n\n" >> $OUTPUT_PATH/$HOSTNAME mtr -r -w -c 10 $HOSTADDRESS >> $OUTPUT_PATH/$HOSTNAME printf... (2 Replies)
Discussion started by: kramer65
2 Replies

8. Shell Programming and Scripting

How to insert header with underline?

How to insert header with underline AM able to insert only header not underline sed '1i NAME COUNTRY' test.txt input file UK 1234 USA 2354 AUS 2253 IND 4256 Output file NAME COUNTRY_CODE ---- ------------ UK 1234 USA 2354 AUS 2253 IND 4256 (5 Replies)
Discussion started by: Kalia
5 Replies

9. Shell Programming and Scripting

Find header in a text file and prepend it to all lines until another header is found

I've been struggling with this one for quite a while and cannot seem to find a solution for this find/replace scenario. Perhaps I'm getting rusty. I have a file that contains a number of metrics (exactly 3 fields per line) from a few appliances that are collected in parallel. To identify the... (3 Replies)
Discussion started by: verdepollo
3 Replies
ui_compat(3)							      OpenSSL							      ui_compat(3)

NAME
des_read_password, des_read_2passwords, des_read_pw_string, des_read_pw - Compatibility user interface functions SYNOPSIS
int des_read_password(DES_cblock *key,const char *prompt,int verify); int des_read_2passwords(DES_cblock *key1,DES_cblock *key2, const char *prompt,int verify); int des_read_pw_string(char *buf,int length,const char *prompt,int verify); int des_read_pw(char *buf,char *buff,int size,const char *prompt,int verify); DESCRIPTION
The DES library contained a few routines to prompt for passwords. These aren't necessarely dependent on DES, and have therefore become part of the UI compatibility library. des_read_pw() writes the string specified by prompt to standard output turns echo off and reads an input string from the terminal. The string is returned in buf, which must have spac for at least size bytes. If verify is set, the user is asked for the password twice and unless the two copies match, an error is returned. The second password is stored in buff, which must therefore also be at least size bytes. A return code of -1 indicates a system error, 1 failure due to use interaction, and 0 is success. All other functions described here use des_read_pw() to do the work. des_read_pw_string() is a variant of des_read_pw() that provides a buffer for you if verify is set. des_read_password() calls des_read_pw() and converts the password to a DES key by calling DES_string_to_key(); des_read_2password() oper- ates in the same way as des_read_password() except that it generates two keys by using the DES_string_to_2key() function. NOTES
des_read_pw_string() is available in the MIT Kerberos library as well, and is also available under the name EVP_read_pw_string(). SEE ALSO
ui(3), ui_create(3) AUTHOR
Richard Levitte (richard@levitte.org) for the OpenSSL project (http://www.openssl.org). 0.9.7a 2001-10-25 ui_compat(3)
All times are GMT -4. The time now is 12:19 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy