Tables :: Moving Records From One Table To Another

Jan 16, 2014

I have to move records from one table to another.

When we lose a client I need to take them out of my current table and put them in my dropped table.

I don't want to lose my summary info and I want the dropped client to keep it's ID Number which is an identifier.

Seems I can't just copy it from one table to another and then go back and delete it from the Current.

Seems I can't cut from Current and paste into Dropped.

In a perfect world it would be great if my boss could just check a box in Current Table and the record moved to Dropped all by itself!

View Replies


ADVERTISEMENT

Moving Records Fluidly Between Tables

Sep 5, 2014

I am designing a database to keep track of a state's surplus fire property to be doled out to volunteer departments as I see fit.

I have a table for surplus property that includes what department currently has the surplus property, what type of equipment it is and additional equipment information. I also have a table for "pending transfer property" to track what pieces of property I have decided to potentially assign to a fire department from the state's surplus inventory.

My problem comes when I need to transfer a piece of equipment from one department to another. I would like the surplus property table to automatically remove the property from the surplus property table to the pending transfer table so that it will not be listed on a pending transfer and in the states surplus at the same time. On the flip side, if a transfer falls through I'd like that record to repopulate in the surplus inventory again.

View 2 Replies View Related

Tables :: Moving Records Between Tables?

May 7, 2014

I have been tasked with creating a simple database for work.

Basically the table tracks the progress of various employment checks. So example headings are Name, CRB, Occupational Health etc. Now basically, once all the checks are completed, I need the record to be moved to another table named 'Live'.

Is there any easy way to achieve this, or will i have to manually move each record once the checks have been completed.

View 3 Replies View Related

Moving Records In The Same Table?

May 22, 2006

Hello there,

Is it possible somehow to move a record in the same table, to different row (in the form)? Or in other words, is it possible manualy adjust the position of records (rows) in a report?

I have a continuous form, where rows are filled with data (e.g. 10 rows ).Then i have report , which looks the same as form (rows, and their order). But sometimes user wants to move certain position (row) up or down, to be it on top or bottom or two places above, or below etc, of row list....is there any easy way to do it? Like some button press, where you could swap position with next record (next row) .....

Or just delete (everything) and fill again from beginning the way he wants...

Thanks!

View 4 Replies View Related

Moving Records To Another Table Then Delete

Mar 15, 2007

OK guys, ive done some searching and saw some stuff on this, but everytime I try something I get a INVALID SQL error message. So Im hoping you guys can help out cause Im lost right now.

I have a 2 tables, Training and Schedule. Training contains all the employees training records. Schedule is meant to be a temp table where the supervisors can enter the training and then once completed, can check the COMPLETED checkbox and hit the LOAD TO TRAINING RECORD command button and it moves ONLY the files for that trainee (a combo box) with a completed checkmark to the training table.

Ive tried this code sooooooooo many ways and its giving me a headache. My original way didnt work at all (had a lot of Do..Loop and With Statements, and then someone posted something about Archiving which is the code Ive gone off of now). Any help you guys can off would be awesome!

Heres what I got:

Private Sub cmdLoad_Click()

On Error GoTo Err_Load_Record_Click

UploadHistory

Exit_Load_Record_Click:
Exit Sub

Err_Load_Record_Click:
MsgBox Err.Description
Resume Exit_Load_Record_Click

End Sub

Sub UploadHistory()

Dim DB As Database
Dim WS As Workspace 'Current workspace (for transaction).
Dim strSql As String 'Sql Code.
Dim strMsg As String 'MsgBox message.
Dim bInTrans As Boolean 'Flag that transaction is active.

Set DB = CurrentDb()
Set WS = DBEngine(0)
WS.BeginTrans
bInTrans = True
Set DB = WS(0)

On Error GoTo Err_UploadHistory

'Execute the add.
strSql = "INSERT INTO [Training] " _
& "(TaskNumber, Date, Hours, TrainerLast, TraineeLast, Qualified) " _
& "SELECT " & "Schedule.Task, Schedule.Date, Schedule.Hours, Schedule.Trainer, " _
& "Schedule.Trainee, Schedule.Qualified FROM [Schedule] " _
& "WHERE (((Schedule.Trainee) = " & Me.TraineeCombo & " AND (Schedule.Completed)= 1));"

