f



DBFCDX, Data Width Error 1026

Key expression:
upper(substr(alltrim(FILE_PATH) + alltrim(FILE_NAME),4,99))

I started with a DBF that was created under DBFNTX, but had no indexes.  Not sure if that bit of information makes any difference.

What do I try next?  Really do not want to keep casing (Windoze ignores), and fields FILE_NAME and FILE_PATH are both 80 characters long.

David A. Smith
0
dlzc
1/15/2015 3:42:41 AM
comp.lang.xharbour 5470 articles. 0 followers. Post Follow

18 Replies
298 Views

Similar Articles

[PageSpeed] 39


Il 15/01/2015 04:42, dlzc ha scritto:

> Key expression: upper(substr(alltrim(FILE_PATH) +
> alltrim(FILE_NAME),4,99))
>
> I started with a DBF that was created under DBFNTX, but had no
> indexes.  Not sure if that bit of information makes any difference.
>
> What do I try next?  Really do not want to keep casing (Windoze
> ignores), and fields FILE_NAME and FILE_PATH are both 80 characters
> long.

Any chance to reproduce the problem here?

EMG

--
EMAG Software Homepage: http://www.emagsoftware.it
The EMG Music page: http://www.emagsoftware.it/emgmusic
The EMG's ZX-Spectrum Page: http://www.emagsoftware.it/spectrum
The Best of Spectrum Games: http://www.emagsoftware.it/tbosg
0
Enrico
1/15/2015 9:19:23 AM
> Key expression:
> upper(substr(alltrim(FILE_PATH) + alltrim(FILE_NAME),4,99))
> What do I try next?

padr(upper(substr(alltrim(FILE_PATH) + alltrim(FILE_NAME),4,99)),99)

Saulius 


0
Saulius
1/15/2015 9:32:07 AM
On Thursday, January 15, 2015 at 2:32:13 AM UTC-7, Saulius wrote:
> > Key expression:
> > upper(substr(alltrim(FILE_PATH) + alltrim(FILE_NAME),4,99))
> > What do I try next?
> 
> padr(upper(substr(alltrim(FILE_PATH) + alltrim(FILE_NAME),4,99)),99)

padr(upper(substr(rtrim(FILE_PATH) + FILE_NAME,4,99)),99)

Works perfectly!  Thank you.  Never have figured out how "deep" the index function goes to determine max key length, and apparently "one step" is about it.

David A. Smith
0
dlzc
1/15/2015 10:31:45 PM
On Thursday, January 15, 2015 at 2:19:48 AM UTC-7, Enrico Maria Giordano wrote:
> Il 15/01/2015 04:42, dlzc ha scritto:
> 
> > Key expression:
> > upper(substr(alltrim(FILE_PATH) + ;
> >    alltrim(FILE_NAME),4,99))
....
> Any chance to reproduce the problem here?

