Solved

How to auto-fill field in Access 2010 Table

Posted on 2014-09-03
5
6,538 Views
Last Modified: 2016-09-05
I have a table with about 1750 records, there is a field that is currently empty that I would like to populate with a name of a group called Sunshine.  Do not want this to populate going forward, just want to be able to have it filled in now.  Do not want to have to go to each record and put it in.  Any and all assistance, input would be greatly appreciated.
0
Comment
Question by:FreddyBass
5 Comments
 
LVL 34

Expert Comment

by:PatHartman
ID: 40301821
Create an update query to populate the value.  With no criteria, it will update all records.  If you want to update only some records, add criteria to select the records you want to update.

Here's a sample that joins two tables and sets the careplan in one table to the value found in the second but only where the careplan is empty:

UPDATE TEMP_PAfromPortal INNER JOIN tblCarePlans ON TEMP_PAfromPortal.CPID = tblCarePlans.CPID SET tblCarePlans.PortalCarePlan = [TEMP_PAfromPortal].[CarePlan]
WHERE (((tblCarePlans.PortalCarePlan) Is Null));

Open in new window

0
 
LVL 57

Accepted Solution

by:
Jim Dettman (Microsoft MVP/ EE MVE) earned 500 total points
ID: 40301822
1. go to queries and choose new.

2. select the table you want to update.

3. change the query type to update.  When you do, you'll see a line in the grid appear called "Update to"

4. Pull down from the table into the grid the field you want to update

5. Fill in "Sunshine" on the "Update to" line under this column.

6. Execute/run the query.   it should tell you you have 1750 records to update.   If there are more records than just those, pull down additional fields and place criteria on them to get the records you want.   Just leave the "Update to" line blank for these.

 Note that you may want to leave it as a select query until you get all the records that you want, then switch to an update type.

Jim.
0
 

Author Closing Comment

by:FreddyBass
ID: 40301899
Hello Jim,

Thank you for your input and the way that you spelled out how to achieve solution was much appreciated.

Fred
0
 

Expert Comment

by:Karthik Shanmugam
ID: 41784595
Hi Jim,

The information provided here on how to fill series in Access was very useful. I was working one important data for which I had to use this option. I must say it saved a whole lot of time. Thank You so much
0
 

Expert Comment

by:Karthik Shanmugam
ID: 41784596
Hi Jim,

 The information provided here on how to fill series in Access was very useful. I was working one important data for which I had to use this option. I must say it saved a whole lot of time. Thank You so much
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
Familiarize people with the process of utilizing SQL Server views from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Access…
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now