Creating a Parameter Query

graphics/microsoft93.gif

When you need to change the criterion value for a query, you either must edit the old query or create a new one. However, if the change involves simply altering a value, you might consider using a parameter query. A parameter query prompts the user for the value of a particular query field, rather than having the value built into the query itself. For example, if you want to display the records for particular toy types, a parameter query can prompt you for the type, saving you from creating a separate query for each type.

Create a Parameter Query

graphics/one_icon.jpg

In Query Design view, click the Criteria box.

graphics/two_icon.jpg

Enter the text of the prompt surrounded by square brackets.

graphics/three_icon.jpg

Click the Run button on the Query Design toolbar.

graphics/four_icon.jpg

Enter a criteria value in response to the prompt.

graphics/five_icon.jpg

Click OK.

graphics/13inf24.jpg

graphics/13inf25.jpg

Did You Know?

You can rename a field . Access assigns a name to a calculated field. If you want a different name, click the field in the design grid, and then click the Properties button on the Query Design toolbar. Enter a new name in the Caption box, and then click OK.



Show Me. Microsoft Office 2003
Show Me Microsoft Office 2003
ISBN: 0789730073
EAN: 2147483647
Year: 2002
Pages: 418

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net