Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » DBISAM Technical Support » Support Forums » DBISAM General » View Thread |
Messages 1 to 6 of 6 total |
Spaces truncated from Blob on version 4 upgrade |
Mon, May 7 2007 6:10 PM | Permanent Link |
David | Hi,
I upgraded a version 3 table containing a BLOB field to a version 4 table. The original BLOB field contained 322 chars (the block size was also 322). The last 30 chars were spaces with ASCII CR/LF at the end. After the upgrade, the BLOB field only contained 304 chars, although the block size was increased to 328. I understand that the block size was increased to a value this is divisible by 8. That part is fine, but the real issue is that the data is truncated. Unfortunately, I am working with fixed length data records in the BLOB field, so this throws off my spacing. By the way, it didn't truncate all the spaces, there are still 14 at the end. Is there a way to upgrade BLOB fields that contain data with spaces at the end, and not truncate the data? The conversion was done using DBsys version 4. Not using Delphi or anything. Thanks, David |
Tue, May 8 2007 7:30 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | David,
<< I upgraded a version 3 table containing a BLOB field to a version 4 table. The original BLOB field contained 322 chars (the block size was also 322). The last 30 chars were spaces with ASCII CR/LF at the end. After the upgrade, the BLOB field only contained 304 chars, although the block size was increased to 328. I understand that the block size was increased to a value this is divisible by 8. That part is fine, but the real issue is that the data is truncated. Unfortunately, I am working with fixed length data records in the BLOB field, so this throws off my spacing. By the way, it didn't truncate all the spaces, there are still 14 at the end. Is there a way to upgrade BLOB fields that contain data with spaces at the end, and not truncate the data? >> The most likely situation is that the BLOBs contained embedded NULLs. Can you send me a 3.x table prior to the upgrade so that I can try it here ? Thanks, -- Tim Young Elevate Software www.elevatesoft.com |
Wed, May 9 2007 10:36 AM | Permanent Link |
David Wilson | Hi Tim,
Here is the file attachment. I don't believe there are any Nulls in the Text within the BLOB. The attachment contains a version 3 table that illustrates a problem. The table has one record with one Blob field. The Blob field is 322 bytes which can be seen in DBsys version 3. The last 21 chars of the text in the Blob are spaces. Using DBsys version 4, upgrade this table to version 4. You will get several messages about block size. The block size is increased. However, the data within the Blob field is now 304 characters (18 chars shorter than before). It looks like most (but not all) of the trailing spaces got truncated. Thanks, David "Tim Young [Elevate Software]" <timyoung@elevatesoft.com> wrote: David, << I upgraded a version 3 table containing a BLOB field to a version 4 table. The original BLOB field contained 322 chars (the block size was also 322). The last 30 chars were spaces with ASCII CR/LF at the end. After the upgrade, the BLOB field only contained 304 chars, although the block size was increased to 328. I understand that the block size was increased to a value this is divisible by 8. That part is fine, but the real issue is that the data is truncated. Unfortunately, I am working with fixed length data records in the BLOB field, so this throws off my spacing. By the way, it didn't truncate all the spaces, there are still 14 at the end. Is there a way to upgrade BLOB fields that contain data with spaces at the end, and not truncate the data? >> The most likely situation is that the BLOBs contained embedded NULLs. Can you send me a 3.x table prior to the upgrade so that I can try it here ? Thanks, -- Tim Young Elevate Software www.elevatesoft.com Attachments: BlobTest.zip |
Wed, May 9 2007 5:29 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | David,
<< Here is the file attachment. I don't believe there are any Nulls in the Text within the BLOB. The attachment contains a version 3 table that illustrates a problem. The table has one record with one Blob field. The Blob field is 322 bytes which can be seen in DBsys version 3. The last 21 chars of the text in the Blob are spaces. Using DBsys version 4, upgrade this table to version 4. You will get several messages about block size. Th block size is increased. However, the data within the Blob field is now 304 characters (18 chars shorter than before). It looks like most (but not all) of the trailing spaces got truncated. >> Okay, the issue is that the upgrade expects the BLOB block size to be a multiple of 8, and doesn't handle it well when it isn't. The workaround until a fix can be made is to restructure the table in DBISAM 3 and change the block size to a multiple of 8. In general, you shouldn't use block sizes that aren't an even multiple of 64 or higher. There's really no benefit to doing otherwise, anyways. -- Tim Young Elevate Software www.elevatesoft.com |
Wed, May 9 2007 6:12 PM | Permanent Link |
David Wilson | << Okay, the issue is that the upgrade expects the BLOB block size to be a multiple of 8, and doesn't handle it well when it isn't. The workaround until a fix can be made is to restructure the table in DBISAM 3 and change the block size to a multiple of 8. In general, you shouldn't use block sizes that aren't an even multiple of 64 or higher. There's really no benefit to doing otherwise, anyways. -- Tim Young Elevate Software www.elevatesoft.com >> OK, thanks Tim. We are planning to write a small version 3 utility that will fix the block size on our customer databases before running our version 4 program and doing the upgrade. That should take care of it. Thanks for looking into this issue. David Wilson VantageMed |
Thu, May 10 2007 1:22 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | David,
<< OK, thanks Tim. We are planning to write a small version 3 utility that will fix the block size on our customer databases before running our version 4 program and doing the upgrade. That should take care of it. Thanks for looking into this issue. >> Thanks for being understanding about the situation and using the workaround. -- Tim Young Elevate Software www.elevatesoft.com |
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 |