Results 1 to 3 of 3
  1. #1
    Join Date
    Feb 2004
    Location
    Burbank & Santa Cruz de la Sierra
    Posts
    3,716

    Angry Unanswered: ARGH!!! Can't pass smalldatetime to stored procedure in DEBUGGER!

    I know this is probably user error, but here's the scoop:

    I have a stored procedure...

    CREATE PROCEDURE [dbo].[sp_Build_CurrentPortfolio_By_Date]
    @NewDate smalldatetime

    and when I try to run it in debug in the SQL Query Analyzer, I sent in the parameter via the debug interface as '2004/02/02', and as GETDATE(), and a number of other formats, but cannot even get into the procedure once debugger starts up!

    I get the following error once I hit "execute" after putting in the above data in the parameter text box...

    [Microsoft][ODBC SQL Server Driver]Invalid character value for cast specification

    HELP PLEASE!!! (I'm about to punch my new monitor!!!)
    aka "Paul"
    Non est ei similis.

    I just read "100 Things To Do Before You Die". I was surprised that "Yell for help!!" wasn't one of them

  2. #2
    Join Date
    Jul 2003
    Location
    San Antonio, TX
    Posts
    3,662
    Remove apostrophe and pass it as 2004-02-02 00:00:00.000

  3. #3
    Join Date
    Feb 2004
    Location
    Burbank & Santa Cruz de la Sierra
    Posts
    3,716

    Thumbs up THANKYOUTHANKYOUTHANKYOU!!

    I LOVE YOU, Man!!!

    why, if'n I wasn't already married...

    That worked...thanks so much!

    I'll hafta file that one on my scorch list!!!

    Thanks again!
    Paul
    aka "Paul"
    Non est ei similis.

    I just read "100 Things To Do Before You Die". I was surprised that "Yell for help!!" wasn't one of them

Posting Permissions

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