The key above did not work on my older xHarbour.  Bracketing with padr() (Saulus' suggestion), fixed it.  Weird.

David A. Smith
0
dlzc
1/15/2015 10:33:50 PM

Il 15/01/2015 23:33, dlzc ha scritto:

> The key above did not work on my older xHarbour.  Bracketing with
> padr() (Saulus' suggestion), fixed it.  Weird.

Yes, weird. I don't understand why the key has to be of different 
length, maybe something strange in the content?

EMG

--
EMAG Software Homepage: http://www.emagsoftware.it
The EMG Music page: http://www.emagsoftware.it/emgmusic
The EMG's ZX-Spectrum Page: http://www.emagsoftware.it/spectrum
The Best of Spectrum Games: http://www.emagsoftware.it/tbosg
0
Enrico
1/15/2015 11:22:55 PM
Dear Enrico Maria Giordano:

On Thursday, January 15, 2015 at 4:23:20 PM UTC-7, Enrico Maria Giordano wrote:
> Il 15/01/2015 23:33, dlzc ha scritto:
> 
> > The key above did not work on my older xHarbour.
> > Bracketing with padr() (Saulus' suggestion), fixed
> > it.  Weird.
> 
> Yes, weird. I don't understand why the key has to be
> of different length, maybe something strange in the
> content?

I think the point was, the key *cannot* be of different length, even though I initially truncated to 99 characters, I never assured that it had at minimum 99 characters every time.

The index generator probably threw blank( FILE_PATH ) and blank( FILE_NAME ) into the key expression, and came up with a zero length key with my original formula.

My usual ID-10-t error (idiot, in case you'd never heard that expression, only makes sense in English of course).

David A. Smith
0
dlzc
1/16/2015 1:47:28 AM

Il 16/01/2015 02:47, dlzc ha scritto:

>> Yes, weird. I don't understand why the key has to be of different
>> length, maybe something strange in the content?
>
> I think the point was, the key *cannot* be of different length, even
> though I initially truncated to 99 characters, I never assured that
> it had at minimum 99 characters every time.

Sorry, I missed AllTrim().

EMG

--
EMAG Software Homepage: http://www.emagsoftware.it
The EMG Music page: http://www.emagsoftware.it/emgmusic
The EMG's ZX-Spectrum Page: http://www.emagsoftware.it/spectrum
The Best of Spectrum Games: http://www.emagsoftware.it/tbosg
0
Enrico
1/16/2015 11:54:50 AM
Oops!

On Thursday, January 15, 2015 at 3:31:47 PM UTC-7, dlzc wrote:
....
> padr(upper(substr(rtrim(FILE_PATH) + FILE_NAME,4,99)),99)
> 
> Works perfectly!  Thank you.  Never have figured out
> how "deep" the index function goes to determine max
> key length, and apparently "one step" is about it.

A little hasty, actually.
Error DBFCDX/1012  Corruption detected: <cFullpath.cdx> Arguments: () 
....
Called from : MAIN(82) in Module: movielist.prg

Line 82 is:
use "<cFullpath>.dbf"

It indexes fine.  But the next time the program is run, it generates the above error.

Not a shared DBF, no file locking, in a mapped drive to another Windoze computer.  Commits do not help.

Any bright ideas now?

ORDCREATE( "<cFullpath>.cdx", ;
           "ONE", ;
           padr(upper(substr(rtrim(FILE_PATH) + FILE_NAME,4,99)),99),;
           {|| padr(upper(substr(rtrim(FILE_PATH) + FILE_NAME,4,99)),99) })

Operating system...: Windows  Windows Vista Professional 6.01.7601 Service Pack 1
xHarbour version...: xHarbour build 1.2.1 Intl. (SimpLex) (Rev. 6633)
xHarbour built on..: Nov  5 2009 11:55:35
C/C++ compiler.....: XCC ISO C Compiler 2.70

David A. Smith
0
dlzc
1/16/2015 11:21:23 PM
Thinking out loud: a virus has inserted a NULL character in the path or fil=
e name, or somewhere in the .dbf file you have a completely empty record ap=
pended by a different software, and that one contains a NULL character in o=
ne of the fields used for indexing...
0
Ella
1/17/2015 1:50:17 AM

Il 17/01/2015 00:21, dlzc ha scritto:

> It indexes fine.  But the next time the program is run, it generates
> the above error.

The fastest and easiest way to locate the problem is to get the DBF, the 
index and a minimal sample. Can you send me those?

EMG

--
EMAG Software Homepage: http://www.emagsoftware.it
The EMG Music page: http://www.emagsoftware.it/emgmusic
The EMG's ZX-Spectrum Page: http://www.emagsoftware.it/spectrum
The Best of Spectrum Games: http://www.emagsoftware.it/tbosg
0
Enrico
1/17/2015 7:43:59 AM
Dear Ella Stern:

On Friday, January 16, 2015 at 6:50:18 PM UTC-7, Ella Stern wrote:
> Thinking out loud: a virus has inserted a NULL
> character in the path or file name,

I can run this from other machines, but have not yet.  The index created works perfectly fine, until the program ends.  On next run, it is contaminated, even if that is seconds later.

> or somewhere in the .dbf file you have a
> completely empty record appended by a different
> software, and that one contains a NULL character
> in one of the fields used for indexing...

I made sure there were no records with empty( FILE_NAME ), and even COUNTed the number of CHR( 0 ) $ DBRecordInfo( DBRI_RAWDATA ), no results.  Thanks though.

For now, I will just delete the index file before using the database.

David A. Smith
0
dlzc
1/17/2015 3:01:48 PM
On Saturday, January 17, 2015 at 12:44:26 AM UTC-7, Enrico Maria Giordano w=
rote:
> Il 17/01/2015 00:21, dlzc ha scritto:
>=20
> > It indexes fine.  But the next time the program is run, it generates
> > the above error.
>=20
> The fastest and easiest way to locate the problem is to get the DBF, the=
=20
> index and a minimal sample. Can you send me those?

Minimal sample:
<BEGIN>

// FErase( "movielist.cdx" )
RddSetDefault( "DBFCDX" )
set autopen on
use "movielist.dbf" exclusive  && <----- fails here
delete all for empty( FILE_NAME )
pack
set order to 1
if empty( ordkey() )
   ORDCREATE( "W:\public\D\movielist.cdx", ;
               "ONE", ;
               padr(upper(substr(rtrim(FILE_PATH) + FILE_NAME,4,99)),99),;
               {|| padr(upper(substr(rtrim(FILE_PATH) + FILE_NAME,4,99)),99=
) })
   commit
   end if
set order to 1

<END>

And I expect that it is a bug in my old version of xHarbour.  I can send th=
e other two files, as soon as I figure out how to send it to you.  I'll mak=
e a zip, and change the extension to .txt, but don't have your email addres=
s (remember to mux it up so it cannot be harvested).

David A. Smith
0
dlzc
1/17/2015 3:11:16 PM

Il 17/01/2015 16:11, dlzc ha scritto:

>> The fastest and easiest way to locate the problem is to get the
>> DBF, the index and a minimal sample. Can you send me those?
>
> Minimal sample:

Thank you.

> And I expect that it is a bug in my old version of xHarbour.  I can
> send the other two files, as soon as I figure out how to send it to
> you.  I'll make a zip, and change the extension to .txt, but don't
> have your email address (remember to mux it up so it cannot be
> harvested).

You can send the ZIP without problem to

e.m.giordano@emagsoftware.it

Harvesting is no problem. My email is already everywhere on Internet. :-)

EMG

--
EMAG Software Homepage: http://www.emagsoftware.it
The EMG Music page: http://www.emagsoftware.it/emgmusic
The EMG's ZX-Spectrum Page: http://www.emagsoftware.it/spectrum
The Best of Spectrum Games: http://www.emagsoftware.it/tbosg
0
Enrico
1/17/2015 3:20:47 PM
Dear Enrico Maria Giordano:

On Saturday, January 17, 2015 at 8:21:14 AM UTC-7, Enrico Maria Giordano wr=
ote:
> Il 17/01/2015 16:11, dlzc ha scritto:
>=20
> >> The fastest and easiest way to locate the problem
> >> is to get the DBF, the index and a minimal sample.
> >> Can you send me those?
>=20
....
>=20
> You can send the ZIP without problem to

Sent.

I would not be surprised if it were the entry for "Naked Gun 2=BD", whateve=
r the 1/2 symbol mutated into, as I have also edited this dbf's contents wi=
th Libre Office dabase app, on a Linux machine (converted netbook, while wa=
tching a movie...).

David A. Smith
0
dlzc
1/17/2015 6:25:09 PM

Il 17/01/2015 19:25, dlzc ha scritto:

>> You can send the ZIP without problem to
>
> Sent.

Thank you. I found your error. You missed that the third parameter of 
OrdCreate() must be a string:

    ORDCREATE( "movielist.cdx", ;
                "ONE", ;
                "padr(upper(substr(rtrim(FIELD -> FILE_PATH) + FIELD -> 
FILE_NAME,4,99)),99)",;
                {|| padr(upper(substr(rtrim(FIELD -> FILE_PATH) + FIELD 
-> FILE_NAME,4,99)),99) })

