I have a database with two tables. The structure of each is identical (see below). Table 1 (2004 sales) contains sales data from 2004 and table 2 (2005 sales) contains sales data for 2005.
Table structure (Simplified).
Month Area Shop No of sales
Jan-04 Area 1 Shop 101 6
Jan-04 Area 1 Shop 102 8
Jan-04 Area 2 Shop 201 5
Jan-04 Area 2 Shop 202 10
Feb-04 Area 1 Shop 101 7
Feb-04 Area 1 Shop 102 5
Feb-04 Area 2 Shop 201 6
Feb-04 Area 2 Shop 202 8
What I am trying to do seems simple yet I am struggling.
I want to sum the sales, by area and year, for example Jan-04 and Jan-05 and then show the difference.
Ideal report structure:
Jan-04 Jan-05 Difference
Area 1 14 13 -1
Area 2 15 20 5
I have created a cross-tab to show the first 3 columns, i.e Area, Jan-04 and Jan-05 but I cannot create the difference column.
Can anybody help!
Table structure (Simplified).
Month Area Shop No of sales
Jan-04 Area 1 Shop 101 6
Jan-04 Area 1 Shop 102 8
Jan-04 Area 2 Shop 201 5
Jan-04 Area 2 Shop 202 10
Feb-04 Area 1 Shop 101 7
Feb-04 Area 1 Shop 102 5
Feb-04 Area 2 Shop 201 6
Feb-04 Area 2 Shop 202 8
What I am trying to do seems simple yet I am struggling.
I want to sum the sales, by area and year, for example Jan-04 and Jan-05 and then show the difference.
Ideal report structure:
Jan-04 Jan-05 Difference
Area 1 14 13 -1
Area 2 15 20 5
I have created a cross-tab to show the first 3 columns, i.e Area, Jan-04 and Jan-05 but I cannot create the difference column.
Can anybody help!