Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Query Results to Cursor - Manipulating data
Message
De
14/07/1999 06:23:58
Mark Hall
Independent Developer & Voip Specialist
Keston, Kent, Royaume Uni
 
 
À
14/07/1999 06:17:33
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00241169
Message ID:
00241170
Vues:
16
>On a network app I use an SQL statement to populate a cursor which then displays results in a grid. The data includes people's date of birth which I need to display as an age - but I understand I cannot maniplulate cursor contents (i.e by using the date of birth to calculate the age). Is there any way round this, i.e. allowing me to modify the results of the query once in the cursor? I am using a cursor as the output from the query because it is a network app and cannot export the result to a table in case more than 1 user tries to use the facility at the same time.

You could do the age calculation as part of the SQL SELECT
e.g.
SELECT DOB, INT(DATE()-DOB / 365.25) AS AGE, .... ;
FROM TABLE

Or there is a way to modify a cursor
USE (DBF("Cusror")) AGAIN IN 0 ALIAS SecondCopy
Regards
Mark

Microsoft VFP MCP
Menulib - OO Menus for VFP www.hidb.com/menulib
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform