Results 1 to 3 of 3

Thread: 5701 Changed database context to... using SQL 7 Stored Proc's

  1. #1
    Neal Walters Guest

    5701 Changed database context to... using SQL 7 Stored Proc's


    I'm trying to use SQL 7 stored procedures to implement something like
    example B7 where I allow users to signon and only show them to update
    records that they should be able to update.

    I first got the error in my B7 code, then I simplified down
    to a hardcoded simple ASP that tries to do a view (without
    all the logon stuff).

    ASP code set if SQL statement:
    mydb.SQL = "EXEC training_usp1 @parm1=abc"
    I also have:
    MyDB.dbDBType = "SQL"


    Listing of Stored Procedure:

    CREATE PROCEDURE training_usp1
    @parm1 char(12) = NULL
    AS
    SELECT tr_exam, tr_classname, tr_city, tr_metroplex, tr_state,
    tr_country, tr_date_from, tr_date_to, tr_cost, trp_comp_name,
    tr_teacher
    from training, trprovider
    where tr_provider_id = trp_id
    and trp_userid = @parm1




    I'm getting the following error:
    Error # = 0
    Description = [Microsoft][ODBC SQL Server Driver][SQL Server]Changed database context to 'abcdefg'.
    Source = Microsoft OLE DB Provider for ODBC Drivers
    SQL State = 01000
    NativeError = 5701

    NOTE: "abcdefg" is my userid and database name.

    followed by

    Error # = 0
    Description = [Microsoft][ODBC SQL Server Driver][SQL Server]Changed language setting to us_english.
    Source = Microsoft OLE DB Provider for ODBC Drivers
    SQL State = 01000
    NativeError = 5703

    Any ideas?
    Thanks in advance,
    Neal Walters
    http://ITCoolStuff.com



  2. #2
    Frank Guest

    5701 Changed database context to... using SQL 7 Stored Proc's (reply)


    use the stored procedures properties when dealing with SPs and not dbSQL.

    dbStoredProc
    dbStoredProcCmdParams



    FK



    ------------
    Neal Walters at 2/28/00 12:40:33 AM


    I'm trying to use SQL 7 stored procedures to implement something like
    example B7 where I allow users to signon and only show them to update
    records that they should be able to update.

    I first got the error in my B7 code, then I simplified down
    to a hardcoded simple ASP that tries to do a view (without
    all the logon stuff).

    ASP code set if SQL statement:
    mydb.SQL = "EXEC training_usp1 @parm1=abc"
    I also have:
    MyDB.dbDBType = "SQL"


    Listing of Stored Procedure:

    CREATE PROCEDURE training_usp1
    @parm1 char(12) = NULL
    AS
    SELECT tr_exam, tr_classname, tr_city, tr_metroplex, tr_state,
    tr_country, tr_date_from, tr_date_to, tr_cost, trp_comp_name,
    tr_teacher
    from training, trprovider
    where tr_provider_id = trp_id
    and trp_userid = @parm1




    I'm getting the following error:
    Error # = 0
    Description = [Microsoft][ODBC SQL Server Driver][SQL Server]Changed database context to 'abcdefg'.
    Source = Microsoft OLE DB Provider for ODBC Drivers
    SQL State = 01000
    NativeError = 5701

    NOTE: "abcdefg" is my userid and database name.

    followed by

    Error # = 0
    Description = [Microsoft][ODBC SQL Server Driver][SQL Server]Changed language setting to us_english.
    Source = Microsoft OLE DB Provider for ODBC Drivers
    SQL State = 01000
    NativeError = 5703

    Any ideas?
    Thanks in advance,
    Neal Walters
    http://ITCoolStuff.com



  3. #3
    Neal Walters Guest

    5701 Changed database context to... using SQL 7 Stored Proc's (reply)

    Found this description in online help for MS/SQL.
    It says the error is informational only, so why does ASPDB choke on it?

    Thanks,
    Neal Walters
    http://ITCoolStuff.com

    -------------------------------

    Error 5701
    Severity Level 10
    Message Text
    Changed database context to '%.*ls'.

    Explanation
    This is an informational message indicating that the database context has changed. This message is returned anytime a USE database statement is executed.

    Action
    None needed.

    See Also


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •