Alaska Software Inc. - copy from : Foxpro migration
Username: Password:
AuthorTopic: copy from : Foxpro migration
Alain Rcopy from : Foxpro migration
on Thu, 23 Apr 2015 12:10:29 +0200
Hello

    I have a insolving problem with FoxProx et Xbase with index file

I'm working in Clipper, dbase and Xbase.

At office, we use a program from Headquater and It's writing in FoxPro !

With a program write in Xbase, I would like use DBF FOXPRO without
use the index files created by FoxPro.

It's works fine since 2 years but we have a new program from main office.

Now I have a problem of indexing.

When I create a new index ( with DbeSetDefault( "FOXCDX" ) )
i have a problem with a field named clenunik_1  ( it's structure is
character)

my coding :

   DbeSetDefault( "FOXCDX" )
   icibleB   := w_rep_tempo + "clefunik.cdx"
   delete FILE (icibleB)
   do init_p
      OrdCreate(iCibleB,,"upper(clenunik_1)",{||prog_p(upper(clenunik_1))})
( VERSION 1)
   do end_p


      OrdCreate(iCibleB,,"clenunik_1",{||prog_p(clenunik_1)})    ( VERSION
2)


The indexation works because the windows progression show the status (oProgr
:= ProgressBar():new(oFCrt,,{950,030},{15,650},,.f.))

but when te program must close the index files, it crashes

When I use version 1 with UPPER :

------------------------------------------------------------------------------
Log Erreur de "Gestion CE.EXE" Date: 22/04/2015 16:58:23

Xbase++ version     : Xbase++ (R) Version 1.90.331
SystSme d'op,raton  : Windows XP 05.01 Build 02600 Service Pack 3
------------------------------------------------------------------------------
oError:args         :
          -> VALTYPE: U VALUE: NIL
oError:canDefault   : N
oError:canRetry     : N
oError:canSubstitute: Y
oError:cargo        : NIL
oError:description  : Parameter has a wrong data type
oError:filename     :
oError:genCode      :          2
oError:operation    : upper
oError:osCode       :          0
oError:severity     :          2
oError:subCode      :       1025
oError:subSystem    : BASE
oError:thread       :          1
oError:tries        :          0
------------------------------------------------------------------------------
CALLSTACK:
------------------------------------------------------------------------------
Appel par (B)FACTURATION(0)
Appel par FACTURATION(265)
Appel par (B)MAIN(453)
Appel par MAIN(498)


When a use version 2 without UPPER :


------------------------------------------------------------------------------
Log Erreur de "Gestion CE.EXE" Date: 22/04/2015 17:01:27

Xbase++ version     : Xbase++ (R) Version 1.90.331
SystSme d'op,raton  : Windows XP 05.01 Build 02600 Service Pack 3
------------------------------------------------------------------------------
oError:args         :
          -> VALTYPE: C VALUE: F:\bdce\data\clefunik.cdx
          -> VALTYPE: U VALUE: NIL
          -> VALTYPE: C VALUE: clenunik_1
          -> VALTYPE: B VALUE: {||prog_p(clenunik_1)}
          -> VALTYPE: L VALUE: Y
          -> VALTYPE: L VALUE: Y
oError:canDefault   : Y
oError:canRetry     : Y
oError:canSubstitute: N
oError:cargo        : NIL
oError:description  :
oError:filename     :
oError:genCode      :       8999
oError:operation    : OrdCreate
oError:osCode       :          0
oError:severity     :          2
oError:subCode      :          0
oError:subSystem    : BASE
oError:thread       :          1
oError:tries        :          1
------------------------------------------------------------------------------
CALLSTACK:
------------------------------------------------------------------------------
Appel par FACTURATION(266)
Appel par (B)MAIN(453)
Appel par MAIN(498)


Thanks for your ideas and sorry for my bad english

alain
Peter AlderliestenRe: copy from : Foxpro migration
on Fri, 24 Apr 2015 17:46:44 +0200
Alain,

Could it be that the FoxPro table supports NULLABLE fields and one of the
fields has a NIL value?
What happens if you SET NULLVALUE OFF?

Peter
Alain RRe: copy from : Foxpro migration
on Sat, 25 Apr 2015 13:17:36 +0200
Bonjour Peter

    Exactement, mes programmes écrit en xBase fonctionnait bien.
Mais les programmes écrit en FoxPro ont été mis à jour.
Et une modification a été apporté à cette BD !
Le champ "Clenunik_1" a ce nouveau "statut"
Je ne peux pas modifier la structure du fichier sans
avoir des bugs dans notre programme principal. !


Hello Peter

Exactly, my programs write in xBase worked well.
But the programs write in FoxPro were improved. (modified upgraded)
And a modification was made to the  DB's structure ! Why I don't now !
The field " Clenunik_1 " has this new "status" -> character but NULL is 
activated
I cannot modify the structure of the file without having bugs in our main 
program.!

Thanks a lot Peter

Bye



"Peter Alderliesten" a écrit dans le message de groupe de discussion : 
1m6wzn6j9zohl.j5lnyox7bo7b$.dlg@40tude.net...
> Alain,
>
> Could it be that the FoxPro table supports NULLABLE fields and one of the
> fields has a NIL value?
> What happens if you SET NULLVALUE OFF?
>
> Peter
Alain RRe: copy from : Foxpro migration
on Thu, 30 Apr 2015 11:53:29 +0200
Hi Peter

    If I put set nulllvalue off
that's work perfectly

Thanks to you

Bye

Alain


"Peter Alderliesten" a écrit dans le message de groupe de discussion : 
1m6wzn6j9zohl.j5lnyox7bo7b$.dlg@40tude.net...
> Alain,
>
> Could it be that the FoxPro table supports NULLABLE fields and one of the
> fields has a NIL value?
> What happens if you SET NULLVALUE OFF?
>
> Peter