Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Crazy behaviour
Message
De
23/05/2003 06:31:32
 
 
À
22/05/2003 19:58:50
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Titre:
Divers
Thread ID:
00792009
Message ID:
00792116
Vues:
17
Hi Piet,

you uses variable time function on query with attention.
These are evaluate for any comparison, an for long query these can change.

If you exec query on 23:59:59.50, start data is X,
but data change before query is terminate.

Moreover, it is very slow.

uses variable:

yearNow=YEAR(DATE())
LOCATE FOR iordernr = m.i_ordernr and year(dOrddate)=m.yearNow

can be best:
=LOOKUP(iordernr,m.i_ordernr,iordernr)
yearNow=YEAR(DATE())
LOCATE REST FOR iordernr = m.i_ordernr and year(dOrddate)=m.yearNow

and for long table
=LOOKUP(iordernr,m.i_ordernr,iordernr)
yearNow=str(YEAR(DATE()),4)
s_ordernr=LTRIM(STR(m.i_ordernr))
LOCATE REST FOR iordernr =&s_ordernr and year(dOrddate)=&yearNow

Fabio
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform