Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
SQL - Select & SUM
Message
De
31/07/2003 09:53:18
 
 
À
31/07/2003 08:05:57
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00815321
Message ID:
00815367
Vues:
10
>I have a table as follows:
>
>
>NAME       PLANID      NOSHARES
>Russell      1            50
>Russell      4            45
>Mark         3            50
>Mark         2           100
>John         3            30
>Russell      1            70
>Mark         1            35
>Mark         2            20
>
>
>What I would like produced from an SQL Statement is :
>
>
>NAME     PLANID 1    PLANID 2   PLANID 3    PLANID 4
>Russell     120          0         0            45
>Mark         35         120       50             0
>John          0          0        30             0
>
>
>Is this possible? If so, How?
>
>Thanks in advance for your help,
>Russell

What you require is a cross-tab query. Use the Cross tab Wizard to generate it. Its very easy.

Cheers
Sanjay Kapoor

Relatively speaking is a conversation with Einstein
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform