Change a pattern in all the files in one go!
#!/bin/sh
for file in $(grep -il "devdb" *.sql)
do
sed -e "s/devdb/testdb/g" $file > /tmp/tempfile.tmp
mv /tmp/tempfile.tmp $file
done
Sphoot - A Marathi Word for "IMPROMPTU"
Change a pattern in all the files in one go!
#!/bin/sh
for file in $(grep -il "devdb" *.sql)
do
sed -e "s/devdb/testdb/g" $file > /tmp/tempfile.tmp
mv /tmp/tempfile.tmp $file
done
In Order to change the date format through Personalization, please follow the steps given below:
1. Navigate, Root > People Tools > Personalization > Personalization Options > Search
Here, you will get the option for the different application for which you want to change the Date Format or you can also choose PPTL (People Tools) which change the Date Format in the Tools itself.
Choose, PPTL.
2. Look for a Definition : DFRMT, for the Date Format.
3. On the Format Tab, just click on this Tab.
4. Now, click on the "Set Option Default Value".
5. Change the Option Default Value as per your requirement MMDDYY and click OK.
Ofcourse! Save
PeopleBook Change assistant.
#Project= Used primarily for functions that require a project name; for example, Build Project.
#Directory= Used when you need to run a script that is not located
in the
#Directory=#PT_PSHOMEsrc\cbl\base\
#P1= through #P5= Used to pass parameters to SQR reports, for example,
TEST.sqr. In this case, you would pass the necessary value, such as:
#P1=#OutputDirectory
#PTPS_HOME= Used to specify the
on the Directory tab of the Change Assistant options (Options, Change Assistant, Directories tab).
#OutputDirectory= Used to specify the Output Directory variable that is defined in the Options, Change Assistant, Directories screen.
#NT= Used for DB2
View/Query View
Derived
SubRecord
Stored Procedure
Temporary Table
Dynamic View
#RCID= Enables the user to override the
Setting SSH on a machine using security file for direct ssh
Client:- The system from which the ssh session will be started via the ssh command
Server:- The system that the ssh session connects to
Steps to taken on the client :
On the client run the following commands:
$ cat id_rsa.pub >> $HOME/.ssh/authorized_keys
$ chmod 0600 $HOME/.ssh/authorized_keys
An alternative is to create a link from authorized_keys2 to authorized_keys:
$ cd $HOME/.ssh && ln -s authorized_keys2 authorized_keys
On the client test the results by ssh'ing to the server
$ ssh -i $HOME/.ssh/id_rsa server
(Optional) Add the following $HOME/.ssh/config on the client:
Host server
IdentityFile ~/.ssh/id_rsa
This allows ssh access to the server without having to specify the path to the id_rsa file as an argument to ssh each time.