Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Cartesian join produces 0 records
Message
 
 
À
31/01/2006 19:25:29
Alan Harris-Reid
Baseline Data Services
Devon, Royaume Uni
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
01091514
Message ID:
01092145
Vues:
22
>Tried the above code, and I got the expected result of
>RECCOUNT('Cursor3')=1. So this got me thinking... My Cursor2 had one record, but SELECT * FROM Cursor2 resulted in zero records. The purpose of Cursor2 was to create an empty cursor from a SQL table using SQLEXEC(lnHandle,[SELECT * FROM MyTable WHERE1=2],'Cursor2'), then I performed an APPEND BLANK in order to get a single record to join with Cursor1 to produce a single record in Cursor3. As soon as I fill any field in Cursor2 with some data, then perform the join, I get the expected result.
>
>As your code above worked fine with APPEND BLANK, I suspect the problem lies with how Cursor2 was originally created using SQLEXEC. Is there something wrong with my thinking?

Alan,

The cursor created with SQLEXEC() is set to the optimistic record buffering. You have to issue TABLEUPDATE() after addding a record.
--sb--
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform