Showing posts with label provide. Show all posts
Showing posts with label provide. Show all posts

Sunday, March 25, 2012

Date Picker RS2005SP2 useless

I read a lot of posts in this forum, but none of them provide a solution.

Probably it is related to SP2 as many report, I have SP2 as well...

A funny situation:
I have a report parameter @.date, datatype datetime, so I can use the datepicker control.

But, even when not using this @.date parameter in my dataset, I still get the error:

  • The value provided for the report parameter 'date' is not valid for its type. (rsReportParameterTypeMismatch)

    Of course it has to do with regional settings and languages etc... But at my international client's site, workstations are in any regional setting and servers are in en-US, nothing I can do about that.

    Come'on Microsoft, don't tell us this datePicker is only for the US market?

    Thank You MS!

    Apparently it is now solved in the Cumulative update package 2 for SQL Server 2005 Service Pack 2

    See http://support.microsoft.com/kb/936305, bug n_ 50001284

  • Monday, March 19, 2012

    date function/tool to determine future business days/ holidays

    Hi,

    Does SQL server 2005 provide a function to determine future BUSINESS day ? What about holidays ? I sthere a way to feed a holiday file into a table and have SQL Server determin if the future date falls on a business day ?

    As far as you do not mean the fixed calculated public holidays (like Easter, which can be calculated with a Gauss formula) you will have to implement that on your own having a custom table with the special dates.

    Jens K. Suessmeyer


    http://www.sqlserver2005.de

    |||

    Thanks but I am still unclear. If I'd like to know if today's date + 100 days from now would fall on a business day . Is there a ready-to-use MS SQL function that I can use or should I write it on my own ?

    |||

    Well, define business day. There is not a common understanding of business day (even in one countrym like here in Germany :-) )

    Jens K. Suessmeyer

    http://www.sqlserver2005.de

    |||

    Hello. I think the following library of functions can help with the issue of finding Business Days:

    http://www.SQLsharp.com/

    I just added some date functions and one of them is finding the number of business days within a given date range. And because not everyone can agree on what is a business day, the function allows the user to select which days are to be filtered out as non-business days. I have not done a function to find if a particular day in the future is a business day, but that can be added quite easily. This function can determine holidays on any given year so you don't need the typical holiday table that most people suggest using.

    date function/tool to determine future business days/ holidays

    Hi,

    Does SQL server 2005 provide a function to determine future BUSINESS day ? What about holidays ? I sthere a way to feed a holiday file into a table and have SQL Server determin if the future date falls on a business day ?

    As far as you do not mean the fixed calculated public holidays (like Easter, which can be calculated with a Gauss formula) you will have to implement that on your own having a custom table with the special dates.

    Jens K. Suessmeyer


    http://www.sqlserver2005.de

    |||

    Thanks but I am still unclear. If I'd like to know if today's date + 100 days from now would fall on a business day . Is there a ready-to-use MS SQL function that I can use or should I write it on my own ?

    |||

    Well, define business day. There is not a common understanding of business day (even in one countrym like here in Germany :-) )

    Jens K. Suessmeyer

    http://www.sqlserver2005.de

    |||

    Hello. I think the following library of functions can help with the issue of finding Business Days:

    http://www.SQLsharp.com/

    I just added some date functions and one of them is finding the number of business days within a given date range. And because not everyone can agree on what is a business day, the function allows the user to select which days are to be filtered out as non-business days. I have not done a function to find if a particular day in the future is a business day, but that can be added quite easily. This function can determine holidays on any given year so you don't need the typical holiday table that most people suggest using.

    Tuesday, February 14, 2012

    Date based filter in merge replication

    Hopefully, someone can provide some advice regarding filtering data by dates.
    We have data that we want to expire from the sqlce database because it has reached a certain age. Filters have been applied to only replicate data wihtin the date boundaries we require.
    What we have found through testing is that when we increment server and device dates to a date where data should expire, it is not removed from the database on the device. During this testing we made sure our snapshot was updated before applying more chan
    ges through our application, allowing us to see data travelling to and from the device. But, alas, the outdated data survived.
    So, I suppose it makes sense that if a record is not updated, it will not be affected by replication - or is there some way around this?
    Other than archiving data on the server side which has its own set of implications (ms_MergeTombstone growing excessively, effects on historical reports), is there some other technique we can use to limit the volume of data on the device?
    Thanks
    Steve
    Steve,
    As you mentioned already, records that are not updated are not affected by
    replication. Creating a new snapshot won't help on this side either. So the
    technique I term as 'Induced Updates' could be applied in your case. This
    simply means making an update in the table for all rows you want replication
    to re-assess without changing the data. This sample script will demo:
    update YourTable
    set column_name = column_name
    where date_column = some_date_criteria
    You can also create a job to do this periodically, where some_date_criteria
    can be dependent on the getdate() function.
    Hope the above helps.
    Raj Moloye.
    |||Steve,
    As you mentioned already, records that are not updated are not affected by
    replication. Creating a new snapshot won't help on this side either. So the
    technique I term as 'Induced Updates' could be applied in your case. This
    simply means making an update in the table for all rows you want replication
    to re-assess without changing the data. This sample script will demo:
    update YourTable
    set column_name = column_name
    where date_column = some_date_criteria
    You can also create a job to do this periodically, where some_date_criteria
    can be dependent on the getdate() function.
    Hope the above helps.
    Raj Moloye.
    |||Thanks Raj,
    I have to say I was starting to think along those lines as I wrote the original post.
    When I update these rows that are out of date range, does replication cause these updated rows to be removed from the device?
    I think some testing might be in order here just to confirm what you are saying.
    Thanks again.
    SteveM
    "Raj Moloye" wrote:

    > Steve,
    > As you mentioned already, records that are not updated are not affected by
    > replication. Creating a new snapshot won't help on this side either. So the
    > technique I term as 'Induced Updates' could be applied in your case. This
    > simply means making an update in the table for all rows you want replication
    > to re-assess without changing the data. This sample script will demo:
    > update YourTable
    > set column_name = column_name
    > where date_column = some_date_criteria
    > You can also create a job to do this periodically, where some_date_criteria
    > can be dependent on the getdate() function.
    > Hope the above helps.
    > Raj Moloye.
    >
    >
    |||Thanks Raj,
    I have to say I was starting to think along those lines as I wrote the original post.
    When I update these rows that are out of date range, does replication cause these updated rows to be removed from the device?
    I think some testing might be in order here just to confirm what you are saying.
    Thanks again.
    SteveM
    "Raj Moloye" wrote:

    > Steve,
    > As you mentioned already, records that are not updated are not affected by
    > replication. Creating a new snapshot won't help on this side either. So the
    > technique I term as 'Induced Updates' could be applied in your case. This
    > simply means making an update in the table for all rows you want replication
    > to re-assess without changing the data. This sample script will demo:
    > update YourTable
    > set column_name = column_name
    > where date_column = some_date_criteria
    > You can also create a job to do this periodically, where some_date_criteria
    > can be dependent on the getdate() function.
    > Hope the above helps.
    > Raj Moloye.
    >
    >