Thursday, March 29, 2012
Date Range Parameter Help
I have entered a date range parameter into my report to pick a range for Appointment Dates. When I choose a start date of 01/01/2007 and an end date of 01/31/2007, my report has all of January's appointments, but also has the last appointment of the previous month (in this case December). The same happens if I pick a date range from Feb 1st to the 28th. I get all of Feb appointments, but also the last day in January.
Am I missing something? Or has this happened to anyone else?Are you wanting the dates between your 2 date paramenters, and if so did you reference your date ranges in the record selection?
{table.appointmentdate} In {?StartDate} To {EndDate}
This will give you everything between the 2 dates.
GJ
Monday, March 19, 2012
date help...
Wednesday, March 7, 2012
Date Format
Date is entered on the table on the format of dd/mm/yyyy. When I see the
table I can see it in correct order ddmmyyyy. In the Query Analyzer, I see it
yyyymmdd. In addition the more seriouse proble is that when I right a
statement to choose an exact date or date interval, I have to enter the date
in format mmddyyyy otherwise the SQL will understand the date in wrong format.
Can any one help on that please.
*********
IT Manager
DeLaval Ltd.
Cairo-Egypt
*********
|--|
|Islam is peace not Terror|
|--|
Ibrahim,
See if the following article helps:
http://www.karaszi.com/sqlserver/info_datetime.asp
Anith
|||That site helps a lot, thanks!
>--Original Message--
>Ibrahim,
>See if the following article helps:
>http://www.karaszi.com/sqlserver/info_datetime.asp
>--
>Anith
>
>.
>
Friday, February 24, 2012
Date enquiry
and an entered in parameter?
The following works in giving me the difference from the record to now...
but I need to change the now to the @.to parameter.
DATEDIFF([day], view.DATE, GETDATE()) AS noofdays
ThanksYou can pass the date parameter to the SP and then do the
DateDiff.
>--Original Message--
>How would I do a datediff between the date within a
record in the dataset
>and an entered in parameter?
>
>The following works in giving me the difference from the
record to now...
>but I need to change the now to the @.to parameter.
>
>DATEDIFF([day], view.DATE, GETDATE()) AS noofdays
>Thanks
>
>.
>|||DATEDIFF([day], view.DATE, CAST(@.to, datetime)) AS noofdays
"AshVsAOD" <.> wrote in message
news:%23UmDBoKkEHA.3896@.TK2MSFTNGP15.phx.gbl...
> How would I do a datediff between the date within a record in the dataset
> and an entered in parameter?
>
> The following works in giving me the difference from the record to now...
> but I need to change the now to the @.to parameter.
>
> DATEDIFF([day], view.DATE, GETDATE()) AS noofdays
> Thanks
>|||Thanks!
"D Lee" <dle@.d.com> wrote in message
news:e5jYN0nlEHA.3912@.TK2MSFTNGP12.phx.gbl...
> DATEDIFF([day], view.DATE, CAST(@.to, datetime)) AS noofdays
> "AshVsAOD" <.> wrote in message
> news:%23UmDBoKkEHA.3896@.TK2MSFTNGP15.phx.gbl...
> > How would I do a datediff between the date within a record in the
dataset
> > and an entered in parameter?
> >
> >
> > The following works in giving me the difference from the record to
now...
> > but I need to change the now to the @.to parameter.
> >
> >
> > DATEDIFF([day], view.DATE, GETDATE()) AS noofdays
> >
> > Thanks
> >
> >
>
Sunday, February 19, 2012
Date Conversion inconsistent with DB rules
I'm trying to validate data entered from users as legitimate dates by running them thru a conversion component. When conversion fails, I asssign NULLs, other wise land the date to a datetime field on the database. Dates that pass thru the conversion, however fail on insert into the DB.
It appears that the rules in the conversion component are different than that of the DB?
for instance if a user forgot the last digit on a year, i.e. "10/22/197" the convert creates a field for any of the various date datatypes as 10/22/0197, which fails on imsert into the DB, becasue it won't allow years prior to 1753.
Dates are very piccy, it is best to validate and make sure the date is correct in your package, in addition some rdms support dates before 1753 which is why SSIS supports them, SQL doesn't.