Any database can be queried to perform the necessary actions with the stored data. The most common type of queries is data selection. It presents users with a certain kind of information that satisfies given conditions. There is also a parametric query and an action query. In the relational DBMS Access, you can create a query to any type of database. DBMS tools allow you to quickly and easily create various queries using the design mode or the query wizard. In addition, there is a possibility of "manual" writing of SQL queries.
Necessary
Microsoft Access application
Instructions
Step 1
Start the Microsoft Access application and open your database in it. Based on the existing tables, create the required information requests. To do this, use design mode or the query wizard.
Step 2
In the control section of the database window, go to the "Queries" tab. All existing queries in this database will be displayed on the right, as well as two modes of their creation: “… in design mode” and “… using the wizard”.
Step 3
Click on the inscription to create a query in design mode. A window of this mode will appear on the screen, add the tables you need for the query to it. The existing relationship between the table data will be displayed in the design window after they are added.
Step 4
Double-click the tables on the tables to select the fields whose information you need in the query. The fields will appear in the columns of the query. Set the necessary conditions and mode for displaying fields in the same place. If necessary, specify a grouping of rows or a function for counting values selected from tables.
Step 5
Save the created request by entering its name. A new line will appear in the query window. Check the query result. To do this, double-click it to execute it. A table containing the results of your query will open on the screen.
Step 6
Create a request using the wizard. To do this, click on the corresponding inscription in the requests tab. A wizard will start to guide you. At the first stage, specify all the fields you need from the database tables. To do this, in the "Tables and Queries" drop-down list, put the required name of the table or query. Then use the " arrows to select the fields for your query.
Step 7
If you need a query with a summary function, in the next step, check the box next to the "Summarized" item. Open the mode with the "Totals" button and set the desired function on the selected field to calculate the total value of its data.
Step 8
At the last step, name the created query with a name that is unique for this database and complete the creation with the "Finish" button. A new line with the name of the query will appear in the query window. When you double-click on it, the request will be executed. You will be presented with a table with the results of the generated query.