If date = sunday in one field, place a 1 in another field

jeh

Active Member
Joined
Apr 27, 2002
Messages
250
Hi Everyone,

I need some help. I have a table with three fields; Temp(Text). Date(Date mmddyy). LLH(Nothing yet).
What I need is for the field.LLH to be 1 in every date that = sunday in the Date field.

Thanks for the help, and if anyone can help me, please break it down in hardcore newbie language,

Thanks for your time,

Jim
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
It is best not to store calculated fields but to create them as needed so rather than storing them in the table you should calculate them in a query.

Also it is not a good idea to call a field "Date" as it is also the name of an inbuilt function and Access can get confused. It is better to call it something like dDate or OrderDate.
To create your LLH field you can use the WeekDay() function in a query. Add a new column and in the Field row add something like
LLH:IIf(Weekday([dDate])=1,1,"")
where dDate is the name of your date field

HTH

Peter
 
Upvote 0
Re: If date = sunday in one field, place a 1 in another fiel

Thanks Peter, Worked perfect!

Jim
 
Upvote 0

Forum statistics

Threads
1,221,564
Messages
6,160,513
Members
451,655
Latest member
rugubara

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