We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Filtering on DateTime Column does not work

Thread ID:

Created:

Updated:

Platform:

Replies:

54269 Jan 4,2007 04:24 PM Jun 21,2007 07:55 AM ASP.NET Web Forms (Classic) 13
loading
Tags: GridGroupingControl
Jahmai
Asked On January 4, 2007 04:24 PM

I have a grid attached to a sqldatasource which is reading from a table in which one of the columns is a datetime column.It is a sql server table. The grid has filter set for all columns.
The grid's filter mechanism works on all the columns except the column which is type datetime. Even after using the Convert statement in the select query of the sqldatasource to convert the column to a Varchar type, the filter in the grid still doesnt work for this column.

Can anyone help me out with this issue?

Administrator [Syncfusion]
Replied On January 4, 2007 09:28 PM

Hi Jahmai,

We couldn't able to reproduce the issue as you mentioned. So we have created one sample which will bind the Grid to SqlDatasource/AccessDatasource with FilterOption. Unlike you mentioned, Filter option is working fine with DateTime column(i.e. BirthDate in our sample).However we have attached our sample too. So Please download our sample and do let us know if your are able to reproduce the issue in our sample.

Forum_54269.zip

Thanks for using Syncfusion Products.

Regards,
Gokulkumar.B

Jahmai
Replied On January 5, 2007 10:12 AM

Hello Gokulkumar.

I have attached a project demonstration which shows my problem.

The project consists of just a default.aspx page and a sql server express database with 1 table for demo purposes.

The steps I took to bind and provide filtering capabilities on the grid were as follows:

1. Drag a Grid Grouping control onto the default.aspx page

2. From the context menu of the control select New DataSource

3. Attach to my sql server table and select all columns from the Contacts table

4. Set AllowFilter=true for all columns

5. Set ShowFilterBar=true in TableDescriptor.TopLevelOptions

6.Do a databind of the grid in the Page_Init function

7.Run the application

Please tell me what I am doing wrong.


Filtering works with all my access tables but not my sqlserver tables.

Thanks
Jahmai



Jahmai
Replied On January 5, 2007 10:23 AM

Ensuring there was an attachment.

FilterTest.zip

Jahmai
Replied On January 5, 2007 11:13 AM

I appeared to have found the cause of the problem.
If the datetime field has a time attached e.g 1/2/2006 9:45:00 AM, then the filter for the column does not work.

Is there anyway around this?

Jahmai
Replied On January 5, 2007 11:40 AM

It appears that any data containing the ":" character cannot be filtered.

Gokul B [Syncfusion]
Replied On January 5, 2007 07:46 PM

Hi Jahmai,

Thanks for your attachment.We could see this issue in your sample. So we need to look bit more regarding this issue and let you know later within "Tuesday". However, Could you please update us if you are able to reproduce the issue in our perviously attached sample too in this post.

Thanks for using Syncfusion product.

Regards,
Gokulkumar.B


Jahmai
Replied On January 8, 2007 11:04 AM

In order to reproduce the error in your sample, just put a ":" in any field of the data being displayed.

For instance, in the northwind database employees table, changing the first employee's name from "Nancy" to "Nancy:", the data cannot be filtered for the name "Nancy:".

In other words, as long as the data contains a ":" character, you cannot filter the data for that particular piece of information.

Gokul B [Syncfusion]
Replied On January 9, 2007 07:33 PM

Hi Jahmai,

Thanks for your update. It help us to reproduce the issue.As you mentioned filter is not working when the data contains ":" character. This might be a bug.However we will check bit more on this for some possible workaround and let know later tommorrow.

Thanks for using syncfusion products.

Regards,
Gokulkumar.B

Gokul B [Syncfusion]
Replied On January 10, 2007 06:02 PM

Hi Jahmai,

We noticed that Record Filter is not working as long as when the data contains ":" characters(Ex:DateTime Field).But It is working fine when Record filter is hard coded like shown below.

//Filter the Record between the specified range.
this.GridGroupingControl1.TableDescriptor.RecordFilters.Add("[Birthdate] Between {12/11/2006 11:02 AM,12/11/2006 11:02 AM}");

So we confirm this as a bug and Filed a bug report in our Internal Defect Tracking System. We have requested our developer to provide more information regarding the timeframe to fix this issue. Hope we can provide you with more information within a 12 days.

Sorry for the incovenience caused.

Let us know if you need any other assistance.

Thanks for using Syncfusion products.

Regards,
Gokulkumar.B

Gokul B [Syncfusion]
Replied On January 23, 2007 06:47 PM

Hi Jahmai,

I regret for the delay in getting back to you.

I am afraid I have not heard back from the development team yet but will follow up again and update you within 7 days.Sorry for the delay.

Thanks for using Syncfusion product.

Regards,
Gokulkumar.B

Gokul B [Syncfusion]
Replied On January 31, 2007 07:37 PM

Hi Jahmai,

I very much appreciate your patience on this issue. The development is on going for this issue and the fix will be available on March 5th.

Thanks for using Syncfusion products.

Regards,
Gokulkumar.B

Suresh Sekarean [Syncfusion]
Replied On May 23, 2007 05:20 AM

Hi Jahmai,

Sorry for the delay in response.

A defect report has been logged for this issue. You can keep track of the progress of the issue from the below link

http://www.syncfusion.com/support/issues/grid/Default.aspx?ToDo=view&questId=3354

We have forwarded this issue to our developers and will update you with the fix for the same on or before June, 25th, 2007.

Please let us know if you have any queries.

Regards,
Sureshsekaran.

Suresh Sekarean [Syncfusion]
Replied On June 21, 2007 07:55 AM

Hi Jahmai,

Could you please open an incident in the direct trac with the forum id as the subject line, so that we can send you the necessary information?

http://www.syncfusion.com/Support/DirectTrac/logon.aspx

Regards,
Sureshsekaran.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;