Coding With Fun
Home Docker Django Node.js Articles Python pip guide FAQ Policy

MS Access aggregates data


May 16, 2021 MS Access



Aggregate queries are useful if you are looking for only one specific number, but if you want to summarize information such as spreadsheet summaries, you might want to consider trying a crosstase query. 20> a crosstase query.

  • A crosstass query is a selection query. W hen you run a crosstase query, the results are displayed in the data table. This data table has a different structure than other types of data tables.

  • The structure of a crosstace query is easier to read than a simple selection query that displays the same data, as shown in the following screenshot.

By far, the easiest way to create a crosstace query in Access is to simply use the wizard that came with Access to create a crosstace query. Let's now go to the Create tab, in the query group, and then click the query wizard.

MS Access aggregates data

In the dialog box above, you can see a variety of special queries. Y ou can create a simple query wizard, just as we did in Design View. OK. ow, select the crosstase query, and then click OK.

MS Access aggregates data

The first screen in the wizard will prompt what table or query contains the fields that you want to use for the results of the crosstase query. xt. lick Next.

MS Access aggregates data

We will now look for the available fields for the query. I t prompts you to enter the desired field value as the line title. 20> ow select the title field and send it to the selected field area, and then click Next.

MS Access aggregates data

In the dialog box above, the problem is that you want to use as a column title, which really depends on what you want to evaluate. Let's say you want to view our sales by date, select TransactionDate, and click Next.

MS Access aggregates data

The question in the dialog box above is based on the special field of the field we selected earlier, because we selected the date time column. > . elect the year option, and then click Next .

MS Access aggregates data

The next question in the dialog screen above asks you how many numbers you want to calculate for each column in the row cross. 21> Quantity (QTY) and Sum from the feature, and then click Next.

MS Access aggregates data

The last screen of the wizard asks you to name the query, and then click Done to view the query.

MS Access aggregates data

We now have book information and information about the total sales, when selling each one.