11-05-2003
Oracle stored procedure.
I am using sqlplus.
I have the stored procedure name.
How can i print the stored procedure content?
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Here is a snippet of my code:
if
then
echo "\n Deleting all reports older than 24 hours. \n" >> $logfile
ls -l $FileName >> $logfile
... (1 Reply)
Discussion started by: mh53j_fe
1 Replies
2. Shell Programming and Scripting
Is it possible to pass unix shell arrays in Oracle stored procedure?
Is yes, how?
Thanks (6 Replies)
Discussion started by: superprogrammer
6 Replies
3. Shell Programming and Scripting
hai,
can anybody say how to call or to execute an oracle stored procedure in oracle from unix...
thanks in advance.... for ur reply....
by,
leo (2 Replies)
Discussion started by: Leojhose
2 Replies
4. Shell Programming and Scripting
Here's a shell script snippet.....
cd $ORACLE_HOME/bin
Retval=`sqlplus -s <<eof
$TPDB_USER/april@$TPD_DBCONN
whenever SQLERROR exit 2 rollback
whenever OSERROR exit 3 rollback
set serveroutput on
set pages 999
var status_desc char(200)
var status_code... (1 Reply)
Discussion started by: hidnana
1 Replies
5. Shell Programming and Scripting
Hi
i am calling a stored procedure from unix shell like this call
test_proc('0002','20100218');
the stored procedure was giving output
like this dbms_output.put_line(' processed earlier');
i want to see the output in the unix shell where i called.
Thanks
barani (6 Replies)
Discussion started by: barani75
6 Replies
6. Shell Programming and Scripting
Hi
i want to call a oracle stored procedure from unix (using bash shell).
consider this is my oracle stored procedure with parameter
create procedure testproc(name IN varchar, age IN Number, id OUT Number )
AS
begin
id=1;
dbms_output.put.line('successfull validation')
end;... (6 Replies)
Discussion started by: barani75
6 Replies
7. Shell Programming and Scripting
Hi,
Can you assist me in how to redirect the output of oracle stored procedure from unix script?
Something similar to what i did for sybase
isql -U$MYDBLOG -D$MYDBNAME -S$MYDBSVR -P$MYDBPWD -o$MYFILE<< %%
proc_my_test 8
go
%%
Thanks in advance - jak (0 Replies)
Discussion started by: jakSun8
0 Replies
8. Shell Programming and Scripting
Hi Everyone,
I want to create a script where i need to run the oracle stored procedure from unix script and get the output(sequence number ) into a variable which i will pass in my datastage job.
Below is my stored procedure:-
DECLARE
P_TRANSTYPE VARCHAR2(20);
... (4 Replies)
Discussion started by: prasson_ibm
4 Replies
9. Shell Programming and Scripting
Friends,
I'm newbie with ksh so wanting some help....
1. I'm trying to call oracle stored procedure from ksh script by taking variable value from runtime, feed into script and execute procedure.
2. Put name1 and name2 value from script run replacing $3 & $4
I'm trying to put name1 in... (4 Replies)
Discussion started by: homer4all
4 Replies
10. Shell Programming and Scripting
Friends,
I pass some runtime arguments (date, number) through ksh script to Oracle procedure, use input value and pass it on to procedure.
Oracle procedure gets input value, run query and logs everything in the logfile.
I'm facing with couple of challenges
1. Even though I pass all... (5 Replies)
Discussion started by: homer4all
5 Replies
LEARN ABOUT PHP
mssql_bind
MSSQL_BIND(3) MSSQL_BIND(3)
mssql_bind - Adds a parameter to a stored procedure or a remote stored procedure
SYNOPSIS
bool mssql_bind (resource $stmt, string $param_name, mixed &$var, int $type, [bool $is_output = false], [bool $is_null = false], [int
$maxlen = -1])
DESCRIPTION
Binds a parameter to a stored procedure or a remote stored procedure.
PARAMETERS
o $stmt
- Statement resource, obtained with mssql_init(3).
o $param_name
- The parameter name, as a string.
Note
You have to include the @ character, like in the T-SQL syntax. See the explanation included in mssql_execute(3).
o $var
- The PHP variable you'll bind the MSSQL parameter to. It is passed by reference, to retrieve OUTPUT and RETVAL values after the
procedure execution.
o $type
- One of: SQLTEXT, SQLVARCHAR, SQLCHAR, SQLINT1, SQLINT2, SQLINT4, SQLBIT, SQLFLT4, SQLFLT8, SQLFLTN.
o $is_output
- Whether the value is an OUTPUT parameter or not. If it's an OUTPUT parameter and you don't mention it, it will be treated as a
normal input parameter and no error will be thrown.
o $is_null
- Whether the parameter is NULL or not. Passing the NULL value as $var will not do the job.
o $maxlen
- Used with char/varchar values. You have to indicate the length of the data so if the parameter is a varchar(50), the type must
be SQLVARCHAR and this value 50.
RETURN VALUES
Returns TRUE on success or FALSE on failure.
EXAMPLES
Example #1
mssql_bind(3) example
<?php
// Connect to MSSQL and select the database
mssql_connect('KALLESPCSQLEXPRESS', 'sa', 'phpfi');
mssql_select_db('php');
// Create a new stored prodecure
$stmt = mssql_init('NewUserRecord');
// Bind the field names
mssql_bind($stmt, '@username', 'Kalle', SQLVARCHAR, false, false, 60);
mssql_bind($stmt, '@name', 'Kalle', SQLVARCHAR, false, false, 60);
mssql_bind($stmt, '@age', 19, SQLINT1, false, false, 3);
// Execute
mssql_execute($stmt);
// Free statement
mssql_free_statement($stmt);
?>
SEE ALSO
mssql_execute(3), mssql_free_statement(3), mssql_init(3).
PHP Documentation Group MSSQL_BIND(3)