Procedure or function Authorize_Member has too many arguments specified

Discussion in 'ASP .Net' started by Seth Williams, Sep 16, 2008.

  1. I have a sqlDataSource, using a stored procedure - the datasource is:
    <asp:SqlDataSource ID="dsMembers" runat="server"
    ConnectionString="<%$ ConnectionStrings:MainConnectionString %>"
    SelectCommand="Get_MemberToUpdate"
    SelectCommandType="StoredProcedure"
    UpdateCommand="Authorize_Member"
    UpdateCommandType="StoredProcedure">
    <SelectParameters>
    <asp:QueryStringParameter Name="MemberID"
    QueryStringField="id" Type="Int32" />
    </SelectParameters>
    <UpdateParameters>
    <asp:parameter Name="memberID" Type="Int32" />
    <asp:parameter Name="Authorized" Type="Boolean" /> ' This is
    a bit field in the database
    </UpdateParameters>
    </asp:SqlDataSource>

    The DetailsView has the DataKeyNames property set correctly - - This was
    working and I don't remember changing it in any way.
    What could be the problem?
     
    Seth Williams, Sep 16, 2008
    #1
    1. Advertising

  2. I forgot to mention that I get this error message only when Updating
    Here's the sProc:
    create PROCEDURE [dbo].[Authorize_Member]
    @memberID INT,
    @Authorized Bit
    AS
    BEGIN
    UPDATE [dbo].[Members]
    SET [Authorized] = @Authorized
    WHERE MemberID=@MemberID



    I have a sqlDataSource, using a stored procedure - the datasource is:
    <asp:SqlDataSource ID="dsMembers" runat="server"
    ConnectionString="<%$ ConnectionStrings:MainConnectionString %>"
    SelectCommand="Get_MemberToUpdate"
    SelectCommandType="StoredProcedure"
    UpdateCommand="Authorize_Member"
    UpdateCommandType="StoredProcedure">
    <SelectParameters>
    <asp:QueryStringParameter Name="MemberID"
    QueryStringField="id" Type="Int32" />
    </SelectParameters>
    <UpdateParameters>
    <asp:parameter Name="memberID" Type="Int32" />
    <asp:parameter Name="Authorized" Type="Boolean" /> ' This is
    a bit field in the database
    </UpdateParameters>
    </asp:SqlDataSource>

    The DetailsView has the DataKeyNames property set correctly - - This was
    working and I don't remember changing it in any way.
    What could be the problem?
     
    Seth Williams, Sep 16, 2008
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mike P
    Replies:
    0
    Views:
    3,317
    Mike P
    Jun 19, 2006
  2. Mike
    Replies:
    3
    Views:
    490
  3. David Lozzi
    Replies:
    0
    Views:
    693
    David Lozzi
    Mar 2, 2007
  4. John Smith

    Procedure or function has too many arguments specified

    John Smith, Jun 29, 2005, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    149
    John Smith
    Jun 29, 2005
  5. c676228
    Replies:
    2
    Views:
    184
    c676228
    Sep 14, 2006
Loading...

Share This Page