Months In Date Order On Query

Nov 29, 2005

I have a combo box that contains the months. They appear in month order on the form but when I query, they are in alphabetical. How can I get this to be in month order on the query?

View Replies


ADVERTISEMENT

Date Order For Months On Query Results

Nov 30, 2005

I have a combo box that contains the months. They appear in month order on the form but when I query, they are in alphabetical. How can I get this to be in month order on the query?

View 2 Replies View Related

Queries :: Date Criteria - Query Previous 12 Months Including Months With No Data

Mar 22, 2013

I currently have a form where users can enter an "End Date", click a button, and it queries the data from 12 months prior to "End Date" entered.

Is there a way to force the query to show all 12 months, even if there are no records for a particular month? For example: if the user enters February 2013 in the date field, I would like the query to return:

March 2012
April 2012
May 2012
June 2012
July 2012
August 2012
September 2012
October 2012
November 2012
December 2012
January 2013
February 2013

...so even if June 2012 has no records, it is included in the query with a value of zero.

This is what I have so far:

WHERE (((Qry_Tbl_Assets.Dte) Between DateAdd("m",-12,[Forms]![Main_screen]![End_Date]) And [Forms]![Main_screen]![End_Date]))

View 2 Replies View Related

Help With Query (make The Months Go In Order)

Dec 12, 2006

I have a little problem

I have an access database containing the following

LibraryYearMonthVisits
Lenzie1999Dec1095
Lenzie1999Feb789
Lenzie1999Mar1293
Lenzie1999Apr1526
Lenzie1999May1231
Lenzie1999Jun1171
Lenzie1999Jul1206
Lenzie1999Aug1287
Lenzie1999Sep1206
Lenzie1999Jan1451
Lenzie1999Nov1706
Lenzie1999Oct1414
Lenzie2000Oct956
Lenzie2000Jan1113
Lenzie2000Feb858
Lenzie2000Mar1110
Lenzie2000Apr1198
Lenzie2000May1203
Lenzie2000Jun1105
Lenzie2000Jul1152
Lenzie2000Aug916
Lenzie2000Sep985

As you can see the months are in order alphabetically. How can I fix my query so the months can be in the right order. Jan,Feb,Mar etc?

I imagine it is a simple procedure but I am not sure how. PLEASE HELP :confused:

Derek

View 3 Replies View Related

Months Of The Year In Chronological Order

Sep 9, 2005

Hello All

Does any know how to index months of the year in chronological order, such as

Jan
Feb
Mar

Etc.

Regards
Terence
Nairobi

View 14 Replies View Related

Subtracting Months From A Date In Query

May 30, 2006

I have a field called DATE_END_DEERS which is in a format of YYYYMMDD (20060530). I need to run a query that shows 6 months subtracted from this date. I can never get an answer that is even close. Can someone please help? ACCESS2000.

View 3 Replies View Related

Date Query - Subtracting Months

Apr 10, 2008

Hello Everyone,I have a query where I am trying to pull records where the user took a class that is 2.5 years old or newer based on their license expiration date. Can someone tell me what I'm missing/doing wrong?SELECT tblCE_Details.LIC_NUMBER, tblCE_Details.Course_Code, tblCE_Details.Course_Date, sociwork1.expirat_dtFROM Sociwork1 INNER JOIN tblCE_Details ON Sociwork1.LIC_NUMBER = tblCE_Details.LIC_NUMBERWHERE (tblCE_Details.LIC_NUMBER = Forms![SW form]!SLIC_NUMBER) AND tblCE_Details.Course_Date >= (sociwork1.expirat_dt - Month(30))ORDER BY tblCE_Details.Course_Date;Thanks,Crhodus

View 3 Replies View Related

Query For Last Order Date

Oct 19, 2005

I have tried posting this message before, but with no results. I am trying to get a query that will give me all of my customers and show what their last order date is. The query that I have now is coming back with ALL the dates the customers made purchases. Here is how I have the query set up:
Field1 Customer ID
Field 2 Customer name
Field 3 Address
Field 4 State
Field 5 Phone #
Field 6 Order Date (Last in Group by)
Field 7 Shipping Method
Field 8 Salesman name

The query is a select query and I hit the totals button on the toolbar. In Field 6-Order date, I have it grouped by "last".
Another problem that I have it I am working in a 97 access database. I have tried to convert it to 2003 with no success. So, I am not able to make NEW queries or reports. I can modify them, but when I close the query or report design, it does not save.

