Finding A Minimum Time For A Swimming Event

Feb 21, 2006

I am trying to produce a database that will select a swimmers, best time for each event, and will select the overall best time done by any swimmer in the events.

At the moment I am having some trouble with my queries.

When trying to get the query to select a swimmers best time for the events, It will work when selecting min for the time field and including the following fields:
Forename
Surname
Stroke
Distance
Age group
Gender

However I also wish to include the name of the swimming pool the time was done at and the date at which it was achieved. My problem is that when I add these fields into the query, it looks for the swimmers minimum time in the event, on the date, and at the venue and consequently comes up with all the times the swimmer has done, rather than just the best ones.

I would Really appreciated if anyone had any suggestions as to how I can get over this problem

Thanks in advance

Jennifer

View Replies


ADVERTISEMENT

Quering With Relationships And Finding Only The Last Event

Jun 28, 2005

hi guys, i have a table that stores information about packages

[autonumber],[pack number], [county], [uber number] ( the uber number is made up of the pack number and the county ), etc

and i have a history table so that when anything is done with a package it is recorded in the history.

[autonumber],[uber number],[event],[date],[user]

they are linked by the [uber number] with a one to many relationship so that is shows all the events for a specific pack.

but now i need to create a list of all the packs that are at certain events

but if i just create a query with the packs info and the event number from the history i get all the packs that have been at that state and not just the packs that are at that state.

how can i accomplish this?

best regards

stuart

View 1 Replies View Related

Finding Out The Last Time Data Was Updated

Jan 31, 2006

Hi,

I am using this code below to retrieve the last updated time on the tablea.


lbl_DataLastUpdated.Caption = "Data last updated: - " & Format(CurrentDb.TableDefs("ATM_Info").LastUpdated, "dd/mm/yyyy hh:mm")


This works but the problem i have is, when i add an entry via a form or do anything else via a form. This does not get updated?. I check the properties of the table and that isn't either.

When i then modify something manually in the table (go in and change it). It then updates.

Is there something im doing wrong or is there a better way to check the last updated.

Thanks
k0r54

View 3 Replies View Related

After Finding Records Show Themone At The Time

Mar 5, 2008

Hi All,


I have the following code to run search:
Code:Private Sub Command20_Click() Me.household_id.SetFocus 'Me.Text21.SetFocus 'subj_num = Text21 DoCmd.FindRecord Me.household_id, acEntier, True, acSearchAll, True, acCurrent, TrueEnd Sub
Let's say it found 5 records matching the search criteria.
I like the Access form show me each record every on second. Meaning show me next record every one second.


I have the follwoing code to loop throgh each record but I nned to run after the find code runs and loops throgh the record that have been found:

I have the following code to do the loop through each record but, I need to run it after running the find code and then loops through the records that have been found:

Code:Private Sub Command10_Click()Dim inti As Integer'Loop through record 1 to 20 in form For inti = 1 To 20 DoCmd.OpenForm "DEM_RECH_CHECK_LIST", , , "[household_id]= " & inti Next inti End Sub



I need some help to combine the above codes.

Thanks in advances,

Abrahim

View 9 Replies View Related

Queries :: Finding Records In A Query Where Date / Time Has Been Used?

Aug 15, 2013

I have a database that is used (partially) to enter appointments during a day. In the appointment column I've entered the date and time as dd-mmm-yyy-hh-nn-ss. I'm now trying to search for appointments entered on a specific day through a user input ([Enter Date] in the query criteria) Problem is, this only returns records where the time hasn't been entered and the time shows as 00:00:00.

I've tried CDate which gives me add/mmm/yyy return. if I try to search against that I get nil returns though. As a test I put DATE() in the criteria but it then says that it's an invalid foremat. I've also tried various machinations of "Like" and "Between" without success.

View 5 Replies View Related

Modules & VBA :: DCount Not Finding Records And Returning 0 All The Time

Sep 10, 2013

It is basically a DCount, and it should find records, but returns 0 all the time. My code is:

Code:

Function cntkit(sftd As Date, sftn As String, typid As Integer, specpaint As Boolean) As Integer 'Counts jobs kitted during shift given by sftd and sftn
Dim timeformat As String
timeformat = "#mm/dd/yyyy hh:nn:ss#" 'need this, to convert it to US datetime format
cntkit = DCount("[JOB]", "Archive", "[Type] =" & typid & " And [Autfinish]=False And [SpecPaint] =" & specpaint & " And ([Kit] BETWEEN " & Format(sftstart(sftd, sftn), timeformat) & " AND " & Format(sftstart(sftd, sftn), timeformat) & ")")
End Function

sftstart and sftend are functions which are returning dates. The funcion works fine if I omit the Between part of the criteria. So the problem is in that part.

View 5 Replies View Related

Calulate Time On A Button Event

Jan 24, 2006

Hello All,

I am using a timer function to hopefully calulate have long a call has lasted, I have setup a rolling clock called "ElapsedTime" and i have the start time running off the P.C. Time this is called "txt_Start", this works fine no issues.

Now comes the fun bit i have a button called "cmd_Finish", i wish the time to be calulated and the total time to be placed in a text box called "txt_Finish" sound easy but nope this would apear not to be.

The Following Setup is used:-
ElapsedTime = "00:00:00"
txt_Start = Time(), formated to LongTime
txt_Finish = Formated to Long Time

Example of what i would like to happen
txt_Start = 10:40:02
ElapsedTime = 00:00:11
txt_Finish = 10:40:13

I have tried the following Code:
*********************************************
Private Sub Command5_Click()
Me.txt_Finish = ([ElapsedTime] + [txt_Start])
End Sub
*********************************************

Can anybody help me on this please.

Alastair :eek:

UPDATE
*****************************RESOLVED THANKS TO ALASTAIR69 (ME) & Allan57********************

View 6 Replies View Related

Disable Button - Time Event?

Oct 4, 2007

Hello All,

I was wondering if there is a way to disable a command button after it has been clicked for a small period of time. (lets say 1 second) stopping the user from any happy clicking. (fast repetitive clicks)

This is to do with viewing embedded images, i can explain more if required.

Thanks, Aaron

View 2 Replies View Related

Added Current Time On Click Event

Mar 5, 2008

I have two fields in my form contained Start time and End time. Currently, Both fields using default Time$() on form. However, End time always wrong because until we get our job done, It took atleast 20 or 30 minutes more than current default time. My question is, is there any way I can setup the End time to just click on it, and a new current default time populated?

Thanks in advance..

View 3 Replies View Related

Forms :: Onload Event Doesn't Run All The Time

Aug 16, 2015

I have a form with an onload event that apparently only runs when it wants to. I've checked the onload property on the form and it is set to event procedure. Went through the code on the event and everything looks good. When i mark it in break mode and step through it it runs fine. When I take the marks off it sometimes works and sometimes doesn't.

View 6 Replies View Related

Creating A Timer Event That Checks System Time?

Apr 21, 2005

I need a query run that brings up a list of customers that need maintence after 6 months after their last maintence service. As soon as you open the DB, the event/query runs and if there are any customers past due to display them. And if there are none, to not even show the query at all.

I have very little experience with timers and if/then statements and don't know how to set this up.

Any help would be greatly appreciated. Thanks in advance.

View 1 Replies View Related

Modules & VBA :: Save NOW (Date And Time) Into Event Log File

Oct 16, 2014

I want to save NOW() (i.e. Date and time) into an event log file. But I just cannot work out the syntax. My insert statement works fine without the date field in, but fails on a syntax error (3134) when I include it.

strsqlac = "INSERT INTO EventLog ( EventTime, User, EventType, EventMessage, DocRef, AutoSeq, CoCode ) " & _
" Values ( '" & Now() & "', '" & GlobUser & _
"', '" & Mess2 & _
"', '" & Mess1 & _
"', '" & Docref & _
"', " & AutoSeq & _
", '" & CoCode & _
"' );"

... it's the first column, EventTime that is the issue. I have tried several different ways of wrapping it in the VALUES () without success.

My database field EventTime is defined as a General date which Access 2007 tells me will give me date and time. That's what I want.

The Value formats I have tried (currently showing as 'NOW()' above, are ...

#NOW()#
#'NOW()'=
'#NOW()#'
and (as I say) 'NOW()'

View 5 Replies View Related

Modules & VBA :: Double Click Event In Listbox - Run Time Error 3464

Mar 14, 2014

On double click event in the listbox, code as below:

Code:
Private Sub ListBox_DblClick(Cancel As Integer)
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "frmTransactions"

stLinkCriteria = "[BinNumber] =" & Me![ListBox]
DoCmd.OpenForm stDocName, , , stLinkCriteria
End Sub

When I double click any row then it show Run time error 3464.

View 3 Replies View Related

General :: Populate List Box With Event After Update In Combo Box - Run Time Error 13

Sep 9, 2013

I am trying to populate a list box with an event after update in a combo box. I can get the formula to work using 2 criteria, the problem is i nee to add a third criteria. When I try to add it I get the run-time 13 error.

Here is the code I am trying to use:

Private Sub cboStatusRFQ_AfterUpdate()
Me.cboSupplier.RowSource = "SELECT DISTINCT [Consolidated_Master_Req_Pool.RFQ Contact] " & _
"FROM Consolidated_Master_Req_Pool " & _
"WHERE consolidated_master_req_pool.Complete = FALSE AND [Consolidated_Master_Req_Pool.RFQ Supplier] = '" & Nz(cboStatusRFQ.Value) & "'" And "[cosolidated_master_req_pool.Status] = '" & "[SUPPLIER_RFQ FOLLOW-UP]" & "'" & _
"ORDER BY [Consolidated_Master_Req_Pool.RFQ Contact];"
Me.cboSupplier = Null
End Sub

View 2 Replies View Related

Getting The Minimum Value?

Jan 28, 2005

Hello,

I have a table which has repeated IDs, I want to find the start of the ID then mark it as Y in the next field, the remaining repeated IDs should have blanks in the next field, how do I do this, thanks for any help

View 3 Replies View Related

Minimum Quantity

Aug 9, 2007

hi

i try to build an access form .

i have "big" table that fill in the name of the product , the quantity , and a minimum quantity.

the field : min quantity give us the quantity that is the minimum of the product.

i have a "minimum" table that has the list of the product and the minimum quantity.



i want to see the minimum quantity of a product , when i type the product (in the form if it possiable , if not - in a report)



eran

View 2 Replies View Related

Minimum Values

Jul 8, 2005

I have a counter on my form which will increase or decrease depending on weather a number of tick boxes report true or false. Is it possible to set a minimum aloud value on a box regardless of other criteria. At present I can depending on certail criteria, finish up with a - number which for other reasons, I dont want.

View 14 Replies View Related

Minimum Record Set Must Be One

Mar 6, 2006

Hi All,

I have a main form and 5 tabs within that mainform that are subforms. They are linked by an EventID.

The subforms are continuous forms, but only one record is "required". What kind of code do I need to make sure that the data entry person enters at least one record in each subform.

Also, is there a way that when I am tabbing through my subform and get to the second record and leave it blank, that when I press tab it will take me to the first record of the next tab subform.

I appreciate your responses.

View 2 Replies View Related

Minimum Value For A Report Field

Dec 18, 2006

I have a field in a report that is calculated to generate a dollar amount. Well the people who need this have some strange rules about how they get their dollar amounts. Mostly they just round up to the nearest dollar, which is no problem. But they also want a minimum charge of $2.00. So my problem is if the calculation works out to be 0.01 to 1.00, it will say 1.00 and it is going to be wrong because they will want it to be 2.00. So is there a way to set a minimum value for this field, or where should I go to try this?

View 4 Replies View Related

Minimum Values In A Query

Aug 18, 2005

Hi

I have a table (tbl1) with three fields/columns (Primary key, NameID, Number). E.g.:

NameID ... Number
Mike ........ 2
Mike ........ 3
Mike ........ 19
Ronald ...... 1
Ronald ...... 2
Greg ........ 7
...

I would like to make a query that lists each NameID only ONCE, with corresponding MINIMUN Number. So the result from the upper example would be:

NameID ... Number
Mike ......... 2
Ronald ....... 1
Greg ........ 7


How do I do it???


Thank you in advance

m.

View 8 Replies View Related

Minimum Date With Group By

Oct 26, 2005

I wondered if anyone new how to return the following

Table of Data

ID|ID2|Date
----------------
1 | 1 | 20/01/05
2 | 1 | 21/01/05
3 | 1 | 19/01/05
4 | 2 | 20/01/05
5 | 2 | 25/01/05

I want to return the minimum date grouped by ID2, but with the corresponding ID i.e.

ID|ID2|Date
----------------
3 | 1 | 19/01/05
4 | 2 | 20/01/05

cheers for your help...

View 4 Replies View Related

Return Minimum Value Within Group With ID

Sep 7, 2007

How do I create a query to return just one record, a minimum value for one of the fields, per group within a group that contains an ID field?

This is what my query is returning:
ID, UPC, MinOfAverage Unit Cost
19161, 026851003663, $1.15
15927, 026851003663, $1.11
4459, 026851003663, $1.18
19598, 029695215513, $39.73
15993, 029695215513, $39.29
11694, 029695215513, $48.81

This is what I need:
ID, UPC, MinOfAverage Unit Cost
15927, 026851003663, $1.11
15993, 029695215513, $39.29

I would be *extremely* grateful for an answer. I am new to this list, but I have plenty it MS Access help karma to my name, so I'm hoping to cash some of that that in.

Fingers crossed.

-Tom

View 3 Replies View Related

Minimum From Multiple Tables

May 17, 2013

I have a query that is working, but I am looking to make it faster. We import 13 csv files daily into 13 Access tables. The files have an ItemID and price. We need to get the minimum of the raw data across the 13 tables & then manipulate the prices some (in the query) and get the lowest of the manipulated prices again for the 13 tables for each ItemID - some might be blank. We are using a MinOfList function in the query to get the minimum of the 13 numbers. But this is very time consuming since we have to run the Min function twice (with 13 input parameters) for each ItemID - about 15,000 records. It takes about 1 minute to run the query.

View 2 Replies View Related

Identify And Assign Value To Minimum?

Oct 29, 2012

What I am doing is trying to have access identify and label various lanes of transit.

So, for example. I have the below...

Origin Destination Via Transit Time
Hong Kong New York East Coast 38
Hong Kong New York West Coast 32
China New York East Coast 34
China New York West Coast 29

Is there a way in Access to have it identify that Hong Kong to NY via West Coast is the "DEFAULT" where HKG to NY via East Coast would be "ALTERNATE" ?? And then do the same for the next origin? The table I have now has over 71 different origins but I need it look at each origin independently.

View 2 Replies View Related

Enforce Minimum Record Count

Jun 1, 2007

Does anyone have a good technique for enforcing a minimum number of records in a table?

I am attempting to ensure that in a table of Roles, there be a minimum of two Roles defined as Technicians. The field which identifies a Role as Technician is a Boolean.

I wrote a Function which does a domain lookup to count the number of Roles defined as Technician and am calling it from the BeforeUpdate event.

However, if there are 2 Technician Roles, and I mark a third Role as Technician, change my mind and try to unmark it...of course the Function can still see just the 2 existing.

I realize I can Undo the edit, but a user may not.

Thanks for any help.

View 4 Replies View Related

Chart Changing Scale Minimum.

Aug 23, 2007

Hi all,

I´ve had this problem for a while but it only just recently became very annoying.

I have a chart on a form displaying data over time. I´m using two comboboxes to select start date and end date. There are A LOT of data in the underlying query. However the problem does not seem to be related to that.

When I select the starting date to be before a certain date, the chart suddenly sets its own minimum to 0 so that the line in the chart becomes almost flat (since the data reaches from maybe 20 to mayb 25).

This has to be a common problem, but is there a good solution?

I´ve checked the data so there´s no problem there.

Thanks in advance!


Fuga.

View 4 Replies View Related







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