Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Filtering problem...
Message
From
01/05/2001 03:10:42
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
01/05/2001 02:04:48
N. Lea
Nic Cross Enterprises
Valencia, California, United States
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00501870
Message ID:
00501874
Views:
18
>Our last programmer created this free table, and the date information that was inputted is located in a character field. Therefore when try to set a filter it filters the data on the first couple of characters. I have tried LEFT, RIGHT, SUBSTR, but have no luck. Can anyone help me in trying to figure a way to filter this table by date. This table has over 20,000 records. Thanks!

Lea,
But you don't give a clue how the date format is. You could do a conversion to date format. ie: say current format is MMDDYYYY. :
alter table myTable add column Newdate d
replace all NewDate with ;
date(val(substr(Old,5,4)),val(substr(Old,1,2)),val(substr(Old,3,2)))
PS:Some formats are compatible with directly setting new field type to date.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform