09-24-2009
Thanks varontron ended up using the above logic to get the results i wanted though it took a while
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Does anyone know the correct syntax for computing arithmetic expressions inside the echo statement? Let me know, thanks (3 Replies)
Discussion started by: circleW
3 Replies
2. Shell Programming and Scripting
Okay i've got some code which reads a text file and loops through it and there a few if statements inside where one is failing (the one bolded).
Basically the acc column contains a list of three digit access codes, some though have null records (i.e nothing in the field) so what I want to do is... (3 Replies)
Discussion started by: TonyR
3 Replies
3. Shell Programming and Scripting
In my ksh script, if the conditions of a if statement are true, then do nothing; otherwise, execute some commands.
How do I write the "do nothing" statement in the following example?
Example:
if (( "$x"="1" && "$y"="a" && "$z"="happy" ))
then
do nothing
else
command
command
fi... (3 Replies)
Discussion started by: april
3 Replies
4. IP Networking
We have a code to find the DNS entry of a host that has a trailing '-' in its url (format example: mysite-.watch.com):
if(gethostbyname_r(host,host_ent,host_buffer,host_buffer_size,&host_error)==NULL)
{
//failed
}
But when remove the '-' from the host name the code does not return... (12 Replies)
Discussion started by: uunniixx
12 Replies
5. Programming
Hi all,
I am trying to write a program in C which will generate private and public keys using openssl RSA and use these for encryption and decryption. I am able to generate the keys successfully and write these to files. I am able to read the private key successfully. I can encrypt and decrypt... (1 Reply)
Discussion started by: Treasa
1 Replies
6. Shell Programming and Scripting
hi
i try to check if awk returns null
and i dont know how it's works
this is the command
set EndByC = `ls -l $base | awk '/.c$/ {print $9}'`
if ($EndByC=="") then #check if ther is XXX.c directory
echo Sorry ther is no XXX.c folder "in" $base path
echo the XXX.c folder is necessary... (6 Replies)
Discussion started by: frenkelor
6 Replies
7. Shell Programming and Scripting
I have been experiencing this problem intermittantly, I thought the problem was '/bin/sh -> /bin/dash' but I changed that to bash and the problem persists.
I am writing functions to be included in user's '.bash_profile' through source or '.' filename a quick example of the problem is illustrated... (3 Replies)
Discussion started by: bsquared
3 Replies
8. Shell Programming and Scripting
Hi,
I want to be able to check if a variable is not equal to null. I am using KSH, and am getting this error message when i run this script:
: assignment requires lvalue
The line which is causing the problem is as follows:
if (($SFTP_DESTINATION != '' ));then
if ssh... (6 Replies)
Discussion started by: Jack_Maloney
6 Replies
9. HP-UX
Hi there,
I have 2 HP-UX on same subnet and having a problem on one about ping. I'll call them as hp01 hp02.
hp01 can ping hp02 (ping says %100 transmitted)
hp01 can ssh/telnet hp02
hp02 can ssh/telnet hp01
hp02 cannot ping hp02 (ping says %100 packet loss)
There I thought of ndd... (4 Replies)
Discussion started by: royalliege
4 Replies
10. UNIX for Advanced & Expert Users
Why does this not work?
echo 'find / -iname \'*katt*\' -size +500M 2>/dev/null'
How does this work? I have 5 single quotes. I though you needed an even amount of single quotes.
echo 'find / -iname \'*katt*\' -size +500M 2>/dev/null''
What is the trick to make it work with an alias? This... (4 Replies)
Discussion started by: cokedude
4 Replies
LEARN ABOUT DEBIAN
optionfindvalue
optionFindValue(3) Programmer's Manual optionFindValue(3)
NAME
optionFindValue - find a hierarcicaly valued option instance
SYNOPSIS
#include <your-opts.h>
cc [...] -o outfile infile.c -lopts [...]
const tOptionValue* optionFindValue(const tOptDesc* pOptDesc, char const* name, char const* value);
DESCRIPTION
This routine will find an entry in a nested value option or configurable. It will search through the list and return a matching entry.
pOptDesc
an option with a nested arg type
name name of value to find
value the matching value
RETURN VALUE
a compound value structure
ERRORS
The returned result is NULL and errno is set:
EINVAL - the pOptValue does not point to a valid hierarchical option value.
ENOENT - no entry matched the given name. @end itemize
SEE ALSO
The info documentation for the -lopts library.
ao_string_tokenize(3), configFileLoad(3), optionFileLoad(3), optionFindNextValue(3), optionFree(3), optionGetValue(3), optionLoadLine(3),
optionNextValue(3), optionOnlyUsage(3), optionProcess(3), optionRestore(3), optionSaveFile(3), optionSaveState(3), optionUnloadNested(3),
optionVersion(3), pathfind(3), strequate(3), streqvcmp(3), streqvmap(3), strneqvcmp(3), strtransform(3),
2011-07-10 optionFindValue(3)