10 More Discussions You Might Find Interesting
1. Programming
Hi again and thanks to R.Singh.
One more question here.
The code works in awk. (or GAWK)
awk 'BEGIN{print "Enter your Name: ";getline name < "-";print RS "Input entered by user is: "name}'
How to display the variable name again ?
The awk script is running automaticly to the... (3 Replies)
Discussion started by: Zabo
3 Replies
2. Shell Programming and Scripting
Hi All,
I need to pass a variable from bash script to perl script and in the perl script i am using those variables in the sql query but its giving
error :
Use of uninitialized value $ENV{"COUNTRYCD"} in concatenation (.) or string at /GIS_ROOT/custom/tables/DBread_vendor.pl line 50.
Can ... (6 Replies)
Discussion started by: NileshJ
6 Replies
3. Shell Programming and Scripting
Hi guys, I'm having issues getting the following snippet of my script to work and was hoping for some suggestions.
I'm trying to pass a variable in perl system with wget.
This is what I need help with:
#!/usr/bin/perl
use strict;
use warnings;
use POSIX qw(strftime) ;
my... (3 Replies)
Discussion started by: timj123
3 Replies
4. Shell Programming and Scripting
Hi All,
I am new to AWK programming. I have the following for loop in my awk program.
cat printhtml.awk:
BEGIN
-------- <some code here>
END{
----------<some code here>
for(N=0; N<H; N++)
{
for(M=5; M<D; M++) print "\t" D "";
}
-----
}
... (2 Replies)
Discussion started by: ctrld
2 Replies
5. Shell Programming and Scripting
consider the script below
sh /opt/hqe/hqapi1-client-5.0.0/bin/hqapi.sh alert list --host=localhost --port=7443 --user=hqadmin --password=hqadmin --secure=true >/tmp/alerts.xml
awk -F'' '{for(i=1;i<=NF;i++){
if($i=="Alert id") {
if(id!="")
if(dt!=""){
cmd="sh someScript.sh... (2 Replies)
Discussion started by: vivek d r
2 Replies
6. Shell Programming and Scripting
Can we pass perl variable to shell commands. If yes, please give some example. (2 Replies)
Discussion started by: Anjan1
2 Replies
7. Shell Programming and Scripting
Hi Friends,
I'm calling 'sed' command inside one perl script, which is to list directory names which are having some date value as their names (in the form YYYYMMDD) with in the range (start and end date).
#!/usr/bin/perl -w
use strict;
use warnings;
my $DATA = "/export/home/ganapa";
my... (5 Replies)
Discussion started by: ganapati
5 Replies
8. UNIX for Advanced & Expert Users
Hi Everyone,
Can anyone help me how do i call hash variable in to sql query in perl. Please see the script below
i have defined two Hash %lc and %tab as below
$lc{'REFF'}='V_RES_CLASS';
$lc{'CALE'}='V_CAP_CLASS';
$lc{'XRPD'}='V_XFMR_CLASS';
$tab{'V_RES_CLASS'}='V_MFR_SERS';... (6 Replies)
Discussion started by: jam_prasanna
6 Replies
9. Shell Programming and Scripting
So, I have this script. It reads a CSV file that has a mixture of object names with IP addresses (parsing out that part I have working), and object names which have a DNS name. I want to be able to run a "dig +short" based off of the name given to me in the line of the awk script, and then deal... (6 Replies)
Discussion started by: mikesimone
6 Replies
10. Shell Programming and Scripting
I need a non-perl (bash) way to strip the path from a list of "find" results. Below is the perl version which I could use, if I could figure out how to call the script with a variable (like in sh, $1 is the variable passed in ./script variable)
$file = "/path/to/file.txt";
# How do I... (2 Replies)
Discussion started by: TheCrunge
2 Replies