DoCmd.SetWarnings False
DoCmd.RunSQL strSql
DoCmd.SetWarnings True

'Execute the delete.
strSql = "DELETE FROM [Schedule] WHERE Trainee = " & Me.TraineeCombo & " AND Completed = 1;"

DoCmd.SetWarnings False
DoCmd.RunSQL strSql
DoCmd.SetWarnings True

'Get user confirmation to commit the change.
strMsg = "Upload " & DB.RecordsAffected & " record(s) from " & Me.TraineeCombo & "?"
If MsgBox(strMsg, vbOKCancel + vbQuestion, "Confirm") = vbOK Then
WS.CommitTrans
bInTrans = False
End If

Exit_UploadHistory:
'Clean up
On Error Resume Next
Set DB = Nothing
If bInTrans Then 'Rollback if the transaction is active.
WS.Rollback
End If
Set WS = Nothing
Exit Sub

Err_UploadHistory:
MsgBox Err.Description, vbExclamation, "Upload failed: Error " & Err.Number
Resume Exit_UploadHistory

End Sub

View 4 Replies View Related

Tables :: Moving Data From One Table To The Other Via Yes / No Boxes?

Jul 5, 2013

I have two tables;

Parts
Sold Parts

Now what I am trying to get to happen is using a YES/NO box, Say i have a "part" in the parts table when i click the YES/NO box, to have the tick to say it has been sold, I want that line to move to the Sold Parts table. is this even possible?

View 5 Replies View Related

Moving Records From One Table To A New Table?

Apr 10, 2012

1st - Table one, holds around 10,000 recordes, names and phone numbers and basic address information

2nd - Table two which holds all out customer details eg full name and case details and is used by an admin team

What I was hoping to do was have one form designed from table one and when the agent changes a status it moves the record from table one to table two.

View 5 Replies View Related

Moving Data From 2 Related Tables To 2 New Tables As An Archive

Apr 3, 2007

I have a form displaying the 11 fields of the parent/primary table using a selection from a combo box. I am using queries and vba code modules respective to form, combo box and command buttons. I have initial code that uses the two fields from the combo box selection to append same to a new parent/primary archive table. I now want to add to the append SQL the remaining fields to the parent/primary archive table. When I add the second sql string for the remaining fields to the same procedure and execute I keep getting 'null in primary key'. If I copy the primary record and paste same into the archive table it works.

Private Sub Command26_Click()
On Error GoTo Err_Archive_Primary_Click

Dim strSQL As String
Dim strSQL2 As String

strSQL = "INSERT INTO ARC_289325045 ([Survey Point ID], [Survey Area Detail], [Date On Site]) " & _
"VALUES ('" & Me.cboAreaDetailDate.Column(0) & "','" & Me.cboAreaDetailDate.Column(1) & "'," & _
"#" & Me.cboAreaDetailDate.Column(2) & "#)"

CurrentDb.Execute strSQL, dbFailOnError

'strSQL2 = "INSERT INTO ARC_289325045 (RecordID, UnitID, UserName, [TimeStamp], [Survey Point - Area], Measurement, NewArea, [EXIT Form] ) " & _
'"SELECT FORM_ID_289325045.RecordID, FORM_ID_289325045.UnitID, FORM_ID_289325045.UserName, FORM_ID_289325045.TimeStamp, FORM_ID_289325045.[Survey Point - Area], FORM_ID_289325045.Measurement, FORM_ID_289325045.NewArea, FORM_ID_289325045.[EXIT Form] " & _
'"FROM FORM_ID_289325045"

'CurrentDb.Execute strSQL2, dbFailOnError



Exit_Archive_Primary_Click:
Exit Sub

Err_Archive_Primary_Click:
MsgBox Err.Description
Resume Exit_Archive_Primary_Click

End Sub


The next step is to do the same for the child table and append related records to the child archive table.

View 4 Replies View Related

Moving Data From 2 Related Tables To 2 New Tables As An Archive

Apr 3, 2007

