How to EXECUTE a stored procedure from web page RRS feed

  • Question

  • I am a NEWBIE! Please help.

    I am designing a dynamic data web site using Visual Web Developer 2008 Express and SQL Seerver 2008 Express with SQL Server Business Intelligence Development Studio with Windows XP Pro SP3.
    The application is for a Golf League which will enable members to enter their raw scores. Then I have 2 stored procedures to calculate the Net Scores of each member (Raw Score - Handicap) and calculate points awarded for each hole.
    In order to keep the historic data, since handicaps will change, I have a check box field that the query sets to true after it is run so only new data is calculated. I have the Reports working but I need to be able to execute the 2 stored procedures from the web application, preferably automatically just prior to the Report generation.

    I have tried to execute them in the report query but it didn't work.

    Sunday, March 7, 2010 6:34 PM


  • hi,
    I did probably not correctly understant your requirement, but (just a question of mine), why can those 2 stored procedure not be executed soon after each player updates her scores?
    I'm meaning, the player (or whatever person) updates her scores filling a "form" which in turn will execute an INSERT stored procedure...
    you can "cascade" the hystorical data pipelining in that procedure code execution like
    CREATE PROC dbo.usp_AddScores (
       @Player ...,
       @Score ...,
       @Date ....,
       INSERT INTO dbo.PlayerScores VALUES ( @Player, @Score, @Date );

       EXEC dbo.usp_UpdateNetScore @Player;
       EXEC dbo.usp_UpdateHandicap @Player;

    or the like..
    this should automatically and immediately updates the hystorical data as required, so that if I query your app soon after I played my last game I can immediately see my "current updated" values..

    did I get the point?
    http://www.asql.biz - DbaMgr2k - DbaMgr and further SQL Tools
    • Marked as answer by jimr46 Monday, March 8, 2010 2:44 AM
    Monday, March 8, 2010 1:19 AM