Hello,
We currently have a BASH script that runs and moves image files from a remote server to the local db server. A snippet of the code shows that we are picking up all Images that are 'mtime -1'
It's simple and it works.
Now, due to development requirements we need a way of picking up those images from different directories within the base directory of /u01/bea/madeup/Images. The plan is to have an 'index' table that will hold the location (path and filename) of the image file and it is this that I would like to read from the table and somehow use in place of the hard coded file path above.
Can I Just do something like this example: (This may work with some tweaking, but it gives you an idea of what i am trying to achieve).
Dear Friends,
Please help me to achieve the following:
I want to pass one parameter from Shell-script to Sql-script.
Example:
My ShellScript.sh is calling report.sql like this:
/bin/sqlplus /reports.sql
And
My report.sql is calling many Stored-Procedures like this:
exec... (0 Replies)
hi I all ,
I have sql statment in my shell script , I pass two argument to the script I need to pass the this two arguments to the sql statment
example :
runsql.sh "1" "2"
sql :
updat tables_x set y=0
where
A=:x should subsituted by "1"
and
B=:y shuold subsituted bt "2"... (1 Reply)
Hi guyz,
Posting a thread after a long time.
I want to pass two variables to unix shell script from sql script.
Note: I am calling sql script from unix script. sql script has 2 variables one is the return code for status of program run and second one email flag. I don't know how to capture... (3 Replies)
Hi All,
I need to pass a variable to perl script from bash script, where in perl i am using if condition. Here is the cmd what i am using in perl
FROM_DATE="06/05/2008"
TO_DATE="07/05/2008"
"perl -ne ' print if ( $_ >="$FROM_DATE" && $_ <= "$TO_DATE" ) ' filename"
filename has... (10 Replies)
Unix prompt
=========
echo "Enter the query"
read q
==========
User has entered :
SELECT * FROM employee
=====================
Now the problem starts..
echo $q
Output: SELECT "all files names in the PWD" FROM employee
================================================
... (5 Replies)
Hi Gurus,
i have one requirement in unix script, i have a file called abc.txt in that few lines are there with the empid, i need to read each line and pass to .sql script.
ex:
abc.txt
2345
2346
1243
1234
i need to pass these arguments to .sql script rom unix
ex:
select * from... (1 Reply)
Hi Guys,
I am trying to pass a string variable from Unix shell script to sqlplus as a parameter.
I have tried using single quotes with the variable name but it does not work. Please help me with it.
I am using BASH.
My code:
Your help is much appreciated.
Thanks,
shil (2 Replies)
I'm trying to write a basic bash script that takes input you give (what directory, if any, what name, if any ....) and passes the information to find.
I'm trying to just create a string with all variables and then pass it to find. So far I have this extremely simple:
#!/bin/bash -f
... (2 Replies)
Hi Friend,
I have one file in which some number are mentioned and number of lines are vary every time
And i need to pass that number to my sql command from script.
Suppose i have file acc.txt
45456546456
45464564565
67854353454
67657612132
Number of records are vary every time.... (20 Replies)
Hello,
I have file (PARFILE) with string on first line:
INCLUDE=SCHEMA:"IN\( 'SCHEMA1','SCHEMA2','SCHEMA3' \)"In .sh script I use:
....
IMPORT_SCHEMA=`awk 'NR==1{print $2}' ${PARFILE}`
...print $2 is because 'SCHEMA1','SCHEMA2','SCHEMA3' is 2nd column in file
echo "$IMPORT_SCHEMA"... (5 Replies)
Discussion started by: DjukaZg
5 Replies
LEARN ABOUT DEBIAN
makecpt
MAKECPT(l) MAKECPT(l)
NAME
makecpt - Make GMT color palette tables
SYNOPSIS
makecpt [ -Ctable ] [ -I ] [ -Tz0/z1/dz | -Tztable] [ -V ] [ -Z ]
DESCRIPTION
makecpt is a utility that will help you make color palette tables (cpt files). You define an equidistant set of contour intervals or pass
your own z-table, and create a new cpt file based on an existing master cpt file. The resulting cpt file can be reversed relative to the
master cpt, and can be made continuous or discrete.
OPTIONS -C Selects the master color table table to use in the interpolation. Choose among the built-in tables (type makecpt to see the list)
or give the name of an existing cptfile [Default gives a rainbow cpt file].
-I Reverses the sense of color progression in the master cptfile.
-T Defines the range of the new cptfile by giving the lowest and highest z-value and the interval. Alternatively, give the name of a
ASCII file that has one z-value per record. If not given, the existing range in the master cptfile will be used intact.
-V Selects verbose mode, which will send progress reports to stderr [Default runs "silently"].
-Z Creates a continuous cpt file [Default is discontinuous, i.e. constant colors for each interval].
EXAMPLES
To make a cpt file with z-values from -200 to 200, with discrete color changes every 25, and using a polar blue-white-red colortable, try
makecpt -Cpolar -T-200/200/25 > colors.cpt
To make an equidistant cpt file from z = -2 to 6, in steps of 1, using continuous default rainbow colors, try
makecpt -T-2/6/1 -Z > rainbow.cpt
To make a GEBCO look-alike cpt file for bathymetry, try
makecpt -Cgebco > my_gebco.cpt
BUGS
Since makecpt will also interpolate from any existing .cpt file you may have in your directory, you cannot use one of the listed cpt names
as an output filename; hence the my_gebco.cpt in the example.
SEE ALSO gmt(1gmt), grd2cpt(1gmt)
1 Jan 2004 MAKECPT(l)