10 More Discussions You Might Find Interesting
1. Programming
Le sigh... Hopefully this will be the last time I have to ask for help on this topic. For a while now I've been working with a 1d array that holds 2d arrays. For reference you can view here. Now I'm just trying to loop through the elements with the following:
#include <stdio.h>
void... (3 Replies)
Discussion started by: Azrael
3 Replies
2. UNIX for Dummies Questions & Answers
Hi all,
I am trying to loop through the string contents of an array, to add it during the saving of the output files. I am trying this code to print each column and save it to unique file name, but it doesn't work. Thanks for any help.
fnam=(japan usa uk)
alldata.dat contained sample data... (1 Reply)
Discussion started by: ida1215
1 Replies
3. Shell Programming and Scripting
Hi All,
Can someone tell me how can we create same xml tag lines based on the number of lines present in other file and replace the Name variable vaule present in other file.
basically I have this xml line
<typ:RequestKey NameType="RIC" Name="A1" Service="DDA"/>
and say I... (4 Replies)
Discussion started by: Optimus81
4 Replies
4. Shell Programming and Scripting
So my script is supposed to repeat for every server in my file, but as of now it is getting stuck on my awk commands
# Read file cred.txt (with one IP per line), connect to servers (one at a time), and download directory listing
i=1
param=$(sed -n "{$1}p" $parm_dir/cdm_param.txt) #Get the last... (6 Replies)
Discussion started by: MJCreations
6 Replies
5. UNIX for Dummies Questions & Answers
Hi,
My first post!!
I have a files with header, something like this
Header_Row
AMC|D1|D2|D2
AAO|D3|D4|D5
AMC|D6|D7|D8
AAO|D9|D10|D11
.
.
.
.
.
and millions fo records thereafter like this.
I want to read the above file in a loop and write the lines having AMC into another... (1 Reply)
Discussion started by: amitbakre
1 Replies
6. Shell Programming and Scripting
Good Morning/Afternoon All,
I am having some trouble creating a variable called "total" to display the sum of the values in a specific field, $6 for example.
The data I am working on is in the following form:
John Doe:(555) 555-5555:1:2:3
Jane Doe:(544) 444-5556:4:5:6
Moe Doe:(654)... (2 Replies)
Discussion started by: SEinT
2 Replies
7. Shell Programming and Scripting
Hi All,
Does anyone know how to read multiple lines from standard input into an array and then iterate a loop for all the lines read. Below is an example pseudocode:
I need the below filenames to be read by the script into an array or something similar:
And then in the script, I... (9 Replies)
Discussion started by: bharath.gct
9 Replies
8. Programming
I am facing a strange error while creating posix threads:
Given below are two snippets of code, the first one works whereas the second one gives a garbage value in the output.
Snippet 1
This works:
--------------
int *threadids;
threadids = (int *) malloc (num_threads * sizeof(int));
... (4 Replies)
Discussion started by: kmehta
4 Replies
9. Shell Programming and Scripting
Hi All,
I'm trying to get a script to loop through an array. The array is basically a list of .zip files. I'd like the script to loop through and unzip the zip files contained in the zip file list. When I run the script, it unzip the first zip file correctly, and then stops Any thoughts? Here's... (2 Replies)
Discussion started by: kelldan
2 Replies
10. Shell Programming and Scripting
I have an array of hashrefs that look like the following:
my @LAYOUT = (
{SQL_1 => "select count (*) FROM prospect
WHERE PROCESS_DATE = To_date('INSERT_DATE_HERE', 'mm/dd/yyyy')
and tiff_filename is not null
... (2 Replies)
Discussion started by: kregh99
2 Replies