dreamboy27
Programmer
I have a table with 4 cols and i want to count by grouping.Here is my example.
planner supp loc shipment
MA23242 JOHN 01 TA
MA23242 JOHN 01 TA
MA23242 JOHN 01 TE
MA23242 JOHN 02 TR
MA23111 JIMM 02 TA
MA23111 JIMM 02 TR
MA23111 JIMM 02 TE
MA28888 DAVE 01 TR
MA28888 DAVE 01 TR
MA28888 DAVE 01 TR
HERE IS MY DATA BASE:
and my result chould be
planner supp loc TA TE TR
MA23242 JOHN 01 2 1 0
MA23242 JOHN 02 0 0 1
MA23111 JIMM 02 1 1 1
MA28888 DAVE 01 0 0 3
I NEED A SQL STATEMENT PLEASE AND THE TABLE I AM USING IS A HUGE TABLE
planner supp loc shipment
MA23242 JOHN 01 TA
MA23242 JOHN 01 TA
MA23242 JOHN 01 TE
MA23242 JOHN 02 TR
MA23111 JIMM 02 TA
MA23111 JIMM 02 TR
MA23111 JIMM 02 TE
MA28888 DAVE 01 TR
MA28888 DAVE 01 TR
MA28888 DAVE 01 TR
HERE IS MY DATA BASE:
and my result chould be
planner supp loc TA TE TR
MA23242 JOHN 01 2 1 0
MA23242 JOHN 02 0 0 1
MA23111 JIMM 02 1 1 1
MA28888 DAVE 01 0 0 3
I NEED A SQL STATEMENT PLEASE AND THE TABLE I AM USING IS A HUGE TABLE