How to call stored procedure with CLOB out parameter from shell script?


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting How to call stored procedure with CLOB out parameter from shell script?
# 1  
Old 12-21-2011
How to call stored procedure with CLOB out parameter from shell script?

I have written a stored procedure in oracle database, which is having a CLOB OUT parameter. How can i call this stored procedure from shell script and get the CLOB object in shell script variable?
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

How to call a stored procedure inside a loop?

How to call a stored procedure inside a loop export PATH=$ORACLE_HOME/bin:$PATH ORACLE_SID=xxxx; export ORACLE_SID ORAENV_ASK=NO TODAY_DATE=$(date +"%Y%m%d") LOGFILE=/var/opt/gogd/cust/scripts/${TODAY_DATE}_sap_cust_rel.log echo 'Connected' PARCUST=sap_cust_rel.par sqlldr... (1 Reply)
Discussion started by: ashwanth
1 Replies

2. Shell Programming and Scripting

How to get OUT parameter of a stored procedure in shell script?

I am invoking a SQL script from shell script. This SQL script will invoke a stored procedure(which has the OUT parameter). I want to have the OUT parameter in the shell script as a variable. Is this possible? (6 Replies)
Discussion started by: vel4ever
6 Replies

3. Shell Programming and Scripting

How to write CLOB parameter in a file or XML using shell script?

I executed a oracle stored procedure using shell script. How can i get the OUT parameter of the procedure(CLOB) and write it in a file or XML in UNIX environment using shell script? (2 Replies)
Discussion started by: vel4ever
2 Replies

4. Shell Programming and Scripting

How to call a stored procedure from shell program?

How to call a stored procedure from shell program (1 Reply)
Discussion started by: noorm
1 Replies

5. Shell Programming and Scripting

Call and redirect output of Oracle stored procedure from unix script

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

6. Shell Programming and Scripting

how to call oracle stored procedure from unix shell

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. Programming

How to call sqlloader from stored procedure!!! Advise

Hi , I have a dellimited .dat file and a sqlloader. I want to call the sqlloader from a oracle stored procedure. The procedure should return the result of sqlloader's execution. (3 Replies)
Discussion started by: Haque123
3 Replies

8. Shell Programming and Scripting

need to call 3 stored procedure at the same time

Hi GUYS, I need to trigger 3 stored procedure at the same time.. I know how to trigger the stored procedure. If anybody can tell me how to trigger 3 different process at the same time parallelly.. that would be helpful.. Thanks for your help in advance, Magesh (1 Reply)
Discussion started by: mac4rfree
1 Replies

9. Shell Programming and Scripting

Need to call stored procedure from unix script

Hi Guys, I have a stored procedure which has 5 out parameters. I need to call the stored procedure from the script. When i use the following in my script, db2 "CALL FCFM.PART_MASTER_TMP($Return_code,$Message,$Message1,$SQL,$Load_count)" >> $LOG_FILE I am getting an error.. Please... (1 Reply)
Discussion started by: mac4rfree
1 Replies

10. Shell Programming and Scripting

passing parameter 4m shell script to a DB stored procedure

hi all please tell me how to pass parameters 4m shell script to a DataBase stored procedure. To be specific i have sybase DB. i mean i want the syntax of the command.. how to connect to DB, pass user id and password, pass the required parameter to SP.. .. need ur help frnds.. hema (0 Replies)
Discussion started by: hema2026
0 Replies
Login or Register to Ask a Question
CUBRID_LOB2_EXPORT(3)							 1						     CUBRID_LOB2_EXPORT(3)

cubrid_lob2_export - Export the lob object to a file.

SYNOPSIS
bool cubrid_lob2_export (resource $lob_identifier, string $file_name) DESCRIPTION
The cubrid_lob2_export(3) function is used to save the contents of BLOB/CLOB data to a file. To use this function, you must use cubrid_lob2_new(3) or fetch a lob object from CUBRID database first. If the file already exists, the operation will fail. This function will not influence the cursor position of the lob object. It operates the entire lob object. PARAMETERS
o $lob_identifier -Lob identifier as a result of cubrid_lob2_new(3) or get from the result set. o $filename -File name you want to store BLOB/CLOB data. It also supports the path of the file. RETURN VALUES
TRUE if the process is successful and FALSE for failure. EXAMPLES
Example #1 cubrid_lob2_export(3) example <?php // Table: test_lob (id INT, contents CLOB) $conn = cubrid_connect("localhost", 33000, "demodb", "dba", ""); cubrid_execute($conn,"DROP TABLE if exists doc"); cubrid_execute($conn,"CREATE TABLE doc (id INT, doc_content CLOB)"); cubrid_execute($conn,"INSERT INTO doc VALUES (5,'hello,cubrid')"); $req = cubrid_prepare($conn, "select * from doc"); cubrid_execute($req); cubrid_move_cursor($req, 1, CUBRID_CURSOR_FIRST); $row = cubrid_fetch($req, CUBRID_NUM | CUBRID_LOB); cubrid_lob2_export($row[1], "doc_3.txt"); cubrid_lob2_close($row[1]); cubrid_disconnect($conn); ?> SEE ALSO
cubrid_lob2_new(3), cubrid_lob2_close(3), cubrid_lob2_import(3), cubrid_lob2_bind(3). PHP Documentation Group CUBRID_LOB2_EXPORT(3)