Can anyone help me with this query problem? It is very perplexing.

View 9 Replies View Related

Queries :: Date Order In A Query

Jun 24, 2013

I have started a table to manage expenditure with dates payments and headings. Set up a query to summarise the monthly amounts by each heading. The Query is sorting the date in date in alpha order not date order so I get February before March etc. How do I get it to show chronological order?

View 3 Replies View Related

Modules & VBA :: Find Date Which Is 6 Months Back From Today Date

Jan 27, 2015

I want to find out the last 6 months date from todays date. So as todays date is 27th january 2015 so the code should give me the date which is 6 months back from todays date so it will be something like 27th July 2014.

View 1 Replies View Related

Calculating A Date Six Months In Advance Of A Date

Jan 20, 2005

Not sure if this is actually done with a query (hell, im not sure if it can be done) as my Access knowledge is limited but I've got a list of Patient Appointment Dates and I need to calculate a list of 'Next Appointment' dates that are six months on from the appointment dates not including saturdays and sundays (as the health center is closed those days)

BTW this is for coursework, I don't really work for a health center :S

edit: I seem to have put this in the tables forum, not the queries forum. Apologies for that, I'm not an Idiot, Honest!

View 1 Replies View Related

Date Criteria, Data From Last 6 Months

Jul 1, 2005

Im looking for something that filters information for 6 months prior to any current, non-specific date. Like it will automatically get the data dated from 6 months ago from june, july, or august, without anyone having to go in an change the date criteria.

Below is a non working example of what I am trying to come up with. If I could get something like this, it would save me a ton of time going back and updating all the date criteria for my databases.

Forgot to post it:

>=Now()-Day(180)

View 1 Replies View Related

Display Date On Form 6 Months Ago

Sep 6, 2005

If I key in to the control source of a text box "=Date()-184" I will get the date 6 months ago but if I tried the same of 06/10/05 I will lose a day because of the 30/31 day months. Does anybody know another way around this?

View 6 Replies View Related

Queries :: All Records With 12 Months Of Date?

Aug 6, 2014

We have a field (tbl_Enrolment.CourseCompletedOn) which holds the date a colleague completed a course. I want to bring through all courses completed within 12 months of todays date ( Date() ) from our database. I checked google and it suggested YEAR but that would only bring through dates with the same year, not within a 12 month period.

View 4 Replies View Related

Calculating Age In Years And Months From Date Of Birth

Jan 19, 2006

I have a Date of Birth field in format DD/MM/YYYY and wish to set up 2 new fields one that calculates Age in Years and another that calculates Age in Months.

Thanks

View 14 Replies View Related

Rolling A Date Back 12 Months Question

Mar 14, 2006

I have a query that takes a date from a selection form. Is there a way to window my data by taking this date and going back 12 months to give me a block of data covering this 12 month window.

Example:
Date entered is 03/dd/06
Date window desired is 04/01/05 thru 03/14/06

View 3 Replies View Related

Adding X Months To A Date In Criteria Expression

Sep 4, 2006

Hi all,

I need to be able to add x months to a given date which I'm using in a criteria expression. I've figured out that I can just add y number of days, but the answers aren't quite accurate across different ranges of months.

I'm after something like
<[BeginDate] And >([BeginDate]+[3months])

but I haven't turned up anything useful in an hour of googling - finding it difficult to define what I want in search engine terms.

Cheers,
Alex

View 2 Replies View Related

Date Difference In Years, Months, Days

Jan 14, 2007

Hello,

I have two fields in a table, both containing dates. I would like to write a query that returns the difference between the dates in an year, month, day format (i.e. 26y 2m 3d). If that isnt possible, can the difference be returned as years,days (i.e. 26y 63d).

Thankyou.

View 4 Replies View Related

Format Date Yymm Based On Number Of Months.

May 25, 2006

I am importing data to a program that requires the life of an item. This is in months such as 241 months. The valid format for this program is YYMM. 241 = 2001 or 20 years 01 month.

Another example: 16 months should read 0104 or one year 4 months.

Any idea how to convert this to yymm format based on the number of months?

thanks in advance.

View 4 Replies View Related

Queries :: Date Range Calculation Including Partial Months

Aug 28, 2013

Trying to get a formula or function for calculating profit for each month between selected dates. Partial month calculations are required.

