Re: Dates, command parameters and SQL Server
- From: "Mark J. McGinty" <mmcginty@xxxxxxxxxxxxxxx>
- Date: Mon, 30 May 2005 06:36:03 -0700
"Mark" <mark@xxxxxxxxxx> wrote in message
news:ItAme.1377$%h4.26@xxxxxxxxxxxxxxxxxxxxxxx
> Hi
>
> I am having trouble firing a stored procedure that has a date parameter
> using ADO command etc. Sometimes the date may not be completed so I want
> to pass null back but it won't let me. Although the column type is
> dateTime the parameter is nVarchar (SP was generated by a wizard as a
> test), but even if I pass a zero length string it still inserts a date.
>
> Do I need to place an IF statement in the SP or is there something I Can
> pass from the command parameter that will get recognised as null?
To pass null in a varchar/nvarchar parameter, you must set the Size property
of the parameter to 30.
-Mark
> Thanks inn advance
>
> Mark
>
.
- Follow-Ups:
- Re: Dates, command parameters and SQL Server
- From: Mark
- Re: Dates, command parameters and SQL Server
- References:
- Dates, command parameters and SQL Server
- From: Mark
- Dates, command parameters and SQL Server
- Prev by Date: Dates, command parameters and SQL Server
- Next by Date: Re: Dates, command parameters and SQL Server
- Previous by thread: Dates, command parameters and SQL Server
- Next by thread: Re: Dates, command parameters and SQL Server
- Index(es):
Relevant Pages
|
|