I have a form displaying the 11 fields of the parent/primary table using a selection from a combo box. I am using queries and vba code modules respective to form, combo box and command buttons. I have initial code that uses the two fields from the combo box selection to append same to a new parent/primary archive table. I now want to add to the append SQL the remaining fields to the parent/primary archive table. When I add the second sql string for the remaining fields to the same procedure and execute I keep getting 'null in primary key'. If I copy the primary record and paste same into the archive table it works.

Private Sub Command26_Click()
On Error GoTo Err_Archive_Primary_Click

Dim strSQL As String
Dim strSQL2 As String

strSQL = "INSERT INTO ARC_289325045 ([Survey Point ID], [Survey Area Detail], [Date On Site]) " & _
"VALUES ('" & Me.cboAreaDetailDate.Column(0) & "','" & Me.cboAreaDetailDate.Column(1) & "'," & _
"#" & Me.cboAreaDetailDate.Column(2) & "#)"

CurrentDb.Execute strSQL, dbFailOnError

'strSQL2 = "INSERT INTO ARC_289325045 (RecordID, UnitID, UserName, [TimeStamp], [Survey Point - Area], Measurement, NewArea, [EXIT Form] ) " & _
'"SELECT FORM_ID_289325045.RecordID, FORM_ID_289325045.UnitID, FORM_ID_289325045.UserName, FORM_ID_289325045.TimeStamp, FORM_ID_289325045.[Survey Point - Area], FORM_ID_289325045.Measurement, FORM_ID_289325045.NewArea, FORM_ID_289325045.[EXIT Form] " & _
'"FROM FORM_ID_289325045"

'CurrentDb.Execute strSQL2, dbFailOnError



Exit_Archive_Primary_Click:
Exit Sub

Err_Archive_Primary_Click:
MsgBox Err.Description
Resume Exit_Archive_Primary_Click

End Sub


The next step is to do the same for the child table and append related records to the child archive table.
Edit/Delete Message Reply With Quote Quick reply to this message
JJKramer
View Public Profile
Send a private message to JJKramer
Find all posts by JJKramer
Add JJKramer to Your Buddy List
Sponsored Links

View 1 Replies View Related

Tables :: Linking Records In One Table To Multiple Records In Another And Assign Percentage?

Nov 21, 2012

I have a table (tbl Team Info) which contains names and codes for teams within my business (>400 records) and another table (tbl Process) which contains a list of high level tasks (30 records).

I need to create something where for each team name 9in tbl Team Info) I can map them to the tasks that they undertake (in tbl Process) and assign a percentage of time then spend on each task. Each team could map to several different tasks.

View 3 Replies View Related

Moving Records

Mar 6, 2005

I would like a button on my form that will move a record from one table to another. Can anyone tell me how to do this

View 2 Replies View Related

Moving Old Records.

Oct 25, 2005

hiya!

i have a database that holds details of calls that have been answered on the phone concerning problems with computers.
details that are recorded are caller name, and date of call etc...

however, i want to know if there is a way that i can move all calls recorded BEFORE the present date to another table ( say a "past calls")..?

is there a button that i can put on my database that will run a function and move all calls recorded before the present date to another seperate table..?

thanks everyone!
johnny
:)

View 1 Replies View Related

Moving Records

Jun 27, 2005

Could someone assist me in getting code that allows me to move a record from one table to another when the user clicks a button.

Thanks

View 13 Replies View Related

Moving All Records In Field Down 3 Records

May 30, 2013

I currently have a database that I had to copy over each field from another databse to create the one i have now. When i copy the records from one field over it appears they all move up three spaces for some reason is there a equation i can enter to make them all move down three records in the table?

View 2 Replies View Related

Moving Invaid Records

Nov 28, 2006

Hi again

I have a table that’s full of records, I want to split it into 2 separate tables (identical structure but they have input masks), The input mask is set to LLL0000 all I want to do is send valid records to one table and invalid ones to the other.

I think the best way would be an update query but it doesn’t check the input mask only the validation (and trying to break the string apart using an expression is impractical and lengthy)

Can anyone think of any way of splitting this table – I’m getting rather desperate now and have been trying for over a week with no success

Any help is greatly appreciated

Thanks
Matt

View 3 Replies View Related