Now it's woking fine. :-)

EMG

--
EMAG Software Homepage: http://www.emagsoftware.it
The EMG Music page: http://www.emagsoftware.it/emgmusic
The EMG's ZX-Spectrum Page: http://www.emagsoftware.it/spectrum
The Best of Spectrum Games: http://www.emagsoftware.it/tbosg
0
Enrico
1/17/2015 7:42:50 PM
Dear Enrico Maria Giordano:

On Saturday, January 17, 2015 at 12:43:19 PM UTC-7, Enrico Maria Giordano wrote:
> Il 17/01/2015 19:25, dlzc ha scritto:
> 
> >> You can send the ZIP without problem to
> >
> > Sent.
> 
> Thank you. I found your error. You missed that the
> third parameter of OrdCreate() must be a string:
> 
>     ORDCREATE( "movielist.cdx", ;
>                 "ONE", ;
>                 "padr(upper(substr(rtrim(FIELD -> FILE_PATH) + FIELD -> 
> FILE_NAME,4,99)),99)",;
>                 {|| padr(upper(substr(rtrim(FIELD -> FILE_PATH) + FIELD 
> -> FILE_NAME,4,99)),99) })
> 
> Now it's woking fine. :-)

Yet another ID-10-t error!

This explains why I had to supply the code block, because it could not decipher a random (or empty) path+file name, as an index key.

