Search Results

Search: Posts Made By: venkat_reddy
4,211
Posted By venkat_reddy
@Don Cragun: The header should have 7...
@Don Cragun:

The header should have 7 Columns. Forgot to remove EMPID in the Column 5. Header should be as below:

EmpID,EmpName,DeptID,EmpSal,EmpDOB,EmpHireDate,Active

Sincere apologies for...
4,211
Posted By venkat_reddy
@Don Cragun: Sorry for changing the...
@Don Cragun:

Sorry for changing the requirement from the initial one. Actually the key values can be duplicate only in file 1 but not file 2. Also the key value in file 1 and file 2 would be...
4,211
Posted By venkat_reddy
Thanks for the response File1 will have more...
Thanks for the response

File1 will have more columns than File2 .Both have various columns with different formats i.e CHAR,DATE,TIMESTAMP etc. Both have "," as delimitiers.

I tried the code...
4,211
Posted By venkat_reddy
Hi Ravinder, That works with whatever sample...
Hi Ravinder,

That works with whatever sample files provided earlier.However when I tried the code with my actual files, it does not work though. I do see some Weird output .

File 1

...
4,211
Posted By venkat_reddy
Hi Ravinder, I have two files i.e. File1 and...
Hi Ravinder,

I have two files i.e. File1 and File2 with "," as delimiter. They have one column in common(First column) .

File 1


1,AAA
2,BBB
3,CCC
4,DDD


File 2


1,IND,SL,BAN...
4,211
Posted By venkat_reddy
Hi rdrtx1/Ravinder, Do you mind suggesting...
Hi rdrtx1/Ravinder,

Do you mind suggesting the same code for the files with delimiter ",". I tried using the below ,but didn't work


awk 'BEGIN { FS = ","} NR==FNR{l=$1; $1="";...
4,211
Posted By venkat_reddy
Below is the output -sh-4.1$ awk...
Below is the output


-sh-4.1$ awk 'FNR==NR{A[$1]=$2;next} ($1 in A){print $0 OFS A[$1];next} !($1 in A){print $0 OFS "missing"}' b a
1 AA IND
2 BB AUS
3 CC missing
4 DD missing


...
4,211
Posted By venkat_reddy
@rdrtx1: Code suggested by you worked....
@rdrtx1:

Code suggested by you worked. Thanks a lot

@Ravinder:

I did try out the code suggested by you but its giving me same output which I was getting earlier. I need all the columns from...
1,296
Posted By venkat_reddy
Thanks for the inputs
Thanks for the inputs
4,211
Posted By venkat_reddy
Joining files using awk not extracting all columns from File 2
Hello All

I'm joining two files using Awk by Left outer join on the file 1

File 1


1 AA
2 BB
3 CC
4 DD


File 2


1 IND 100 200 300
2 AUS 400 500 600
5 USA 700 800 900
1,296
Posted By venkat_reddy
UNIX Join not working as expected
Hello All,

I'm working on a Shell script to join data from two files using Join command but not able to get the desired output as its throwing me an error:
I have sorted the two files on the...
2,236
Posted By venkat_reddy
Thank you cjcox & Scrutinizer for the response ....
Thank you cjcox & Scrutinizer for the response . The solution suggested by you works but I would need it inside the while loop.

@RudiC:
This is is what I was looking for. Now I have got the logic...
2,236
Posted By venkat_reddy
Unable to compare to a previous value of a variable in a while loop for a file
Hello All,

I'm working on a script that will actually read a file consisting of data like the below:(ReportID,Sub_reportID,Sub_reportName)

1,1,ABC
1,2,DEF
1,3,GHI
2,1,JKL
2,2,MNO
3,1,PQR
...
3,418
Posted By venkat_reddy
UNIX shell script error: not found
Hello All,

I'm working on one Unix shell sript that will actually extract a column data from Oracle table using sqlplus and writes onto a file. I'm getting this error when executing the shell...
1,585
Posted By venkat_reddy
Thank you so much
Thank you so much
Forum: UNIX and Linux Applications 11-02-2015
6,247
Posted By venkat_reddy
Issue resolved
Hello All,

Thanks very much for the responses.

Issue is resolved now.

Thank you
Venkat
Forum: UNIX and Linux Applications 10-29-2015
6,247
Posted By venkat_reddy
UNIX spool command not extracting complete record from the Oracle table
Hello All,

I'm trying to spool an oracle table data into a csv file on unix server but the complete record is not being extracted. The record is almost 1000 characters but only 100 characters are...
1,585
Posted By venkat_reddy
Help Needed: UNIX shell variables to store Oracle table records
Hello Folks,

I'm working on a requirement to automate the process of generating report(csv file) using metadata info stored in an Oracle table and E-mail it to respective people.

Meta data...
Showing results 1 to 18 of 18

 
All times are GMT -4. The time now is 05:06 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy