Solved

stored procedure does not fire from ASP.NET after site is deployed

Posted on 2014-04-16
1
307 Views
Last Modified: 2016-02-10
I have a stored procedure that fires an SSIS package from a button click event on an asp.net C# web site.  The sql server that the SSIS package is deployed on is a server on the network.  The sql server is not on my development machine.  When running the website in debug mode from the development machine, the stored procedure fires correctly.  After deployment, the stored procedure does not fire.  No error messages, just nothing.

Here is the code to fire the stored procedure:

 public partial class frm_Import : System.Web.UI.Page
    {
        private String strConnString = ConfigurationManager.ConnectionStrings["SSISString"].ConnectionString;


        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void Button1_Click(object sender, EventArgs e)
        {

            using (SqlConnection _conn = new SqlConnection(strConnString))
            using (SqlCommand _cmd = new SqlCommand("dbo.execute_ssis_package_sample", _conn))
{  
   _cmd.CommandType = CommandType.StoredProcedure;

   _cmd.Parameters.Add(new SqlParameter("@output_execution_id", SqlDbType.Int));
   _cmd.Parameters["@output_execution_id"].Value = 5; // whatever value you want

   _conn.Open();
   object result = _cmd.ExecuteScalar();
   _conn.Close();

   

}
    }

Here is the Connection string:

 <add name="SSISString" connectionString="Data Source=SERVERNAME\MS2012;Initial Catalog=master;Integrated Security=true" />


When I use sql server authentication In the connection string I get a error that windows security is required.  

Again, I get no error message with the existing code.  it just does nothing after deployment, but works fine on the development machine.
0
Comment
Question by:rtay
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 51

Accepted Solution

by:
Mark Wills earned 500 total points
ID: 40005828
Sounds like it is unable to resolve the windows user / security issues.

On top of that there are SSIS roles and more importantly the SQL Server Agent roles.

I am guessing that in dev you are part of a privileged group ?

So... two MS articles to check : http://technet.microsoft.com/en-us/library/ms141053.aspx and http://technet.microsoft.com/en-us/library/ms188283.aspx

And a fairly thorough walkthrough : http://armordba.wordpress.com/2013/04/29/executing-a-sql-server-2012-ssis-package-with-a-proxy-account-with-least-rights-across-domains/

Now, the links above are for 2012 (in the TechNet versions, use the drop down the get to the correct version). The last one uses SSISDB being 2012 and you might need to adjust for MSDB in earlier versions.
0

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.
HTML5 has deprecated a few of the older ways of showing media as well as offering up a new way to create games and animations. Audio, video, and canvas are just a few of the adjustments made between XHTML and HTML5. As we learned in our last micr…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question