insert query

cahickm2

Board Regular
Joined
May 14, 2007
Messages
101
I need help with a query that inserts a date from above into blank cells in the same cloumn.

ex.
Date,Time
23/07/07, 00:00
blank
blank
blank
blank
blank
23/07/07, 01:00
blank
blank
blank
blank
blank

and so on.

The data I am working with covers and entire week (168 hours) and it is time consuming to copy and paste. Can someone help me please?
 

Excel Facts

Repeat Last Command
Pressing F4 adds dollar signs when editing a formula. When not editing, F4 repeats last command.
this query assumes that you have a autonumber field (ID in my example)

Code:
UPDATE tblA SET tblA.Field1 = DMax("field1","tblA","tblA.ID <= " & [tbla].[id])
WHERE (((tblA.Field1) Is Null))
order by ID;

replace tblA with your table name, and field1 with your field name
 
Upvote 0

Forum statistics

Threads
1,214,812
Messages
6,121,696
Members
449,048
Latest member
81jamesacct

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top