Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Big Bug with Integer Field
Message
De
27/12/2000 13:38:11
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Big Bug with Integer Field
Divers
Thread ID:
00457047
Message ID:
00457047
Vues:
68
Hi, everybody!

I need your help... I'm with a problem that is ocurring also with some other friends (and with some other, not)...

Do as follows:

* Create a table called Test1 with the structure:
Field: iID
Type: Integer

* Create a table called Test2 with the structure:
Field: iID
Type: Integer

* Create any FOR/NEXT to fill these tables with some 1000 records
For example:
SELE TEST1
FOR i=1 TO 1000
appen blank
repl all iID with recno()
ENDFOR

Do this in both tables.

Well, these two table has the same structure and the same content (records and value)

Now, run the following command:

SELECT * FROM TEST1 WHERE IID NOT IN (SELECT IID FROM TEST2)

We're trying to descover which records is in the Test1 and don't have a corresponding record in Test2. It must return Zero records, because they're exact the same. However, here comes the problem: in my SQL, returns a cursor with the folling records: 17, 253, 509 and 765. Do you see? It begun with 17, and goes adding 256... 17+256=253... 253+256=509.. etecera...

After did a lot of attempts, I resolved to change the type of field IID of table Test2, to Numeric 4,0... well, it does work... I'm sure that it's a problem with Integer Fields.

Could anybody explain this for me?

Thanks in Advance

[]'s

Lassala
Claudio Lassala
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform