Search Results

Search: Posts Made By: donadarsh
Forum: Red Hat 07-11-2013
6,761
Posted By donadarsh
@Vidya I did try sed but got error every...
@Vidya

I did try sed but got error every time. Your solution might help...

Thanks...
Forum: Red Hat 07-11-2013
6,761
Posted By donadarsh
Special character ^@ in CSV file
All,

I am having a tough time with Linux and CSV file. My CSV file gets generated from Cognos on Linux machine that contains special characters. At first instance when I do vi <filename> to that...
2,635
Posted By donadarsh
#!/bin/bash limite=3 a=0 while [ "$a"...
#!/bin/bash

limite=3
a=0

while [ "$a" -le 3 ]; do

if [ "$a" -eq 1 ]; then
pru=/usr/bin/mei.txt
cat $pru | mail -s "IMEIS" mathias@wirtel.com.ar
fi

if [...
2,635
Posted By donadarsh
my mistake - '$a' shouldn't be in single quote....
my mistake - '$a' shouldn't be in single quote. It will read it as one string. better use "$a".
2,635
Posted By donadarsh
Just check if you can initialize 'a' before while...
Just check if you can initialize 'a' before while loop and instead of '$a=1' just use '$a'. Hope it solves your problem.
8,249
Posted By donadarsh
If i remember I faced it sometimes back. Not sure...
If i remember I faced it sometimes back. Not sure if it was exact same but related to it.
2,635
Posted By donadarsh
where you are initializing the variable 'a'? if...
where you are initializing the variable 'a'? if it has no value assigned to it, how can you put expression over it?
8,249
Posted By donadarsh
there can be many scenarios where something is...
there can be many scenarios where something is going wrong

export the DESTN_PATH variable. (it shouldn't contain / at last of the path, otherwise you will two // in your output expression)
...
2,635
Posted By donadarsh
I don't know if I am correct, try this - ...
I don't know if I am correct, try this -

a=$a+1

should be

a=`expr $a + 1`
5,107
Posted By donadarsh
How did you do that? can you paste that entire...
How did you do that? can you paste that entire mailx command? -c option should work. May be its lacking the exact substitution.
17,681
Posted By donadarsh
If you want to kill the current script after 10...
If you want to kill the current script after 10 minutes just run another script in background with nohup. pass the parent process id(current script id) and in that script just wait for 10 mins

...
1,888
Posted By donadarsh
-f option is for checking file, whether its...
-f option is for checking file, whether its ordinary or not.
What exactly you want to check? only the existence, then try -r option, you can copy that.

echo "`date '+%Y%m%d_%H%M%S'` Getting...
6,849
Posted By donadarsh
FILE_NAME is the data file which will have...
FILE_NAME is the data file which will have records and will be loaded to database by using sql loader.

If you are not executing the config file then what is the use of config file? Before you...
1,457
Posted By donadarsh
./script.sh param1 param2 param3 .... paramN in...
./script.sh param1 param2 param3 .... paramN
in script.sh

parameters=$*

for param in $parameters
do
echo $param
done
6,849
Posted By donadarsh
if you put those details in environment variable...
if you put those details in environment variable then -


#count the total records from file includes header and footer also
TOTAL_COUNT=`wc -l $FILE_NAME`

#Now subtract the count of footer...
6,849
Posted By donadarsh
there are two ways to do it. 1. Pass the...
there are two ways to do it.

1. Pass the total no of loads while invoking SQL Loader. (Count the actual no of records from input file and pass it)

TOTAL_COUNT=`wc -l $FILE_NAME...
1,816
Posted By donadarsh
You have different set of similar rows. You want...
You have different set of similar rows. You want to put them all in separate-separate files based on time stamp or only the first set of rows in another file?
5,232
Posted By donadarsh
find /devctr/srcfiles/* -type f -mtime +1 2>...
find /devctr/srcfiles/* -type f -mtime +1 2> error.log |xargs -I FLNAME echo FLNAME
5,232
Posted By donadarsh
use this find <file_pattern> -type f -mtime...
use this

find <file_pattern> -type f -mtime +1 2> <error_log> |xargs -I FLNAME echo FLNAME
1,328
Posted By donadarsh
PASS=Figomom#0;export PASS is password that is...
PASS=Figomom#0;export PASS is password that is getting used to connect to database. Once you set the password you need to export it as environment variable. So whenever you need you can use it.

if...
5,425
Posted By donadarsh
some time back i had the similar issue. my csv...
some time back i had the similar issue. my csv file was generated from cognos on unix box but it was having some special characters. I just did find and replace from ksh script before processing it.
1,384
Posted By donadarsh
try this one, hope it works for you diff...
try this one, hope it works for you


diff <dir1> <dir2>| xargs -I FNAME echo FNAME>> tmp_file

for filepath in `cat tmp_file`
do
dir_name=`echo $filepath|cut -d" " -f3|cut -d":" -f1`
...
1,454
Posted By donadarsh
I didn't understand fully your question but just...
I didn't understand fully your question but just try this, hope you want same.

TODAY=`date '+%d%m%Y'`
expdp system/test@Database dumpfile='expdp_database_'$TODAY'.dmp' directory=datapump_database...
1,911
Posted By donadarsh
you have put a question or assignment here? ...
you have put a question or assignment here?

for file searching older than 5 days
find dir_name/file_pattern -type f -mtime +5

use a temp file to list your desired files and use it where...
2,215
Posted By donadarsh
have you added the first line to tell which shell...
have you added the first line to tell which shell you are running? like
#!/bin/sh
Showing results 1 to 25 of 73

 
All times are GMT -4. The time now is 09:14 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy