Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Increment time() by 1 minute
Message
De
16/06/2005 17:37:00
 
 
À
11/06/2005 07:17:34
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 8 SP1
Database:
Visual FoxPro
Divers
Thread ID:
01020951
Message ID:
01024151
Vues:
22
>>>>Check Dragan's sample for example and try it a few times.
>>
>>I thought that was Dragan's sample I was working with???
>>
>>>>Also try to SQL select with equality operator.
>>
>>I just did and yes... againsts SQL Server it is buggy. And... it was buggy against free tables in VFP.
>>
>>
>>CLOSE DATABASES ALL
>>SET SAFETY OFF
>>CREATE TABLE Test1 (dt t)
>>=RAND(234)
>>FOR X = 1 TO 1000
>>  INSERT INTO Test1 (dt) VALUES (DATETIME()+ROUND((RAND()*10000),0))
>>ENDFOR
>>COPY TO Test2
>>SCAN
>>  m.tDate = Test1.dt
>>  REPLACE Test1.dt WITH m.tDate
>>  m.tDate = Test1.dt
>>  SELECT * FROM Test2 WHERE dt=tDate INTO CURSOR Temp
>>  IF RECCOUNT()#1
>>    USE
>>    SELECT Test2
>>    LOCATE FOR TTOC(Test1.dt)=TTOC(Test2.dt)
>>    ? FOUND(),Test1.dt,Test2.dt,Test1.dt=Test2.dt
>>    CANCEL
>>  ENDIF
>>  USE
>>  SELECT Test1
>>ENDSCAN
>>RETURN
>>
>>
>>It was interesting to note that Test1.dt=Test2.dt does return .T. even though the select fails to locate the matching record.
>
>Yes basically it was my point. In real productions we use SQL often and if something fails might debug it with things like (assuming positioned on a record where we expected to be in resultset):
>
>myTable.Time = m.ltTime
>
>and get .T. !
>
>Cetin

!@#$@!#$ Actually my code had an error in it, it was creating multiple records... So I can't so far, get this to occur against a native table in a select statement.

After further tests... I can't reproduce this on SQL server either.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform