Solved

How to auto-fill field in Access 2010 Table

Posted on 2014-09-03
5
8,422 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 38

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 58

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

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

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

In earlier versions of Windows (XP and before), you could drag a database to the taskbar, where it would appear as a taskbar icon to open that database.  This article shows how to recreate this functionality in Windows 7 through 10.
If you need a simple but flexible process for maintaining an audit trail of who created, edited, or deleted data from a table, or multiple tables, and you can do all of your work from within a form, this simple Audit Log will work for you.
What’s inside an Access Desktop Database. Will look at the basic interface, Navigation Pane (Database Container), Tables, Queries, Forms, Report, Macro’s, and VBA code.
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

623 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