Hi Rangarasan, thanks for your reply. However it is not working for me. I'm new to Unix programming so maybe it is something simple I have not spotted. I ran the following code:
I get the following output
The file test1.txt is definitely in the current directory
Hi,
I have a parameter file and it contains following items
$ cat TransactionParams
From_Date_Parm=2005-02-25
To_Date_Parm=2005-05-25
Extract_Root_Parm=/detld1/etl/ascential/Ascential/DataStage/Projects/CTI_London/IAM
Extract_Type_Parm=Transaction
EDW_Database_Parm=hdw_erks... (1 Reply)
Hi All,
If I want to ftp files from machine to local pc. But the ip must change everytime :( (due to VPN), can I write a script to easiler (no need to update ip in script)?
user_name=aaa
password=bbb
cat ip.txt
#
# FTP the files
#
ftp -d -in 199.200.204.109 <<EOF
user $user_name... (2 Replies)
Hi,
IŽd like to know how to program a shell script for know when a file changes and based on that make another tasks all this in real time.. Thanks (2 Replies)
Hi,
Requirement:-
Need to change pfile,so while executing script,it has to go to pfile location(ORACLE_HOME/dbs) and open init<SID>.ora file and change value db_name=<>.
If db_name=abcd,script will change the db_name=1234 likr that..
Please help to code this (1 Reply)
Hi to all,
Maybe someone could help me. I want to transform the structure of a xml file.
I have this input.xml:
<?xml version="1.0" encoding="utf-8"?>
<votings>
<file name="Reference 19762">
<case id="No. 3 Div. 870">
<j v="1">Peter</j>
<j v="1">Ely</j>
<j... (10 Replies)
hi,
I have a local.conf file which has the first line
TOPDIR = "/home/mvdev/workspace/boxer". I want to replace the value to
"/home/common/workspace/mirror". I tried the following perl command that is
perl -p -i -e 's/Path/path1/g' myfile.txt then
sed... (7 Replies)
Hello all,
I have a line of code in a file that I need to change in the /etc/sysconfig/kdump file
presently the line reads:
KDUMP_COMMANDLINE_APPEND="irqpoll nr_cpus=1 reset_devices cgroup_disable=memory mce=off"
what I need to do is put a comment out the 1st line and repeat it, and... (5 Replies)
I have a file that contains todays date(for ex- test_08/30/2013)
Now I want a script which will run and change the name of the file and put yesterday's date
(for ex- test_08/29/2013)
Please help.
---------- Post updated at 04:40 AM ---------- Previous update was at 04:31 AM ----------
I... (2 Replies)
I have a landing directory on my unix (solaris) server, that receives the following files:
MLH4301I AAOT-hhslog.610.20150805.txt
MLH4301I AAOT-hhslog.611.20150805.txt
MLH4301I AAOT-hhslog.612.20150805.txt
MLH4301I AAOT-hhslog.613.20150805.txt
and I need to add to this files the number 10000... (6 Replies)
Discussion started by: fretagi
6 Replies
LEARN ABOUT SUSE
base
base(3pm) Perl Programmers Reference Guide base(3pm)NAME
base - Establish an ISA relationship with base classes at compile time
SYNOPSIS
package Baz;
use base qw(Foo Bar);
DESCRIPTION
Unless you are using the "fields" pragma, consider this module discouraged in favor of the lighter-weight "parent".
Allows you to both load one or more modules, while setting up inheritance from those modules at the same time. Roughly similar in effect
to
package Baz;
BEGIN {
require Foo;
require Bar;
push @ISA, qw(Foo Bar);
}
"base" employs some heuristics to determine if a module has already been loaded, if it has it doesn't try again. If "base" tries to
"require" the module it will not die if it cannot find the module's file, but will die on any other error. After all this, should your base
class be empty, containing no symbols, it will die. This is useful for inheriting from classes in the same file as yourself, like so:
package Foo;
sub exclaim { "I can have such a thing?!" }
package Bar;
use base "Foo";
If $VERSION is not detected even after loading it, <base> will define $VERSION in the base package, setting it to the string "-1, set by
base.pm".
"base" will also initialize the fields if one of the base classes has it. Multiple inheritance of fields is NOT supported, if two or more
base classes each have inheritable fields the 'base' pragma will croak. See fields, public and protected for a description of this feature.
The base class' "import" method is not called.
DIAGNOSTICS
Base class package "%s" is empty.
base.pm was unable to require the base package, because it was not found in your path.
Class 'Foo' tried to inherit from itself
Attempting to inherit from yourself generates a warning.
use Foo;
use base 'Foo';
HISTORY
This module was introduced with Perl 5.004_04.
CAVEATS
Due to the limitations of the implementation, you must use base before you declare any of your own fields.
SEE ALSO
fields
perl v5.12.1 2010-04-26 base(3pm)