XTab Colun Heading Date Sorting

Oct 7, 2007

I have a cross tab query for which I want to display the dayes in mmm-yy format. I am grappling with the problem that this is essentially a string, so gets sorted alphanumerically.

Having read around related forums I have tried basing the XTab on a select query, which is sorted by the conventialal date, but also has another field that gives a date using Format([DateAdded],"mmm-yy").

Trouble is, Access only lets me bring across 1 column heading, so I must sort on the column I display, and this doesn't solve the problem.

The coulmn headings are not be fixed (i.e. "Jan";"Feb" etc) as the months are financial year months (April - March).

I can get this too work by using yyyy/mm, but my board of directors are not happy with this format.

Any ideas. I would be open to re-querying my Xtab from another query of from a report if that worked.

Cheers

Mike

View Replies


ADVERTISEMENT

Form Laout - Matrix (row Heading, Colum Heading)

Oct 23, 2006

Hi all, this is my first post.


i have created a simple access database for keeping student and attendance record.

student table fileds are:

studentId - primary key
forname
surename
dob
gender
accademic year

attendance table fields:

studentid - primary key
date - primary key
attendance (yes/no boolean field)
paid (yes/no boolean filed)

this database is just ment to keep records of students attending at particualr dates.

for example if attendance table cotain records like:

http://www.crazyanime.pwp.blueyonder.co.uk/table.JPG

for the form layout, what i want to do is

http://www.crazyanime.pwp.blueyonder.co.uk/form.JPG

i want this to be editable. how would i do this using access form, or do i have to wrtite VBA code

PLUS i want the form to automatially have new records when i add for example a student, with ID 10011 OR if i add new records for a different date say 11/11/2006, then i want that to be viewd on the form just like the 21/09/2006 and the 04/11/2006.

please help :) been looking for a solution for long time.

thanks

View 4 Replies View Related

Getting The Actual Date From A Crosstab Column Heading

Aug 23, 2005

Hi,

I have a crosstab query that groups by week to obtain columns for monday to sunday. Is there a way to obtain the actual dates that these columns represent?

Any help would be much appreciated.

View 1 Replies View Related

Queries :: Change Column Headings In Xtab Query

Feb 3, 2014

I have inherited an Access 2003 database and have been asked to improve the functionality of said database. Specifically, I have been asked to create some charts for improved reporting. I used the wizard to create a crosstab query to support the chart(s):

Code:

PARAMETERS [Forms]![Switchboard]![ActualDate] DateTime;
TRANSFORM Sum(qryPMCompletion.CountOfWOs) AS SumOfCountOfWOs
SELECT qryPMCompletion.PA_Priority
FROM qryPMCompletion
GROUP BY qryPMCompletion.PA_Priority
PIVOT qryPMCompletion.wo_Completed
WITH OWNERACCESS OPTION;

Now what has happened is that the wo_Completed is a Yes/No field so my column headings and therefore my legend comes up as "-1" and "0" instead of "Closed" and "Open".

Is there anyway to change the name of the column headings or shall I just create my own legend?

View 1 Replies View Related

Sorting By Date

Oct 7, 2005

I have the data below in a query in Access, and I want it to sort by the Week Begin date.
I have put a sort on for 'Ascending' but it doesn't work. (Due to the 29th being after the 28th - regardless of month)

Is there any way I can force the sort in this query ?
It must be in the same query though, as I could probably do it by using this query in another one then sorting that. However, I don't want to do that for reasons I won't bore you with.

WeekBegin Count
05/09/05 137
12/09/05 90
19/09/05 22
26/09/05 55
29/08/05 122

PS - I should mention that I think it is because the WekBegin date is an expression based on an actual date field. Therefore I believe it's treating it as some sort of text field.

Any help would be appreciated.

Thanks.

J.

View 2 Replies View Related

Sorting By Date

Sep 9, 2006

Hi,

I've just started playing with Access 2002 (Office XP) and I@m having a little bit of trouble.

I'm using the Query Wizard to summarise my database giving me average values for each month. When the query is first run it displays in the correct month order: April, May, June, July, August, September. But viewing the query again or when trying to graph the data in a Form, the sorting forces alphabetical order: April, August, July, June, May, September.