Thanks!

David A. Smith
0
dlzc
1/17/2015 8:43:01 PM
On Thursday, January 15, 2015 at 9:12:43 AM UTC+5:30, dlzc wrote:
> Key expression:
> upper(substr(alltrim(FILE_PATH) + alltrim(FILE_NAME),4,99))
> 
> I started with a DBF that was created under DBFNTX, but had no indexes.  Not sure if that bit of information makes any difference.
> 
> What do I try next?  Really do not want to keep casing (Windoze ignores), and fields FILE_NAME and FILE_PATH are both 80 characters long.
> 
> David A. Smith

You are REPLACING invalid data type

if such is the case then you can initialize in the beginning 

FILE_NAME := FILE_PATH := ""



0
cyril19sara
2/6/2015 2:03:37 PM
On Friday, February 6, 2015 at 7:03:38 AM UTC-7, cyril...@gmail.com wrote:
> On Thursday, January 15, 2015 at 9:12:43 AM UTC+5:30, dlzc wrote:
> > Key expression:
> > upper(substr(alltrim(FILE_PATH) + alltrim(FILE_NAME),4,99))
> > 
> > I started with a DBF that was created under DBFNTX, but had no indexes.  Not sure if that bit of information makes any difference.
> > 
> > What do I try next?  Really do not want to keep casing (Windoze ignores), and fields FILE_NAME and FILE_PATH are both 80 characters long.
> > 
> > David A. Smith
> 
> You are REPLACING invalid data type
> 
> if such is the case then you can initialize in the beginning 
> 
> FILE_NAME := FILE_PATH := ""

No, I had a bad key.  I wanted (essentially) "FILE_PATH + FILE_NAME", and I supplied it FILE_PATH (current value) + FILE_NAME (current value).  The only reason it worked the first time, is that I supplied a correct block when the index was created.

David A. Smith
0
dlzc
2/6/2015 2:39:01 PM
Reply:

Similar Artilces:

Problem with DBFCDX/1021 Data width error
Hello, The application I wrote, which was working ok for more than 2 years suddenly started to generate the error mentioned in the subject line. I made some researches on the net, but all I got were few documents in spanish and russian only - the languages which I don't speak... Actually the problem arised 2 weeks ago (I knew it from errors log generated by my own rewritten error handling procedures), but the user informed me about it only 2 days ago. Till now she simply has been restarting the program not caring much about consequences... :-( For now I am expecting certain level of data...

migrating from xharbour dbfcdx to xharbour + ADS DD dbfcdx
Which scenario can be implemented, while migrating from xharbour dbfcdx to xharbour + ADS DD dbfcdx (remote-database folder is hidden for users), for temporary user tables? Existing xharbour scenario: T1.dbf =96 template table for user working table T2.dbf =96 template table for user working table User x1: Copy file (structure) t1.dbf to x1t1.dbf Use x1t1 index x1t1a, x1t1b alias Working_1 exclusive new Append.. (from Orders,.. etc..) Replace.. Delete.. Ordsetfocus(x1t1b).. =85 Xharbour + ADS DD dbcdx: How user x1 (x2,.. xn) provide aliases Working_1 (Working_2,..Working...

Error Code :17410 Error State :null Error Message :No more data to read from socket Stack Trace : java.sql.SQLException: No more data to read from socket
Hi, I see the following errors in the logs: Error Code :17410 Error State :null Error Message :No more data to read from socket Stack Trace : java.sql.SQLException: No more data to read from socket at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:114) at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:156) at oracle.jdbc.dbaccess.DBError.check_error(DBError.java:803) at oracle.jdbc.ttc7.MAREngine.unmarshalUB1(MAREngine.java:731) at oracle.jdbc.ttc7.MAREngine.unmarshalSB1(MAREngine.java:690) at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:372) at oracle.jdbc.ttc7...

Data, data, data,
I have been tasked to dump around 400GB of data in physical files into a flat files and the transfer them from an iSeries 810 V5r3 to a windows server. I was going to CPYTOIMPF to a stram file and then copy over to the Windows server from the IFS. Anyone have a better idea or any suggestions? Thanks, Thad Rizzi Hi Thad If you have loads of free disk space on your 810 then your method is fine but if not you may consider Simply FTPing or iSeroes Access file transfering the files directly from the iSeries files to Windows Text file. You can get the either FTP or iSeries Access to carry out...

Error: Data link error
Hello, i use Novel DOS 7.0 with uka_ppp. that works very good with my old mainboard. Since a few weeks a have a new Soyo P4I 845PE ISA mainboard with Pentium IV 2,4 GHz.Now i have the problem, that i can get my mails vom pop.t- online.de. I become the error message "DATA LINK ERROR". I can surf with lynx without problems. I can only get mails from pop.gmx.de or from the news.t-online.de. uka_ppp uses tcpport.exe. I have donwloades the wat-32 libs and compiled the progs etc. But i can not build the tcpport.exe with djgpp. In my wattcp.cfg are .... $vec=60 ...