Source Data (record) examples:
Contract1: Startdate = 6/30/12; EndDate = 9/22/12; DailyProfit = $500; MonthlyProfit = $9500
Contract2: Startdate = 7/7/15; EndDate = 12/17/12; DailyProfit = $600; MonthlyProfit = $11400
Contract3: StartDate = 8/1/12; EndDate = 6/30/13; DailyProfit = $350; MonthlyProfit = $6650

User Query #1:
Notes:
ReportStartDate will always be entered as the first day of the month;
ReportEndDate will always be entered as the last day of the month
The report will always show 6 consecutive months

User selects
ReportStartDate = 7/1/12;
ReportEndDate = 12/31/12

Notable conditions:
-The calculation for Contract 1 will have a partial month profit calculated for September 2012. The other months can show the MonthlyProfit value, with October and December being $0.
-The calculation for Contract 2 will have a partial month profit calculated for July 2012 and December 2012. The other months can show the MonthlyProfit value.
-The calculation for Contract 3 will have no partial months since the StartDate is on a month beginning, and the ReportEndDate is prior to the EndDate. July 2012 will show $0.

Request: I either need a super complicated IIF statement for 6 fixed columns in a query (one column for each month) or a smart function, neither of which I can do.

View 6 Replies View Related

General :: Populate List Box With Distinct Months From Date Field

Nov 27, 2012

I have a table of data which includes a date field and also various other fields which may or may not be filled with data.I'm trying to populate a listbox with the months for which this data is missing (a separate macro will then loop through these months to fill the missing data) But I only want each distinct month to populate the listbox - not each individual date.

Code:
strSQL = "SELECT DISTINCT month([EntryDate]), year([EntryDate]) FROM [SampleTable] WHERE [ValueField] Is Null"
Me.lstSampleListBox.RowSource = strSQL

I want to return the month in <mmm yyyy> format.

View 2 Replies View Related

Why Aren't My Date Fields In Date Order ??

Sep 20, 2006

Help - Why don’t my date fields sort in date order ?

I’m having a very annoying problem with my date fields. I have a database that keeps records of patients details and their visits to the practioner.

I have a form based on Patients table with name address etc, and a subform based on a Case Details table with details of visits and advice given etc.

I need the Case Details subform to display the latest visit/record at the bottom (the earlier visits at the top of the list). For some reason I just cannot achieve this. Dates seem to be scattered all over and I can’t understand why ??

I have tried sorting the Case Details table in ascending order, sorting the ‘Date of Visit’ field on the form in ascending order (which does work but as soon as the form is closed and re-opened, all the dates are mixed up again).

In the ‘OrderBy’ property of my Case Details Subform, it says:-
[Case Details Table].[Date of Action]
which according the help I have tried to look at should sort the records ??

I’d really appreciate any pointers as to where I’m going wrong

View 4 Replies View Related

&gt; 6 Months Query

Feb 27, 2007

How do I write an expression to pull data greater than six months from a user entered date.

View 3 Replies View Related

Crosstab Query For Last 6 Months

Jun 28, 2005

Is there something I can put into the criteria of a date box to only use the last 6 months. I dont want have have to do this type of criteria: >12/1/2004. I want it to just use information from the last 6 months no matter what the current month is. If anyone knows what I am trying to say, please help me out! Thanks

Bowes

View 4 Replies View Related

ORDER By Date (SQL)

Sep 14, 2005

I have a query which i've ordered by date with:

ORDER BY status_reports.date;

But I want it to display in reverse order with most recent date first for example i want it in order of 18/sept/05 then 15/sept/05 then 10/sept/05.

im guessing i just need to add to the above SQL but im not sure what!

Can anyone help please

Thanks

View 3 Replies View Related

Date Of Last Order!

May 31, 2005

Hello,

I have a database which in one part records customer orders. What I would like to is identify customers who have not ordered for a given time period i.e. 30 days.

I know once I have built the query, I will require a parameter for the time period i.e.30 days.

I started by trying to record the last date ordered for a customer in a query, but am having problems with this. I had a query including information from my table for Orders (tblOrders). This had:

Order ID
Customer Name
Date Order Required

I do not need any more info apart from these fields.

The results would include all orders, so for some customers there would be numerous 'Order ID' & 'Date Order Required'. In the query, I did try to select the summary option, to group information by Customer - but the 'Date Order Required' was always the first date ordered. What I would like is only the last ones for all customers to be shown.

Can someone provide some guidance on how I can achieve my objective.

Thank you.

View 1 Replies View Related







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