Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How can I fill a grid with monthly figures?
Message
De
18/01/2002 08:08:59
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
18/01/2002 08:01:29
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00606622
Message ID:
00606627
Vues:
16
>Hi all...
>I need a grid that takes information from a sales table, summarize by month and display the results. Something like this:
>
>column1-------column2
>Jan-2001------1,234
>Feb-2001------2,345
>.
>.
>.
>(current month-year)----456
>
>you get the idea.
>I think a select sql would do the trick, but honestly can't figure out how.
>
>Thanks in advance for your time
>
>Ulises

Check the GROUP BY clause in the SELECT command. For instance:
select month, sum(amount) as amount;
  from DetailTable;
  group by month;
  into cursor result
browse
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform