To actually change the values in your table you can run an UPDATE Query against the table. You should always back your data up before running an UPDATE Query — there is no “undo” to return your data to its unchanged state (you could of course possibly run a second UPDATE Query to return it to its previous state — depending on what the first UPDATE actually did)!
In this post:
Here is a handy UPDATE Query you could implement in your PAT database. The goal of this query is to “clean” your data of any extra spaces that may have crept in during the data capturing phase (users often add extra spaces at the end of words and phrases when entering data).
2. Trim function
The Trim function removes leading and trailing spaces from a string. Interestingly, Excel’s TRIM function removes extra spaces from within a string as well as leading and trailing spaces.
Create a basic Query that includes the field(s) that you want to update, then complete the steps below with the help of this screenshot:
- Activate the Query Tools » Design ribbon,
- click on the Update button to convert the Select Query to an Update Query,
- an Update To row now appears in the design grid,
- click in the Update To row, and
- type the expression: Trim([fieldname])
Remember: once you have saved the UPDATE Query, if you double-click the Query, it will run the Query, so you always need to be careful with it!