What is thenature of this error: ERROR: You cannot open WORK._CONVERTDATA.DATA for output access with member-level control because WORK._CONVERTDATA.DATA is in use by
Hi, I am getting an error like: ERROR: You cannot open WORK._CONVERTDATA.DATA for output access with member-level control because WORK._CONVERTDATA.DATA is in use by you in resource environment DMS Process. What is the nature of this error and why I am getting it? How to get rid of this error? I suppose it is related to some system options. I am trying to close my data sets with RC function, but this does not help. Why SAS is so undocumented and sometimes _very_ stupid. I read tons of information already and get everything except what I need. Thanks! If someone can help. (Ho...

data format error
Hello, I am running Sendmail 8.12.8/8.12.1 on Linux box (mandrake 7.x) and could not figure outhow to solve the following problem. I hints, pointers ? Regards M. Akgul ----- The following addresses had permanent fatal errors ----- <elibal@superonline.com> (reason: 553 syntax error, please forward to your postmaster (#5.7.1)) ----- Transcript of session follows ----- ...... while talking to vmx.superonline.com.: >>> MAIL From:<korler@listweb.bilkent.edu.tr> SIZE=7672 <<< 553 syntax error, please forward to your postmaster (#5.7.1) 501 5.6...

sendmail error data format error
dear sir, when i send mails from my mail server i got the following error from /var/log/maillog Dec 16 12:33:39 plain sendmail[2593]: grew WorkList for /var/spool/mqueue to 2000 Dec 16 12:33:40 plain sendmail[2593]: grew WorkList for /var/spool/mqueue to 3000 Dec 16 12:33:40 plain sendmail[2593]: grew WorkList for /var/spool/mqueue to 4000 Dec 16 12:33:40 plain sendmail[2593]: h9OLCdx13158: to=<kanwarjitsingh@isaicai.org>, delay=52+20:21:01, xdelay=00:00:00, mailer=cyrus, pri=166900, dsn=5.6.0, stat=Data format error Dec 16 12:33:40 plain sendmail[2593]: h9OLCdx131...

data environment in data report- error?Why
I have a vb project and I have used data reports. The reports are working perfectly well here. But when I copy the whole folder to another machine, I cannot open the DataEnvironment and it shows error. Why?All the forms and reports can be opened in designed view and works in executable mode also. But I cannot open only the data enironment -Why? Plz help ...

E2900 error on boot: TL = 1, TT = 32. ERROR: Data Access Error -- Help??
Can someone help decipher this error below? Had Sun CE install 32Gb memory into 2 system boards (64Gb total), and now we are getting this error. We tried powering it back up with each system board individually, and get same error no matter which board is in, or both. So we're pretty sure it's not a single dimm that is the problem Sun Fire E2900 OpenFirmware version 5.19.4 (01/19/06 18:06) Copyright 2006 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. SmartFirmware, Copyright (C) 1996-2001. All rights reserved. 32768 MB memory installed, TL = 1, TT = 32....

E2900 error on boot: TL = 1, TT = 32. ERROR: Data Access Error -- Help?? #2
Can someone help decipher this error below? Had Sun CE install 32Gb memory into 2 system boards (64Gb total), and now we are getting this error. We tried powering it back up with each system board individually, and get same error no matter which board is in, or both. So we're pretty sure it's not a single dimm that is the problem Sun Fire E2900 OpenFirmware version 5.19.4 (01/19/06 18:06) Copyright 2006 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. SmartFirmware, Copyright (C) 1996-2001. All rights reserved. 32768 MB memory installed, TL = 1, TT = 3...

ODBC Error: SQLSTATE = S1000, Native error code = -4977 The data buffer parameter is too short(Btrieve Error 22)
HI all, I am trying to insert a new record into a table and got the following error message ODBC Error: SQLSTATE = S1000, Native error code = -4977 The data buffer parameter is too short(Btrieve Error 22) Here is the query I am using. insert into amgr_user_fields_tbl values ('123456789012345678901234',0,38,0,0, '2003-11-01',0.0, '123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890', '123456789012','2003-12-10','16:18:13','1234') Here is the table defination create...

Error Code: 33 [ DATA TYPE ERROR ]
Hope all well. Using VO 2.8 - 2837. Could anyone (Robert if you are there) can shed some light on the cause of Error Code: 33 [ DATA TYPE ERROR ] ? This occurs on various sites, but I cannot duplicate the issue my system and I do a remote web session, I still could not duplicate with the customer tracing the sequence of operations. The VOERROR.LOG has an error on a line: LOCAL dEndDate AS DATE dEndDate := SELF:oDCmDropdate:Value // ERROR 33 HERE . oDCmDropdate is DateTimePicker control which exists on a data window. Error Object created: ----------------...

error 3464 Data type mismatch error!! ??
Does anyone know why I get the error 3464 Data type mismatch from the following code. I have a form with a combo(to choose a consumable) and 2 list boxes on it. list on left is all printers and list on right shows the ones currently compatible with the consumable chosen in the combo at the top. I want to add printers to a corresponding compatible consumable type, by clicking a button and it moving them from the left box to the right and putting the two values in a link table as it is a many 2 many. Now i can do this, but I also have a button which deletes the printers from the consumable b...

Web resources about - DBFCDX, Data Width Error 1026 - comp.lang.xharbour

Clipper (programming language) - Wikipedia, the free encyclopedia
Clipper was originally created in 1985 as a compiler for dBASE III , a very popular database language at the time. Compiling dBASE code changes ...

Clipper (programming language) - Wikipedia, the free encyclopedia
Clipper was originally created in 1985 as a compiler for dBASE III , a very popular database language at the time. Compiling dBASE code changes ...

Resources last updated: 1/26/2016 2:59:28 AM