473,395 Members | 1,437 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Need to update a value for a field depending on Month number

Hi

I am trying to find a solution to the problem I wish to be able to update a particular fields depending on the value =month(date()). I wish user to input hours worked that month on future months depending on value in form. My boss only wants the data to start from todays Month fand dat entred for next three months, so if june we update Month6, Month7, Month8. I know could use a case statement but ther must be a more elegant solution which would append the month no to "[Month]" to update the correct filed
Jun 28 '13 #1
1 985
Seth Schrock
2,965 Expert 2GB
It sounds like you are suffering from a lack of database normalization. Here is a link that will help you design your tables so that your problem will disappear: Database Normalization and Table Structures. The specific problem that I see with your design is that you have a separate field for each month. These need to be combined into one field. A query can then be used to view the data separately or just to add up the hours for a specific month.
Jun 28 '13 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

10
by: Colleyville Alan | last post by:
I am trying to turn a short and fat (63 columns) table into one that is tall and skinny (7 columns). Basically, I am trying to create a "reverse crosstab" using a looping structure in VBA along...
1
by: N. Graves | last post by:
Hello I'm getting stumped and this is probably Access 101 but here goes. I have a list of To_do's When I click on a checkbox "Complete" I want automation to update a field called "Completed...
2
by: Dejan Pujic | last post by:
Hello, I'm having difficulty figuring out how to update values in a certain column, where the new information depends on the previous. Here's a further description: The whole database is for...
4
by: ormor | last post by:
Hi friends, I am new to MS Access. I have desiged a Form wherein I would like to update the field based on some calculation derived from the previous fields. How this can be done. I want...
7
by: Colleen | last post by:
Hello All, I have a table for my employee data. I have a field that generates date before update of latest changes made. I also have two fields within called CreatedBy and UpdatedBy. I would...
1
by: comp.lang.php | last post by:
C ould someone please explain this one? This one got me: PHP Code: for ($thisMonth = (int)$minMonth; $thisMonth <= 12; $thisMonth++) { $monthName = date('M', strtotime($thisMonth));...
1
by: Michael McGrew | last post by:
I have a asp form that has a dynamic drop-down box that a user selects a value from. Once the user makes a selection I use the onChange event to capture the selection and pass this value to a...
2
by: CindySue | last post by:
Hello--I've got a query that uses DatePart("m",) to select records for a particular month, and then a report based on that query. I'd like to be able to create a field in the report that says what...
1
by: cedgell | last post by:
Is it possible to create a batch file of a sql script that would allow end user to update a single field of a table? For example, a number field is populated but needs to be updated on a daily basis...
12
by: Be Borth | last post by:
I saw previous solutions to convert a month number (1) to a month name (January). I have a database with 200+ dates. In a query, I use the "Part" function DatePart("m",), to extract the month...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.