Unable to execute a procedure via an odbc dsn

Hi forum,
I'm facing an unique problem.
When I execute a procedure (through sql advantage) that has a call to another procedure on a remote server, it works fine.But when I connect to sybase server via an ODBC or OLEDB dsn, it displays a message as "Login to site '%S_SRVID' failed". The connection works perfect when i execute other procedures that do not have a call to any remote procedure.
If anybody can help...

Oops, missed SQL Server thing. You are on erong forum. Anyway, to execute it in SQL Server use:
execute process_040_series '01-OCT-09','31-OCT-09'SY.

Similar Messages

  • Execute Oracle procedure via Linked server takes very long

    Exec ('Begin [procedurename]; End;') at OracleLinkedServer
    I used this statement to execute store procedure on Oracle database via linked server. It keeps running and never ends.
    However, if I run this procedure Begin [procedurename]; End; in TOAD, it completes in 10s. 
    This procedure is just simply to merge data between two tables.
    Is there any bug or limit on SQL Server Oracle linked server? I am using SQL SERVER 2012 and Oracle 11g client.

    See if this link helps you
    http://markmal.blogspot.co.il/2008/01/it-is-really-pain-if-you-need-to-call.html
    select * from openquery(MYORADB, '{CALL SCOTT.PROC4MS({resultset 25, OUTPUT})}');
    SELECT * FROM OPENQUERY(<linked server name>, '{CALL <oracle sp>}')
    Best Regards,Uri Dimant SQL Server MVP,
    http://sqlblog.com/blogs/uri_dimant/
    MS SQL optimization: MS SQL Development and Optimization
    MS SQL Consulting:
    Large scale of database and data cleansing
    Remote DBA Services:
    Improves MS SQL Database Performance
    SQL Server Integration Services:
    Business Intelligence

  • Help: Unable to execute a procedure

    Hello Folks,
    Am having a procedure and am trying to execute the procedure in the querytool of sql server. Somehow its returning back with an error.
    I have no clue where am going wrong. Please advice if anyone has any idea.Thanks
    execute process_040_series(01-OCT-09,31-OCT-09)
    its returning Msg 170, Level 15, State 1
    Line 1: Incorrect syntax near '01'.
    /*for refernce this is the code behind procedure */
    CREATE PROCEDURE process_040_series (@start_date     smalldatetime = null ,
                             @end_date       smalldatetime = null, 
                                         @rep_no_in      int = null,
                             @client_code_in char(20) = null,
                             @p_bimonth      int = 0)

    Oops, missed SQL Server thing. You are on erong forum. Anyway, to execute it in SQL Server use:
    execute process_040_series '01-OCT-09','31-OCT-09'SY.

  • Unable to execute packaged procedure in PLSQL

    DECLARE
    CURSOR c1
    IS
    SELECT NAME
    FROM v$hm_check
    WHERE internal_check = 'N' AND NAME NOT LIKE '%ASM%';
    sql_text VARCHAR2 (2000) := NULL;
    random_value VARCHAR2 (50);
    BEGIN
    FOR hm_check IN c1
    LOOP
    random_value := dbms_random.string('U', 20);
    sql_text :=
    'dbms_hm.run_check('''
    || hm_check.NAME
    || ''','''
    || random_value
    || ''',null,null);';
    DBMS_OUTPUT.put_line (sql_text);
    EXECUTE IMMEDIATE (' begin ' || sql_text || ' end; ');
    END LOOP;
    END;
    Error at line 4
    ORA-48615: Parameter [CF_BL_NUM] value not specified
    ORA-06512: at "SYS.DBMS_HM", line 191
    ORA-06512: at line 1
    ORA-06512: at line 24
    if i exeucte commenting execute immediate then i will be able.. but i want to execute with execute immediate...
    can you please help out.. thanks...

    knowledgespring wrote:
    I changed the code
    sql_text:='begin '||sql_text|| ' end;';
    in the given procedure
    it generates
    begin dbms_hm.run_check('DB Structure Integrity Check','NUCQGGPVQLVJELKJMMGW',null,null); end;
    begin dbms_hm.run_check('CF Block Integrity Check','SYWCMEEPBLYNNQCAQAHV',null,null); end;
    begin dbms_hm.run_check('Data Block Integrity Check','KILLVEYBLEVVEVLAYGGI',null,null); end;
    begin dbms_hm.run_check('Redo Integrity Check','ROJDCYKULSFWURHNCUDY',null,null); end;
    begin dbms_hm.run_check('Transaction Integrity Check','IZLGHJOLXJIIORYMGVFG',null,null); end;
    begin dbms_hm.run_check('Undo Segment Integrity Check','WDXGWDIHQPYHGROYYXOA',null,null); end;
    begin dbms_hm.run_check('Dictionary Integrity Check','HTCZJEIBMNTZYBEECTNX',null,null); end;
    can i execute this one by one??
    I see first one is executed but not the second one or next one...? is there any other way of executing this one time..when all else fails, Read The Fine Manual
    http://docs.oracle.com/cd/E11882_01/appdev.112/e25788/d_hm.htm#CHDGBEBD
    "SELECT name FROM V$HM_CHECK WHERE INTERNAL_CHECK = 'N'
    Above retrieves the list of checks that can be run manually by users."

  • Executing stored procedure via java

    Hi all,
    i have a problem calling a stored procedure in my java code. I found an example at OTN which seems not to be correct. i had the following VB-code to translate to java:
    Set k = Server.CreateObject("ADODB.command")
    With k
    .activeconnection = Db
    .CommandType = 4
    .CommandText = "Get_SK"
    Set vret = .createparameter("vRet", 131, 2) 'Output
    .Parameters.append vret
    .Execute
    End With
    In my java code:
    CallableStatement sproc_stmt = null;
    try {
    sproc_stmt = lsession.connection().prepareCall("{ ? = call TCSDBOWNER.Get_SK}");
    sproc_stmt.registerOutParameter(1,OracleTypes.NUMERIC);
    sproc_stmt.setFetchSize(10);
    sproc_stmt.execute();
    The call generates an id for inserting new rows in the DB. executing the code shown above i got the following error:
    wrong number or types of parameter/arguments
    Is there anybody who can help me? Best regards,
    ak

    Hi,
    thanks for your reply.
    I have the description of this procedure (As you can see in my posting above) So it is definetly a procedure with one input parameter.
    Yes ist it a callable statement as the other one before. So the first one:
    CallableStatement sproc_stmt = lsession.connection().prepareCall("{call Get_SK(?)}");
                   sproc_stmt.registerOutParameter(1,Types.NUMERIC,1);
    ResultSet sproc_result = sproc_stmt.executeQuery();
    Works fine. No more problems with that. It is a procedure with one OUT_PARAMETER and no INPUT_PARAMETER.
    So, the only thing to change (I thought is):
    sproc_stmt = lsession.connection().prepareCall("{ call Get_SKS(?,?)}");
                   sproc_stmt.setInt(2,1);
                   sproc_stmt.registerOutParameter(1,OracleTypes.NUMERIC);
    ResultSet sproc_result = sproc_stmt.executeQuery();
    But this seems not that obvious. I got an error:
    java.sql.SQLException: ORA-01722: invalid number
    ORA-06512: at "SYS.DBMS_SYS_SQL", line 826
    ORA-06512: at "SYS.DBMS_SQL", line 39
    ORA-06512: at "TCSDBOWNER.GET_SKS", line 44
    ORA-06512: at line 1
    So it seems something is wrong with this output parameter!?
    Any more help? Regards,
    ak

  • Calling stored procedure via java

    Hi all,
    i have a problem calling a stored procedure in my java code. I found an example at OTN which seems not to be correct. I know there had been a lot of posting regarding this isue but i did not find the solution.
    I had the following VB-code to translate to java:
    Set k = Server.CreateObject("ADODB.command")
    With k
    .activeconnection = Db
    .CommandType = 4
    .CommandText = "Get_SK"
    Set vret = .createparameter("vRet", 131, 2) 'Output
    .Parameters.append vret
    .Execute
    End With
    In my java code:
    CallableStatement sproc_stmt = null;
    try {
    sproc_stmt = lsession.connection().prepareCall("{ ? = call TCSDBOWNER.Get_SK}");
    sproc_stmt.registerOutParameter(1,OracleTypes.NUMERIC);
    sproc_stmt.setFetchSize(10);
    sproc_stmt.execute();
    The call generates an id for inserting new rows in the DB. executing the code shown above i got the following error:
    wrong number or types of parameter/arguments
    Is there anybody who can help me? Best regards,
    ak

    Hi again,
    this was really ugly:
    Re: Executing stored procedure via java
    Thanks all, regards,
    ak

  • Error ORA-03113 when execute procedure via OEM

    Hi All,
    I got error messages
    ORA-03113: end-of-file on communication channel
    ERROR at line 1:
    ORA-03114: not connected to ORACLE
    when execute procedure via Oracle Enterprise Manager
    Who do you know what 's the problem and how can I resolves ?
    Thanks,
    Mcka

    Solution Description:
    =====================
    The ORA-3113 error is a general error reported by Oracle client tools,
    which signifies that they cannot communicate with the oracle shadow
    process. As it is such a general error more information must be collected
    to help determine what has happened.
    This short article describes what information to collect for an
    ORA-3113 error when the Oracle server is on a Unix platform.
    General Issues:
    ===============
    1) Is it only one tool that encounters the error or
    do you get an ORA-3113 from any tool doing a similar operation?
    If the problem reproduces in SQL*Plus, use this in all tests
    below.
    2) Check if the problem is just restricted to:
    [ ] One particular UNIX user,
    [ ] Any UNIX user
    or [ ] Any UNIX user EXCEPT as the Oracle user.
    3) Check if the problem is just restricted to:
    [ ] One particular ORACLE logon
    or [ ] Any ORACLE logon that has access to the
    relevant tables.
    4) If you have a client-server configuration does this occur from:
    [ ] Any client
    [ ] Just one particular client
    or [ ] Just one group of clients ?
    If so what do these clients have in common ?
    Eg: Software release .
    5) Do you have a second server or database version where the
    same operation works correctly?

  • Executing Stored Procedure within Excel

    I am in the middle of setting up an Excel spreadsheet that will execute a stored procedure I have created and return the results to Excel. Pretty much following the example set here: 
    http://datapigtechnologies.com/blog/index.php/running-a-sql-stored-procedure-from-excel-with-dynamic-parameters/
    But, the problem I am stuck on and unable to yet find an answer to, is can I execute the procedure from within Excel and instead of specifying a parameter enter a WHERE clause. At the moment the last step of my stored procedure is:
    SELECT * FROM MY_TABLE
    WHERE ([PRODUCT] LIKE 'DESK-%') AND (NOT([DISCOUNT VALUE] IS NULL))
    But, I cannot find if it is possible to execute this from within Excel. I am not sure if it I am able to set the WHERE as a parameter which may be the way I should be going about this. 
    Thanks.

    Are you invoking a stored procedure, or are you sending a SELECT statement (ad-hoc query) to the SQL Server?  It seems like you are sending an ad-hoc query.
    If that is the case, I would not put the entire WHERE clause as a parameter. I would do it something like this:
    "SELECT * FROM MY_TABLE WHERE ([PRODUCT] LIKE '" & Range("B2").Value & "%') AND (NOT([DISCOUNT VALUE] IS NULL))"
    That assumes that the parameter that you want to use is in cell B2.
    Ideally, I would prefer not to use ad-hoc queries. Instead, create a stored procedure which takes the Product type as a parameter.  There are lots of examples on the net on how to query SQL Server from Excel via a stored procedure with parameters.

  • How to execute a procedure if out parameter is table type

    Hi,
    I need to execute a procedure, output parameter of the procedure is table type.
    Oracle version I am using is 9.2.0.8 . I am using SQL*Plus
    Procedure declaration
    PROCEDURE current_open_cycle (p_ban IN repl_cust2.billing_account.ban%TYPE,
    v_bill_seq_rec OUT bill_seq_table) ;
    Table type declaration
    TYPE bill_seq_table IS
    TABLE OF bill_seq_rectype INDEX BY BINARY_INTEGER ;
    TYPE bill_seq_rectype IS RECORD (v_cycle_run_year repl_cust2.bill.cycle_run_year%TYPE,
    v_cycle_run_month repl_cust2.bill.cycle_run_month%TYPE,
    v_cycle_code repl_cust2.bill.cycle_code%TYPE,
    v_open_cycle BOOLEAN, -- An open cycle
    v_billed_cycle BOOLEAN, --
    v_invoice_number VARCHAR2(13),
    v_start_date DATE,
    v_end_date DATE,
    v_root_ban repl_cust2.bill.root_ban%TYPE) ;
    I tried executing using this script, but it failed. When I execute this oracle lost connection to data base.
    declare
    r_bill_seq_rec ss_invoice_utilities.bill_seq_table;
    begin
    ss_invoice_utilities.current_open_cycle(934018003,r_bill_seq_rec);
    end;
    Please help me how I should write declare block to execute this procedure and also print output of the procedure.
    Regards
    Raghu

    I don't see anything wrong with the anonymous block, assuming ss_invoice_utilities is the correct package name. Perhaps a simplified test case would show up what's not working there.
    As for printing the contents of an associative array, you'll have to write some code to loop through it and construct a string per row to output via dbms_output, assuming the text will fit within dbms_output's size restrictions in 9i. dbms_output is a debugging tool though - is that the requirement?
    btw "pls_integer" is less to type than "binary_integer" ;)
    Edited by: William Robertson on Apr 16, 2009 8:35 AM

  • Shows output / summary after executing a procedure

    Developers have come to me, with below challenge, I am not able to solve / help with, found nothing from my 1 hour search on Google and forums.
    Is there parameter in database or SQLPlus that shows output / summary after executing a procedure?
    I have few updates and few inserts in my procedures, I also user[b] execute immediate once on my proc.
    I want to know how many rows were updated / inserted, at the moment you just get ‘successfully completed.’ After executing a procedure.
    SQL> @myproc.sql
    PL/SQL procedure successfully completed.If anyone is 100% it's not possible, and you have to do it manually using dbms_output, please let me know.
    Thanks for any help

    PL/SQL executes inside the Oracle server process that is servicing your client session. How can it display anything on the client side?
    SQL*Plus (a typical client) displays information messages such as "PL/SQL procedure successfully completed." - and it reads the DBMS_OUTPUT buffer in PL/SQL and write it to your display (when the SERVEROUTPUT SQL*Plus environment variable is set).
    PL/SQL is incapable of "displaying" anything. Rendering is done the client.
    It is important to grasp this basic client-server concept.
    PL/SQL is also in fact two very distinct languages that are tightly integrated. PL and SQL. When PL executes a SQL statement, it does so via the same basic Oracle call interface as any other language. Part of this call interface contains the results of the SQL statement executed - this not only include a return code, but also the number of rows reported affected by the SQL engine. PL "publishes" that result via its system variable called SQL%ROWCOUNT.
    However, due to the way PL calls SQL with respect to the different ways you can construct SQL in PL (implicit cursors, explicit cursors, ref cursors, etc), this variable is only valid when dealing with an implicit cursor. Cursor "system/SQL" variables also exist and these are prefixed with the variable name of the cursor in the format <cursorvar>%<sqlvar>.
    Details can be found in the [url http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14261/toc.htm]Oracle® Database PL/SQL User's Guide and Reference.

  • RTC-5008 Unable to execute in OWB

    Hi,
    When I execute the mappings in Deployment Manager I get the following error
    RTC - 5008: Unable to execute .....
    Pls let me know if anyone can provide solution for this
    Kishan

    Hi Kishan,
    I'd say you have to re-register your OWB-locations.
    Connect as the Runtime Repository User to check whether the current setup of your locations is valid.
    Look at the content of tables WB_RT_STORES and WB_RT_STORE_PARAMETERS (holds locations and all appropriate attributes).
    Unregistering can only done using Runtime Audit Browser, registering is done using the Deployment Manager or via OMBPlus.
    Good luck, Patrick

  • "GRANT EXECUTE ANY PROCEDURE TO " does not work in some cases

    Hello,
    I some of my PL/SQL-packages I'm using DBMS-packages.
    Because I don't want to grant access for every single package, I granted EXECUTE ANY PROCEDURE to the user/schema of my packages.
    This did work in several installation.
    But for what reason ever, in one installation DBMS_RANDOM cannot be used (DBMS_RANDOM must be declared). If I explicitly grant execute on this package, it works. When I revoke it and renew the ANY PROCEDURE, it doesn't again.
    What's wrong.
    Version 11.2.0.2 on Win2008R2
    Regards,
    Mynz

    Mynz wrote:
    Hello,
    I some of my PL/SQL-packages I'm using DBMS-packages.
    Because I don't want to grant access for every single package, I granted EXECUTE ANY PROCEDURE to the user/schema of my packages.
    This did work in several installation.
    But for what reason ever, in one installation DBMS_RANDOM cannot be used (DBMS_RANDOM must be declared). If I explicitly grant execute on this package, it works. When I revoke it and renew the ANY PROCEDURE, it doesn't again.
    What's wrong.privilege acquired via ROLE do NOT apply within named PL/SQL procedures/functions

  • Unable to execute update commands after improper shutdown

    Hi!
    It sounds a little strange.
    I am unable to execute update commands from my application. My machine was shutdown improperly. Then I loaded the datastores again. I was able to execute select commands but unable to execute update commands. It was working fine before shutdown.
    Regards
    /Ahmad

    Hi Chris!
    SQLExecute method of ODBC is returning -1.
    I have checked the syntax of the query its also correct. I am also very confused on it why is this happening. If I execute the update command from ttisql it works ok.
    The code is the same that we discussed in our previous conversation.
    The steps I did after improper shutdown:
    1. Started TimeTen daemon >ttdaemonadmin -start
    2. Loaded the Data store >ttAdmin -ramLoad spiderM
    3. Executed the code
    The output of ttstatus is as follows:
    TimesTen status report as of Fri Jun 29 21:45:41 2007
    Daemon pid 8273 port 17001 instance tt70
    TimesTen server pid 8284 started on port 17003
    TimesTen webserver pid 8280 started on port 17005
    Data store /tmp/spiderM
    There are 6 connections to the data store
    Data store is in shared mode
    Shared Memory KEY 0x08004f3c ID 557070
    Type PID Context Connection Name ConnID
    Subdaemon 8278 0x0000000000570520 Worker 2042
    Subdaemon 8278 0x00000000005dc4d0 Flusher 2043
    Subdaemon 8278 0x000000000060d5d0 Checkpoint 2044
    Subdaemon 8278 0x000000000063e5a0 Aging 2045
    Subdaemon 8278 0x000000000066f570 HistGC 2046
    Subdaemon 8278 0x00000000006a0430 Monitor 2047
    RAM residence policy: Manual
    Data store is manually loaded into RAM
    Replication policy : Manual
    Cache agent policy : Manual
    Data store /usr/users/spider/TimesTen/tt70/info/TT_tt70
    There are no connections to the data store
    Replication policy : Manual
    Cache agent policy : Manual
    Access control enabled.
    End of report
    Regards
    /Ahmad

  • Unable to execute transaction S_ALR_87013542

    Hi all,
    I am unable to execute the above tcode. Whenever this transaction is executed, nothing happens.
    Currently I have to execute this tcode via program 'GP0YUXRUZYY9JFVAAF55MKIVHFJ100' to get to this transaction.
    Anybody know why this happens?
    Appreciate your feedback.
    Rgds,
    SS

    Hi,
    In case one is using these reports first time, it is advisable to generate them so that the Reports are executed from the respective Tcode.
    To generate all such reports go To Tcode:OKS7 and select all and hit generate and later Save.
    Hope it helps...
    Thanks!!!

  • Unable to execute a remote proc

    Hi I am unable to execute a remote procedure from forms6i, and that procedure runs coolly form sql plus console. I just dont get any exception or error. Thats really pathetic for me now.
    I need help.
    thanx Rajeev

    Hi ,
    Remote procedure means the procedure in database. My database is in solaris, d2k on win2k and other database on win2k. I am executing a remote procedure on solaris Oracle db to poll data from win2k db using forms, i.e. on button click. The form user and the solaris db users are same. I am using dblink here.
    Hope this helps in clarifying my query further.
    thanx

Maybe you are looking for

  • Airport Utility won't let me change time capsule settings....

    I've had my TC about 2 weeks, and haven't had any problems until now.... when I am in close proximity, i use it with an ethernet cable, and if i am in other parts of the house i will set it to transmit wirelessly. up until now there hasn't been any p

  • Sheduling Agreement item are not appearing in MIGo

    Hi, Good receipt (MIGO) for Sheduling  Agreement some items are not display(not appear in item detail screen in MIGO) Delivery shedule is maintain and SA is released where to check to slove this problem. shakir

  • File Sharing with SharePoint

    Dear friends... i need advise from all of you.. i am not frm SP... i have a requirement from my client where they want to use a file sharing / DMS system which can provide them versioning .. access over Internet(Secure) may be with dual level authent

  • How to read date as string (format dd-mm-yyyy) and store it as Date object

    Hi. I would like to read from keyboard String with a date and put this value to Date object. How can i do this??? Thanks

  • Updating indesign Pantone swatch books

    why is it that the pantone book references in design cs4 do not tally up with the pantone books that i have, i am using up to date books with with like for like matches i.e pantone solid uncoated in indesign and in the reference book, yet there is a