Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB General » View Thread |
Messages 21 to 24 of 24 total |
migrate DBISAM4 to ElevateDB (can field types be altered) |
Sun, May 27 2012 7:52 PM | Permanent Link |
IQA | Roy,
>> Been there when we holidayed up here before moving - on the drive to it there's a spring / fountain sort of thing - a lion's head on a rock with water coming out of its mouth - I had a drink there while we watched the buzzards doing courtship dances overhead. You can't buy moments like that Roy! >> My wife has a pen pal in Ulverstone - Penguin Road Ah I nearly bought a house not far from there when I was first looking to move to Tassie, but now live over on the North East coast in St Helens. Cheers, Phil. |
Wed, Jun 20 2012 12:30 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Jan,
<< Actually, in DBISAM the currency type was BCD. >> Delphi (Borland) did everyone a big disservice by calling the Currency data type "Currency". Here's the skinny: 1) The Currency data type *in Delphi* is like a BCD in DBISAM/EDB or a DECIMAL/NUMERIC type in SQL. It's a fixed-scale type that allows up to 4 decimal places and is actually stored as a 64-bit integer in memory. 2) The TCurrencyField (ftCurrency) field is stored as a floating-point type (Double) that does *not* use a fixed-scale. It simply displays the numbers formatted/rounded to a fixed scale of 2. Therefore, the actual data may differ from what is displayed. The results are usually more precise when used in calculations, but you can run into issues like Phil has when moving them to a fixed-scale type like the BCD/DECIMAL/NUMERIC types. 3) The TBCDField (ftBCD) field is stored as a TBCD structure in DBISAM, and in EDB it's stored as a Currency type. The TBCD structure is way too big, and the Currency type works fine for most purposes (plus, is the only compatible type in Delphi/BCB). If you have any other questions, please let me know. Tim Young Elevate Software www.elevatesoft.com |
Wed, Jun 20 2012 12:32 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Phil,
<< If a value is say: -10.655 then changing its type to DECIMAL(19,2) makes it -10.65 >> Are you sure that the value is actually -10.655, and not something with a greater precision (like -10.6543222108) ? Tim Young Elevate Software www.elevatesoft.com |
Wed, Jun 20 2012 12:35 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Phil,
<< I think Jan exaplains the problem I'm seeing, originally there was no problem with the Currency (BCD) type in DBISAM, but using the Elevate Migration it appears at least to cause a few problems when it converts the Currency to floats. >> Just to clarify - the migration isn't changing anything in the source data. The Currency fields are already floating-point values. The only thing the migration does is change the sub-type of the field so that it's a plain TFloatField in Delphi, and not a TCurrencyField. This was done to be more in-line with the SQL standard, which really doesn't have any concept of a floating-point "currency" type, or at least doesn't make the distinction. If you have any other questions, please let me know. Tim Young Elevate Software www.elevatesoft.com |
« Previous Page | Page 3 of 3 | |
Jump to Page: 1 2 3 |
This web page was last updated on Tuesday, September 17, 2024 at 04:19 AM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |