Hi all! This is kind of a philosophical question :)
I’m doing some changes to a “CRM”-database, and need to make a function that changes values in several records in one operation. The problem is, I have now idea on how to approach this problem.
One example; I have made a simple invoice function in my db, which works well. But now I send a lot more invoices then when I made the function. I’ve made a form, which prints the invoices, and I can print several in one “operation”. How can I, in the same operation, also change the status of the invoice record so that it says “Printed”?
If you have any suggestions on the method e.t.c.? Thank you! (I'm using Access 2000)
I wan to create a table with a date / time starting at a specific time and then added a number of records with each record being a minute later than the first.
The starting point could be hard coded or by user entry and the loop would run for a certain number of times .....
Any ideas on how to do it ..... poss a macro :confused:
May I know some to construct any functions or query string that can track the no. of records that mean certain criteria in the run time.
Basically I want to track the records in a subform (in datasheet view). Should the no. of records is 0, then I can disallow user from saving it onto the table for better record keeping.
i'm relatively advanced Access user but this problem has got me stumped....i've been given a table that's basically a log of operating rooms with fields designating the date, the room number, "patient in room" time and "patient out of room" time. basically, i want to calculate the turnaround time which is the "patient in room" time" minus the "patient out of room" time from the previous record (if records are sorted in sequential order).
I am pretty new to access and I am trying to reference records by date and time. I don't know how to do it. I am keeping track of aircraft flight time for our Fire Department Helicopter. When the crew gets back from a run they enter the ending Hours or 'HOBBS' time. I've queried the HOBBS to subtract from the previous HOBBS with the following lines:
PrevHobbs: (Select Max(Hobbs) from AircraftRecord Where ([Serial Number] = Aircraft1.[Serial Number] and [Hobbs]< Aircraft1.[Hobbs]))
and
Flight Time: [Hobbs]-[PrevHobbs]
-Aircraft1 is an Alias-
We have more than one helicopter so I needed to pick out the serial number as well. I modified this line from something I found on the internet and it works most of the time. It does not work when the crew gets a call and they don't run up any hours on the helicopter. If they enter the same hobbs time as the last run it will skip the last run and subtract from two runs prior, on account of the "<" in the 'PrevHobbs' line.
I cannot reference a run by the "Run Number" (autonumber) because people will occasionally forget to enter runs and come back days later to enter them. The run numbers are then no longer consecutive. The only thing that consistantly defines a consecutive run is Date and Time.
Any help on this matter would be greatly appreciated. Thank you in advance for your time and effort.
hi all, I have created the database with multiple tables. I've created one main table to store all records from other tables. Then I have make several forms to enter record into several tables. What I'd like to make is that when I enter new record to any one of those other tables, then it will be automitically add to the main table also. The record no of main table will be automatically increase by itself when the new record came in. Can anyone help me with it? thanks.
Hi guys, need your help again with the following problem i'm having. I'll give an example to make the problem clear. I have a table, eg table 1 with the following records: Tag________Desc________Msgno____DateTime 016GB001___Alarm OFF___1403______21/4/06 11:02:02 016GB001___Alarm OFF___1605______21/4/06 11:02:02 034GB005___Alarm ON____1403______21/4/06 11:02:04 016GB001___Alarm ON____1403______21/4/06 11:02:07 016GB001___Alarm ON____1605______21/4/06 11:02:07 048GB001___Alarm OFF___1403______21/4/06 11:05:31 048GB001___Alarm OFF___1605______21/4/06 11:05:32 048GB001___Alarm ON____1403______21/4/06 11:06:51 048GB001___Alarm ON____1605______21/4/06 11:06:52
I need a query that looks at records with similar Tag fields that occur with a 1 second difference between them and deletes those with "1403" in the Msgno field. I'm a newbie and i've got no idea where to start. The query should return the following records: I have a table, eg table 1 with the following records: Tag________Desc________Msgno____DateTime 016GB001___Alarm OFF___1605______21/4/06 11:02:02 034GB005___Alarm ON____1403______21/4/06 11:02:04 016GB001___Alarm ON____1605______21/4/06 11:02:07 048GB001___Alarm OFF___1605______21/4/06 11:05:32 048GB001___Alarm ON____1605______21/4/06 11:06:52
I hope the problem is clear. I know this is going to be one heck of a challenge, and i'm not sure whether this can actually be done in access!! Anyhelp from anybody would be enormously appreciated. Hope to see a solution soon!!
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'm working pro bono on an Access db system for a wildlife hospital. We need to be able to record from the system how many patients (animals) we have every night. We have a form that shows the number of animals in-house as we admit and discharge animals, but I need to be able to record the result of the form's Count() function in a Table whenever we open the "In-house" Form. I want to have a Table showing the time the Form was opened (easy!) and the number of patients then in-house. But recording the Count function always produces 0 of course. I need a function that will record (when the form is opened) the number that the Count() function shows!
I've been struggling with getting a report to simply count records (I don't need any detail other than the counts). Here is what I have:
Table CompressorRoundsT contains these fields (many more actually but these are the ones I care about for this purpose):
Date, Shift, Round
Possible records in the shift field are 1st, 2nd, 3rd and the round field has Rnd 1 and Rnd 2.
For each date, I need to count the number of records per shift and per round. For example, the report should show that on June 7th, 1st shift has 14 records for round 1 and 14 records for round 2. Same for 2nd and 3rd shift. I don't need any other details of what the records contain, just the counts.
I've had some success but the layout ends up too spread out because it is including the individual records instead of just showing the counts and it isn't grouping the way I want.
It's a report for management to see how many readings (rounds) were missed in a period of time.
I'm trying to create an Access database for my college so that our call centre can allocate students to a specific interview time/date. The problem I'm having is that each interview slot must only have a maximum of 10 students at a time.
I'm creating tables for the student details, address and for each interview slot available.
I'm using Access 2010.
How I can limit the number of records in a table to 10 so that when that interview slot is full it informs the user?
I'm using a form with next record and previous record buttons that works fine but as the size of the database has grown it's clear I need a faster way to move through records.
My solution was to have an advance 10 records at a time button but I'm having problems when reaching the far sides of the records.
For example: If I'm on record 9 and I press go back 10 button then access tries to go to record 0 (which doesn't exist) and brings up and error. The same happens if I try to advance more than total number of records.
I found a solution to this which was to disable the button when the recordcount was less than 10. This works except now if I'm on say record 14 and want to go back to 4, i press the button, i goes back to record 10, the button is disabled so it can't go back further and i get an error.
I have a table which has a primary ID and then date/time then an empid field relating to an empid table,
Is it possible to design a query to return all records per empid which exceed 30 minutes for the last 30 days? or even 'today' or a specified date whichever is easiest?
I am currently creating a DB for a Customer Service team so management can keep track of who is skilled in what area, sick days, holidays etc. I have created three tables so far as follows:
EmployeeT with a primary key 'EmployeeID'
SickT with a primary key of 'SickID' and a foreign key of 'EmployeeID' linking to the EmployeeT (Reason behind this is that I may have multiple records for one Employee, meaning I would need a unique identifier)
SkillT with a primary key of 'EmployeeID' linking into the EmployeeT (Only possible to have one skill record linked to one employee)
Set up relationships as follows:
One EmployeeT to one SkillT One EmployeeT to many SickT
I then created a blank form and used Tab Control.
On the first page I was able to populate the page with all the Employee info. On the second page I was able to populate with all the skills relevant to the initial employee.
Then I tried populating sick records relating to the employee on a third page, but that's a no go. I was considering putting a subform on this page, but I wouldn't know where to even start with that.
I have a basic trouble ticket type database that I built. It records troubles and auto fills the date and time when a new records created. I want a simple query that will display the number of calls that each person has taken today.
The problem being that If I use >Date()-1 I will get calls from this time yesterday until now. Is there a way to round down the time to today only? I don't want to lose my time stamp.
I have a MS Access database that tracks when packages are received, returned, etc from different agencies. I need to create a query or report that shows how many packages were received, returned, etc PER MONTH, PER AGENCY. I was able to create a query that listed all the "Date Pkg Rec'd" dates for October (Between #10/1/2004# and #10/31/2004#), but I don't want a listing of all of the dates, rather a total of the records within those timeframes PER AGENCY. For example, APHIS 10, FAS 3, etc.
The other problem I have is I need this done across many columns without excluding those records without an October date (for example) in them. For example, I could have a "Date Pkg Rec'd" date in October, but not an October date listed in the "Date Pkg Returned" column.
Basically, I need the simpliest way to generate monthly "record totals" for several fields.
I have not found the solution to this looking elsewhere, but basically what I am trying to do is the following:
person date 1 1/1/2012 1 12/15/2012 2 6/12/2012 1 6/13/2012 2 6/14/2012 3 6/16/2012
I want a query which shows the count or records for which a person has a date within 30 days of each other. This is being queried from a large table in which records would may not be sequential by person. Thus in my example above, the third record for person 1 would be omitted as well as the record for person 3.
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.
I have a form which uses a loop command to output reports as a PDF. The reports take a bit of time to produce and the record set could contain 100-150 records. Any way that you can split the recordset down into batches. Maybe have a button which creates 1-20 and another 21-40 and so on.
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.