Skip Menu |

This queue is for tickets about the DBD-XBase CPAN distribution.

Report information
The Basics
Id: 113973
Status: open
Priority: 0/
Queue: DBD-XBase

People
Owner: Nobody in particular
Requestors: aharbison [...] gmx.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Table field names limited to 10 characters?
Date: Mon, 25 Apr 2016 17:31:07 +0200
To: bug-DBD-XBase [...] rt.cpan.org
From: aharbison [...] gmx.com
What I expected: A field named "DESCRIPTION" from a DBF file.
What I got: A field named "DESCRIPTIO".
 
Steps to recreate:
0. Find a file with a field name longer than 10 characters.
1. dbfdump --info --SQL myfile.DBF
2. If there is a field name longer than 10 characters (e.g. "DESCRIPTION") it will truncate (e.g. "DESCRIPTIO").
 
Subject: Re: [rt.cpan.org #113973] Table field names limited to 10 characters?
Date: Tue, 26 Apr 2016 08:34:26 +0000
To: "aharbison [...] gmx.com via RT" <bug-DBD-XBase [...] rt.cpan.org>
From: Jan Pazdziora <jpx [...] adelton.com>
On Mon, Apr 25, 2016 at 11:31:20AM -0400, aharbison@gmx.com via RT wrote: Show quoted text
> > What I expected: A field named "DESCRIPTION" from a DBF file.What I got: A > field named "DESCRIPTIO". Steps to recreate:0. Find a file with a field name > longer than 10 characters.1. dbfdump --info --SQL myfile.DBF2. If there is a > field name longer than 10 characters (e.g. "DESCRIPTION") it will truncate > (e.g. "DESCRIPTIO").
What DBD-XBase version is this? Could you attach example myfile.DBF2? Things seem to work as expected on my machine with 1.05: [root@30653a9ce2b6 /]# perl -MXBase -e 'my $newtable = XBase->create(name => "myfile.DBF2", field_names => [ "DESCRIPTION" ], field_types => [ "C" ], field_lengths => [ 40 ], field_decimals => [ 0 ]) or die $XBase::errstr;' [root@30653a9ce2b6 /]# dbfdump.pl --info myfile.DBF2 Filename: myfile.DBF2.dbf Version: 0x03 (ver. 3) Num of records: 0 Header length: 65 Record length: 41 Last change: 2016/4/26 Num fields: 1 Field info: Num Name Type Len Decimal 1. DESCRIPTION C 40 0 [root@30653a9ce2b6 /]# dbfdump.pl --info --SQL myfile.DBF2 create table myfile.DBF2 ( DESCRIPTION varchar(40) ) -- Jan Pazdziora