Help Moving Records From A Form

May 7, 2005

I have an Employee Database with a form that displays the employee record. When an employee leaves they want to be able to click on a button on the form and have the record moved to a different table. My thought was to do a append query to move the record from my active employee table to the termed employee table, but that would still leave a copy in my active table. I'm not real up on coding that much so Im not sure if there's a way to have code move a record from 1 table to another table or copy the data from 1 table to another table and delete it from the first table. Any help would be greatly appreciated.

View 12 Replies View Related

When Moving From Records On A Form

Sep 10, 2004

I was wondering if anyone knew how to check when the user has clicked to move on to the the next record on a form?

Ed

View 1 Replies View Related

Moving Tables From One Database To Another

Nov 21, 2012

I am working in Microsoft Access 2010 and wanted to move tables from a number of databases to a "Master List of Tables" without having to manually recreate them. The purpose is to have this "Master List" available when we are creating new databases covering similar topics.

I was hoping to use the import tool but it appears to address only data not tables.

View 3 Replies View Related

Moving Record Information To New Records

Dec 29, 2005

Hi, found this forum looking for an answer to this question. Hope someone can help.

I'm trying to build a database that tracks electronic components. Mostly the database tracks location movements, but also repair issues and other possible changes. I'm thinking the best way is a database that has a record for each move, and any other changes are included in each record.

My question is, is there a way I can easily have the current information be propogated over to a new record, where it could then be modified? Example: I'm looking at a record of an item that was just returned to me. I would like to click a button on the form which would create a new record, then move all currently displayed information into that record.

Thanks for any help.

View 3 Replies View Related

Moving Through Records And Updating Sub Forms

Jan 23, 2006

hi all,

I have this database I'm working on and have a couple of issues I can't work out.

The first is this, I want to have my sub forms go to the last record when moving through the main form, currently I can only get this to work when I open the form?

If I move through the records in my main form (forward and backwards), the two sub forms go to the first record only, so how can I get them to go to the last recor?

I've attached the DB to show you what I mean.
Thanks in advance
Tez

View 3 Replies View Related

Tables :: How To Combine Records Of Three Tables Into One Table

Jul 30, 2013

I have three tables. I want to combine all the records in these tables into one table. I need VBA code to do this. The first table is called down1, the second table is called down2 and the third table is called down3. All these tables contain the same fields so I don't think combining them will be a problem.

View 3 Replies View Related

Moving Entries From One Table To Another

Jun 12, 2006

So I have 2 tables, the first is for "open" orders (where entries get edited changed and deleted), and the Second is for "finished" orders (where once an order is completed it should move from the open orders table to the finshed one where it will no change and will remain for futre reference)

I need help with the transfering part of this problem. I would ideally like to make a form that allows you to pull up the info for the open order then edit it to finally add the finished order to the other table. Im not sure where to start on this one.

View 3 Replies View Related

Moving Data From One Table To Another

Aug 21, 2006

Hi there,

I have a simple database with a form that displays the contents of a table called Products. I want to be able to delete items from Products but these should be move into ProductsArchive table and I will then create a seperate form to view Products that have now been removed but were once currently live if that makes sense?

I would like to write some code that on the form when the user clicks on the delete button it will just move the data relating to that record into the ProductsArchive table.

Can anyone help?

View 3 Replies View Related

Moving Fields To New Table

Feb 21, 2007

Hey guys,

I'm trying to move a group of fields to a new table. I want the data to follow it. Is there an easy way to do this?

View 5 Replies View Related

Moving A Record From One Table To Another

Oct 24, 2005

I have a database of assets.

For example a computer will have an asset .

This database will show the asset, where it is, what it is and who its with .
It will display this on a form.

When this asset gets given to someone else i want a button on the form which displays the assets current data to be clicked and for that info to be moved from the asset current table into the asset history table.

any idea what vb code would do this?

View 1 Replies View Related

Moving A Record From One Table To Another

Oct 24, 2005

Database is an asset register.

I have a table called assetcurrent

It displays the asset and where it is, who its with and what it is.

I want a button on the form which when clicked will move the record from the table assetcurrent into another table called asset history.

Any ideas?

View 14 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved