how to write scripts to update a table in oracle db based on the result of the number of record counts
for example
i need to execute the following script every hour
here everyhour the filename will be changing...like 200903042106 at 22:05 hrs and 200903042206 at 23:05hrs
(year month day hr min format)
the output will be varying for each execution
for e.g output for 200903042106 will be
and output for 200903042206 will be
I WILL BE HAVING A TABLE WITH ALL POSSIBLE COULMNS (WHICH MAY COME IN THE OUTPUT OF THE SCRIPT LIKE...RTMS)
the think is i should be able to read what is first value (RTMS or BSNLSERVICE1 or CAE...etc) and then insert in to the db, the count corresponding to that column leaving other columns with null values or blank...along with the timestamp in timestamp column of the time table which i can make use for querying purpose...like between dates or interval...etc
DB should reflect like the following:
how it can be achieved?
then 2nd question
about creating the cronjob dynamically with varing file names as told already
with thanks
Aemunathan
Last edited by aemunathan; 03-04-2009 at 10:16 PM..
I have created a cronjob that successfully executes and among other thing runs aria2c to download several files and save them to a folder. However, since it executes as sudo, the downloaded folder is saved with those permissions.
Is there a way to execute the cronjob so that the downloaded folder... (4 Replies)
Hi,
I am really sorry for this question but still i am confused.
I have shell script called sample.sh
I can execute only with the combination of ./sample.sh
Is ./ really necessary ? Is it something related with $HOME or $PATH variable.
Why and How can i resolve this case ?
... (2 Replies)
Hi
I am writing a script to get the CPU and memory utilization periodically from glance command.
Wrote a script which consists of below two lines
Script name : Utilization.sh
#!/bin/sh
glance -iterations 1 | sed -n '/Util/p/'| awk '!/Disk/'| awk '!/Swap/' >> file.txt
I am able to run the... (5 Replies)
HI Folks,
Sorry for this basic confusion but please help me.
i want to execute one script at 9pm today. i want make this as schedule so it can execute automatically.
So am doing like this.
21 10 24 4 <here what can i keep) /tmp/stemp/testcron.ksh
Can you please help on this?
... (6 Replies)
hi, please help, keep getting this bolded error and look it up and people say
its your environment variable though i tried to set it manually in expect..it run fine if i run it manually but once i run it by cronjob it error below..i tried to comment out ip/login info with *..
logfile::
START... (0 Replies)
Hi Users,
I am Newbie to linux and cron. I have a requirement to run a job at 8 AM every Sunday.
I am using RHEL 5. Based on the hints through google search I created
crontab and added entry to call the shell script which will in turn login to Oracle user and execute a pl/sql block.
... (1 Reply)
Hi,
I am developing 1 script in which I need to execute one cron job running in different server and my script is in different server.
so can any one help me to execute the cronjob set in different server.
Thanks in advance. (1 Reply)
Hi,
I need to execute a crontab based on a condition where one SH file should be executed only based on the output of a file in a folder.
I have written the following cron job which is not working.
00 01 * * * read a < /px/batch/reslut.txt && && sh /px/batch/check.sh
where my... (2 Replies)
Hello everybody,
I'm trying to run a shell script in crontab file. But anyhow it's not getting executed. Following is the command that I've used in crontab.
30 07 * * * . ./.cronprofile;/om/reports/reportscripts/jitu/prod/prd_pre_to_post.sh
35 11 * * * .... (3 Replies)
:cool:
I need to execute a shell script to do the following:
cat a file
run two back ground processes using the first two values from the file
wait till those background processes finish
run two more background processes using the next two values from the file
wait till those background... (1 Reply)