How can I get the query/form to return the results in true month order?

Here's the SQL info which the Wizard created:

SELECT DISTINCTROW Format$([Raw Data].[TimeStamp],'mmmm yyyy') AS [TimeStamp By Month], Avg([Raw Data].[Indoor Temperature]) AS [Avg Of Indoor Temperature], Min([Raw Data].[Indoor Temperature]) AS [Min Of Indoor Temperature], Max([Raw Data].[Indoor Temperature]) AS [Max Of Indoor Temperature]
FROM [Raw Data]
GROUP BY Format$([Raw Data].[TimeStamp],'mmmm yyyy'), Year([Raw Data].[TimeStamp])*12+DatePart('m',[Raw Data].[TimeStamp])-1;



Thanks in advance for your help.

David

View 1 Replies View Related

Sorting By Date

Feb 28, 2005

I have a subform that simulates a listbox and I click on the header label to activate the sort. My problem is sorting by date. Below is the sort function and one of the date labels that I need to sort on.

Sort Function:Code:
==========================================
Private Function SortOrder(col As String, xorder As String) As Integer
Dim strSQL As String
Dim sf As Form
Set sf = Forms!frmMainEntry!fctlNotifications.Form
strSQL = "SELECT DISTINCTROW ProgramID, ProgramDescription, Facility, ResponsibleParty, DueDate, FrequencyOfService, AdvancedNoticeDate "
strSQL = strSQL & "FROM qryProgramList "
strSQL = strSQL & "ORDER BY " & col & " " & xorder
sf.RecordSource = strSQL
sf.Form.Requery
End Function
==========================================

On-Click Date:Code:
==========================================
Private Sub lblDueDate_Click()
Dim response As Integer
If Me.txtSortOrder = "DESC" Then
response = SortOrder(CDate(DueDate), "asc")
Me.txtSortOrder = "asc"
Else
response = SortOrder(CDate(DueDate), "DESC")
Me.txtSortOrder = "DESC"
End If
End Sub
==========================================
I'm not sure if I should convert the date into something that can be sorted or just leave it as a date. I can't get it to work. Help please.

Thanks,
PC

View 14 Replies View Related

Sorting By Date

Apr 2, 2006

help w/sorting two columns one with date checked out, other with date due back. some are overdue and there is not a date entered yet. need to sort by the longest overdue first and leave out those that have already been returned

View 3 Replies View Related

Sorting By Date And Time

Apr 28, 2005

Hello,

I am having some trouble sorting my date and times. I have them both working great individually with RunCommand Sort Ascending after Update. The problem is, the dates will get jumbled up after the time is sorted. Is there a way to connect the two fields where the dates will always stay in order? I have attached a pic of this DB if it helps any. Thanks so much for any help.

Fritz

View 3 Replies View Related

Sorting A Date Field

Jul 4, 2005

i have a date field where about 80% of the data is entered in the format dd/mm/yyyy but the rest may be year only since the exact date is not known. Therefore, it does not have an input mask or a format set. Is it still possible to sort on that field? (As i write this i realise it is probably a dumb question but always worth a shot!)

View 3 Replies View Related

Sorting By The Most Current Date.

Jul 13, 2006

Hey all,

I have what is probably a simple question.
I want to sort my date field in a query by the most recent date.
When I use ascending or descending it looks at the Month/day/year to sort it.
I need it to look at year/day/month.

Any help would be awesome.

View 1 Replies View Related

Sorting Query By Date & Employee Name

Apr 3, 2007

I created a query which at first was simply to run a query which asks you for a drivers name, however we have decided that now we want to sort by the employee name as well as by a specified date range. I originaly had it set up to select the driver name with this in the criteria field in the Driver Name column:

[Enter Driver Name]

Then I tried to enter the following in to the criteria field in the date column:

Between [Enter Start Date: (Format MM-DD-YY)] And [Enter End Date: (Format MM-DD-YY]


However when I run the query it asks me for the date about 4 times, and then it goes to a blank report. I am sure I am not doing this properly somehow, anyone care to help out?

View 1 Replies View Related

Reports :: Sorting By Date In Query For A Report

Jul 27, 2014

I have a query where I ORDER BY ClientId, MatterId and Transdate. The result of the query is correct. All of the transdates are in ASC order within the Matter.

When I run the report for a MatterId the relative transactions are not sorted on transdate

Can there be something in the report that could be effecting the order of the transactions.

View 3 Replies View Related

Queries :: Sorting Date From DateTime Field

Jan 27, 2015

I have a field on a table that is a DateTime format and it needs to be that way. I am trying to query that table for all the dates to use in a combobox but I only wat the date not the time. The problem is when I format the field to just date I can't sort it anymore as a date and I can't group them. I still get multiple lines in my combobox because there multiple times for the same day. what is the proper way in a query to extract just the date from a field and still sort it as date ie 1/12/2015 is greater than 12/15/2014?

View 8 Replies View Related

Forms :: Sorting (DATE) Field In A Subform?

Feb 21, 2014

I have a subform which tracks all the notes our personnel have entered in a specific project (which is the main form).

The issue is that I want the most current note to show in the subform when the project is "opened up". The underlying query for the subform has the [DATE] field sorted on "Descending".

View 2 Replies View Related

Sorting A Table, Apply The Sorting To A Form

Mar 10, 2006

Hi all.
I've created a database which contains information about stores. I want to have the forms automaticly sorted by the department number.
I've tried to sort the table by department, but when I try to add a department, the sorting doesn't seem to affect the form at all.

Lets say I have department 1,2,3,6,7,8 in the form, and I add department 4, it will be the last post in the form. I want it to be the fourth, and so on..

I'd apreciate some help with this :) Thanks

Here's the database (http://www.access-programmers.co.uk/forums/attachment.php?attachmentid=12934&stc=1&d=1142018915&PHPSESSID=f730b7f11f6983965698faeacbe5a1ee)

View 5 Replies View Related

Am I Heading For Trouble? I've Never Had So Many One-to-one Before...

Jan 17, 2008

I have been asked to redesign a database that tracks a huge number of data points. These are projects and the original table had over 100 fields. I have managed to separate them to related tables in an attempt at normalization. They are:

tbl_workorders (main project info)
tbl_services (services ordered)
tbl_contacts (internal company contacts)
tbl_customers (customer information)
tbl_project_dates (milestones of project)

Now this is different from other databases I've designed because all of the tables need a one-to-one relationship with the main table (tbl_workorders).

Am I heading for trouble with so many tables existing in a one-to-one? Also, The table tbl_workorders has its primary key as an autonumber. I want any new order on this to create matching foreign keys on all the other tables...I assume this should be handled since I have enforced referential integrity with cascade on update/delete for all the other tables.

Thanks for your feedback!

View 12 Replies View Related

Force ROW Heading In A Crosstab

Dec 7, 2005

Being an amateur at Access, I've only recently realized that you can force column headings for crosstab queries, by typing those headings into the properties of the field selected as the column. But can you do the same for ROWS?

My data concerns patients of a specific type and the times of day they show up at our A&E (ER). I've grouped these by hour and now I want to crosstab them by day of week. But if there aren't any between say 3am and 5am, those hours don't show in the query, which is screwing up a pre-formatted report I have.

I've found some assistance on other threads.....
http://www.access-programmers.co.uk/forums/showthread.php?t=92471
http://www.access-programmers.co.uk/forums/showthread.php?t=83820
.....but to be honest I didn't really follow it.

Is there an easy solution? If not, it's not a huge problem and I can "fudge" it once a month, offensive as that must sound to you professional types!

Thanks as always.

Pat

View 3 Replies View Related

Query Problem: Text With Heading Row

Feb 20, 2006

Excel sheets:
Item Item Desc Price Price Out Date
11040 MIRR SHUTTERED 38.5 69.99
P.O. # Status
52334 280
53074 280
53075 280
11041 MIRR SHUTTERED 38.5 69.99
P.O. # Status
52334 280
53074 280
53075 280

And I want to make it like:

11040 MIRR SHUTTERED 38.5 69.99 52334 280
11040 MIRR SHUTTERED 38.5 69.99 53074 280

View 2 Replies View Related

Modules & VBA :: Place Heading In First Or Second Row In Word Doc

Sep 30, 2013

I have below vba code in a sub that opens word application and generates the data from a table based on criteria provided thru a form.

These lines are smoothly working..

But I need to place some headings in first line or second line of the document and then to start the table information to appear in the doc.

I tried to place my company name below way (see bold lines);

Dim db As DAO.Database
Dim rs As DAO.Recordset
Dim I As Integer

Set db = CurrentDb()
Set rs = db.OpenRecordset("SELECT * FROM T_CustomerMaster WHERE SALESMANCODE='" & Forms!F_ReportMaster!TxtRepCode & "' order by custcode;")

WordSetup

doc.Tables.Add Range:=doc.Range, numrows:=1, numcolumns:=5
'Trying to place main heading
'doc.Range(1, 0).Text = "fsdafds"

[Code] ....

But the table starting from column 1 and cell 1 till data ends up.

Finally I converted my trial lines to remark as it is not working at all.

View 8 Replies View Related

Forms :: Purpose Of The Heading Over The Controls

Jan 20, 2014

When using the Forms wizard for a tabular form, is there ANY purpose for the Heading of the Forms to be OVER the Field headings?

I find it annoying, but maybe it is because I don't understand WHY I have to resize it every time, before I can use my field headings on the form

View 5 Replies View Related

Renaming Crosstab Column Heading?

Mar 23, 2013

I have a cross tab query which give result like this

Date No. BoxItem1 BoxItem2 Item1 Item2
1-2-12 1 15 15 10 15
1-2-12 2 10 10
1-2-12 1 15 15
1-2-12 1 10 5 5 1

I need to BoxItem1 come after item1 and also col heading only box.Is it possible or not?

View 1 Replies View Related

Not Able To Add More Column Heading In Cross Tab Query. Its Urgent Plz Help...

Feb 7, 2006

Hi,

Not able to add more column heading in cross tab query.
I tried to change the query properties to add more column headings as given below.
In the query's Design view, right-click up in the area where your tables are shown and choose "Properties" from the right-click menu. The 3rd line down is for Column names. Enter what you need there.

Evn after doing it. i am not able to .
Whn I try to save or view the datasheet it says. to create a crosstab query u need to have one or more row headin one column headin and one value.

please help. its ver urgent.
thanks in adv..

View 1 Replies View Related

Modules & VBA :: Rename Table To First Column Heading

Feb 25, 2015

I am importing different excel sheets into Access dB using a file dialog. The importing works fine however, I would like to rename the tables once they are imported to the name of the first column heading. Where exactly would I ad the name change at in this code?

#' Open the EXCEL file and read the worksheet names into a collection
Set colWorksheets = New Collection
Set objWorkbook = objExcel.Workbooks.Open(StrFileName, , blnReadOnly, , _
strPassword)
For lngCount = 1 To objWorkbook.Worksheets.Count
colWorksheets.Add objWorkbook.Worksheets(lngCount).Name

[Code] .....

View 2 Replies View Related

Reports :: Unbound Control In Form Heading

Apr 2, 2013

I have a report that starts with an unbound form [Form1] which I need for the parameter inputs. Date1, Date2 and BillingMonth, all three are unbound controls. Date1 and Date2 are the criteria for the dates of billing and they work fine, that is, the query looks them up and the query runs fine. But I want to use the unbound control of BillingMonth to populate an unbound control in the report heading.

The control source is set as =[Forms]![Form1].[BillingMonth]; it works fine if the underlying [Form1] is still open. There is a command button on [Form1] that opens the report and then closes [Form1] since it is a pop-up form that is only used to get the criteria for the underling query; I don't want it to remain open when I run the report. However, the [BillingMonth] does not appear on the report heading. Just #Name?, which I assume means that since [Form1] is no longer open, it can't find the control [BillingMonth].

So, how can I get the [BillingMonth] to appear on the report heading?

View 3 Replies View Related

Reports :: Deleting Column And Its Associated Heading In A Report

Sep 10, 2014

I am coming back to an Access 2007 database that I put together some time ago. I need to simply delete a column and its associated heading in a report and I can't remember how to do it!!

I have attached a few screen shots.

001.jpg is of the actual report and 002.jpg is what the report looks like in Design view. If I try to use Layout view it displays the message "Layout View is Unavailable for this report".

View 14 Replies View Related







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