Sponsored Content
Contact Us Post Here to Contact Site Administrators and Moderators How to Post in the The UNIX and Linux Forums Calling a Sybase Stored procedure from a UNIX Script Post 302990243 by Don Cragun on Tuesday 24th of January 2017 03:41:22 AM
Old 01-24-2017
Moderator's Comments:
Mod Comment This thread is file in an inappropriate forum and duplicates the thread Sybase Stored Proc call from UNIX script.

Continue any discussion on this topic there.

This thread is closed.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

calling stored procedure from shell script.

Hi All, This is a very starnge problem I am having. I have a shell script that calls a stored procedure. Here's my code in shell script: sqlplus "userid/pwd" @file.sql and file.sql has the following statement: exec my_storedProc; Now, when I execute my shell script, nothing... (2 Replies)
Discussion started by: priyamurthy2005
2 Replies

2. Shell Programming and Scripting

Calling MYSQL Stored Procedure?

Hi, Can anyone help me with the correct syntax to call a MYSQL stored procedure from a shell script. I have tried the following, (no input params): /usr/bin/mysql -uadmin -ppassword call TL_CLENSEDATA(); resulting in error: /home/hosting/data/scripts/dbclense.sh: line 12: syntax error... (3 Replies)
Discussion started by: kshelluser
3 Replies

3. Shell Programming and Scripting

Calling stored procedure from shell script

HI, I have a similar problem to thread 18264, only I couldn't get it to work. https://www.unix.com/showthread.php?t=18264 I have a stored procedure which is called by a shell script program. When I run the stored procedure alone or through the shell script, it works fine with output text... (3 Replies)
Discussion started by: dorisw
3 Replies

4. Shell Programming and Scripting

Calling an Oracle Stored Procedure from Unix shell script

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

5. Shell Programming and Scripting

Error when calling sybase stored proc from shell script

Hi, I am writing a script that needs to call a stored proc which would update a column in a table based on a condition. I need to also capture the number of rows updated. However, When I execute the script I keep getting this error: ./test_isql.sh: syntax error at line 33: `end of file'... (3 Replies)
Discussion started by: karthikk
3 Replies

6. UNIX for Dummies Questions & Answers

Calling stored procedure from unix

Hi, My stored procedure returns a value. How to retrieve the value and display in unix. Stored procedure CREATE OR REPLACE PROCEDURE gohan(num INT) IS BEGIN DBMS_OUTPUT.PUT_LINE('My lucky number is ' || num); END; Unix Scripting i used sqlplus -s... (7 Replies)
Discussion started by: gohan3376
7 Replies

7. Shell Programming and Scripting

Execute stored procedure through script in sybase database and store the output in a .csv file

Hi, I have a sybase stored procedure which takes two input parameters (start_date and end_date) and when it get executed, it gives few records as an output. I want to write a unix script (ksh) which login to the sybase database, then execute this stored procedure (takes the input parameter as... (8 Replies)
Discussion started by: amit.mathur08
8 Replies

8. Shell Programming and Scripting

Calling Oracle stored procedure from ksh script

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

9. Post Here to Contact Site Administrators and Moderators

Calling Sybase Stored proc from UNIX Shellscript.

Hi, I am new to shell scripting and Sybase database i need a help that i try to execute a SYBASE stored procedure from a Unix shell script and wanna write the output of the SP into a Text File, somehow i tried to find a solution but when i try to run the script i am not getting the output file with... (1 Reply)
Discussion started by: Arun619
1 Replies

10. Shell Programming and Scripting

Sybase Stored Proc call from UNIX script.

Hi, I am new to shell scripting and Sybase database i need a help that i try to execute a SYBASE stored procedure from a Unix shell script and wanna write the output of the SP into a Text File.somehow i try to find a solution but whwn i try to run the script i am not getting the output file with... (1 Reply)
Discussion started by: Arun619
1 Replies
ns_thread(3aolserver)					    AOLserver Built-In Commands 				     ns_thread(3aolserver)

__________________________________________________________________________________________________________________________________________________

NAME
ns_thread - commands SYNOPSIS
ns_thread begin script ns_thread begindetached script ns_thread get ns_thread getid ns_thread wait tid ns_thread yield _________________________________________________________________ DESCRIPTION
ns_thread begin: begins a new thread which evaluates the specified script and then exits. It returns a thread ID that must eventually be passed to ns_thread wait. (Failing to call ns_thread wait will eventually result in no new threads being created.) ns_thread begindetached: begins a detached thread that doesn't have to be (and can't be) waited for. ns_thread get: gets the thread ID of the current thread. The result is a thread ID that can be passed to ns_thread wait and may look something like "tid532". ns_thread getid: gets the thread integer number for the current thread. The result is a small integer used for identifying threads is a human-read- able way, such as "1" or "1120", for example. ns_thread wait: waits for the specified thread to exit. The tid argument is a thread ID returned by ns_thread begin or ns_thread get. ns_thread yield: causes the current thread to yield. EXAMPLES
This example is similar to the example under the ns_sockselect function of connecting to the 10 servers and waiting to service them with the ns_sockselect command. In this case, though, each connection gets it's own thread. # This is the procedure which is evaluated for each thread and # handles a single connection to host number $i proc getpage {i} { global pages # new thread will start here - first connect to host set host [format "www%2d.foo.com" $i] set fds [ns_sockopen $host 80 set r [lindex $fds 0] set w [lindex $fds 1] # next, send request 0r" puts $w "GET /index.htm HTTP/1.0 flush $w # then read page set pages($i) [read $r] # and close sockets close $w close $r # thread goes away here and other threads waiting # on ns_thread wait will wakeup } # Here's the loop which creates the threads which run getpage. for {set i 1} {$i < 9} {incr i} { set tids($i) [ns_thread begin "getpage $i"] } # wait for the threads to exit and then process the pages for {set i 1} {$i < 9} {incr i} { ns_thread wait $tids($i) # output page ... process the page in $pages($i) put there by other thread ... } Note that the code here is much simpler to follow than the ns_sockselect example; that's the benefit of multithreaded programming. However, it uses more resources as threads need to be created and initialized. This can be a problem if you plan to create many threads. SEE ALSO
KEYWORDS
threads AOLserver 4.0 ns_thread(3aolserver)
All times are GMT -4. The time now is 09:45 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy