Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Is there a way to ALIAS a CA the same as its VFP table?
Message
 
À
05/12/2006 11:38:49
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP1
Database:
Visual FoxPro
Divers
Thread ID:
01174105
Message ID:
01174963
Vues:
12
>The question is incorrect for me.
>Use of Alias into the "SELECT..FROM Alias" is not a NATIVE ( storage ) datasource, but a access to runtime application data, then :
>- it don't require a conversion to others backend,
>- the cursor must exist.
>
>If you want to use a true table with an alias, then you have to define the DBF filename somewhere, and 3 data levels are necessary:
>
>CA.Alias,CA.tables,TablesFilename
>
>CA baseclass support 2 levels only CA.Alias,CA.tables, then you have to define a CA subclass
>with this enhancement. It is simple
>( put TablesFilename into the Datasource properties ...)
>a trace:
>
>dataSource = "MyNatoveVFPTable1 SomeAliasThatCAWillExpect1,MyNatoveVFPTable2 ..."
>
>procedure dataSource_Assign(ds)
>
>CEx.CursorFill
>IF this.d..type=="NATIVE"
>  FOR k=1 to ALINES(ta,this.datasource,",")
>     USE GETWORDNUM(ta[m.k],1) AGAIN IN 0 ALIAS GETWORDNUM(ta[m.k],2)
>  NEXT
>ENDIF
>
Totally agree with you.
That's why I said that using a table BEFORE issue of CursorFill() method is not the way you must go hwne you want to convert the application to other backend. Just use another DataSourceType, not NATIVE (and becuase this is VFP9 I suppose you only could use ADO).
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform