Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » DBISAM Technical Support » Support Forums » DBISAM SQL » View Thread |
Messages 1 to 2 of 2 total |
Sort Order Problem with DBISAM and ReportBuilder |
Sat, May 1 2010 7:21 PM | Permanent Link |
Scott Rowat | Hi Tim,
I'm still struggling to get ReportBuilder working with DBISAM perfectly in terms of sort order comparison. It works 90% of the time but there are some cases that still cause a problem. You mentioned in the previous thread regarding this discussion that DBISAM uses the *Windows API* CompareStringA call on any non-ANSI Standard locales. All my DBISAM tables have the Locale set to ANSI Standard. When the Locale is set to ANSI Standard what comparison method (Windows API or other) does DBISAM use in determning the Sort Order? If I can know exactly how DBISAM does the comparison then I will modify the ReportBuilder code to do the comparison in the same manner. Thanks, Scott From previous thread >>>>> No, DBISAM uses the *Windows API* CompareStringA call on any non-ANSI Standard locales, so you are gettting an ANSI comparison based upon the Windows 1252 (ANSI) character set. The difference is due to the SORT_STRINGSORT flag being used, which affects how punctuation characters such as '-' are sorted. >>>>> |
Mon, May 3 2010 1:54 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Scott,
<< You mentioned in the previous thread regarding this discussion that DBISAM uses the *Windows API* CompareStringA call on any non-ANSI Standard locales. All my DBISAM tables have the Locale set to ANSI Standard. When the Locale is set to ANSI Standard what comparison method (Windows API or other) does DBISAM use in determning the Sort Order? >> DBISAM uses a straight-up binary (Byte() cast on ANSI character set) comparison when the locale is set to ANSI Standard. The comparison code is in the dbisamlb.pas unit: function CompareBytes(FirstBuffer: pAnsiChar; SecondBuffer: pAnsiChar; CompareLength: Word; Descending: Boolean): Integer; -- Tim Young Elevate Software www.elevatesoft.com |
This web page was last updated on Tuesday, April 30, 2024 at 03:55 PM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |