SQL Server Performance

Hold output of an SQL statement called by software & release after successful execution of 2nd SQL

Discussion in 'SQL Server 2005 General DBA Questions' started by bsethi24, Aug 6, 2011.

  1. bsethi24 New Member

    Dear All,

    Hi! I have an online application, which uses ms-sql 2005 database as back-end. In this application lots of Entry forms & reports are there.

    Now my problem is - On load of an Entry Form 2 SQL statements executed (at server end) one by one within 1-2 seconds (One has SQL user defined function & Second has an Stored Procedure). Here, both don't have any dependency and/or relationship on each other.

    Now I need to hold the output of first sql within Sql & after successful execution of second sql re-run the first sql and release the new output to online Application.

    It's not for any type of destructive working. It's for constructive working, as I don't want to make change in Source Code of online application & need to change the output of first sql without changing Sauce Code of application.

    Kindly guide.
  2. AJITH123 Member

    Seems you need to hold the function result and the successfull execution of sproc you need to execute the function right..if this is the scnario you can modify the function and check the procedure has executed or not and based of this flag the function should produce the actual result.

Share This Page