DoReadRPattern Timeout |
Post Reply |
Author | |
mhuratdo
Newbie Joined: 03 May 2009 Status: Offline Points: 3 |
Post Options
Thanks(0)
Posted: 03 May 2009 at 5:34pm |
I'm using the Activex Version of the calendar control with a custom data provider.
I can generate recurrence patterns (apparently ok) but when I try to read them I get a timeout. The problem seems to be because I'm reading the whole month and the DoRetrieveDayEvents is re-reading all the events every time. This happens because the MakeRetrieveDayEventsSQL sql string retrieves all the events before the day been read (as in the C# example) This should be ok, because I have to read the former events to be able to check if there is recurrence. I coded my program just like the C# example, but I get this timeout constantly. In the other hand it doesn't seem to be a method for finding an event in the calendar (so i don't create the same event every time). Any ideas? what should I do? change the SQL String or checking if the event exists? This is the SQL string generated for today SELECT * FROM dbo.Events WHERE (RecurrenceState = 0 OR RecurrenceState = 1) AND (YEAR(dtFrom) < 2009 OR (YEAR(dtFrom) = 2009 AND (MONTH(dtFrom) < 5 OR MONTH(dtFrom) = 5 AND DAY(dtFrom) <= 3 ))) AND (YEAR(dtTo) > 2009 OR (YEAR(dtTo) = 2009 AND (MONTH(dtTo) > 5 OR MONTH(dtTo) = 5 AND DAY(dtTo) >= 3 ))) Any ideas? |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |