Calculating Distance In Access?
May 3, 2014
Before I design an application in Access, I need to know if a certain task is even possible. I have a table of Physicians containing their names and addresses. What I would like to accomplish is to be able to provide an entry screen that would allow a user to input their zip code and have Access search for the physicians with a
1) 5 mile radius
2) 10 mile radius, etc.
Is this even possible within Access?
View Replies
ADVERTISEMENT
Jun 22, 2007
I am trying to create a query that gives me a cummulative distance based on a previous footages. For example I am prompting the user to enter a Route. Along the route are several points having a numeric value. Each of these points along the route have a footage accociated to the previous point. I want the query to display the Route, each point along the route based on the users defined start and end point, show each backspan footage and provide a cummulative distance based on the progression of the route. Below is what I have created so far. Now I want to add a cummulative distance.
SELECT PED.ROUTE_1, PED.TERMINAL_1, PED.TERMINAL_1, Sum(PED.BACKSPAN_1) AS SumOfBACKSPAN_1
FROM PED
GROUP BY PED.ROUTE_1, PED.TERMINAL_1, PED.TERMINAL_1
HAVING (((PED.ROUTE_1)=[ enter route ]) AND ((PED.TERMINAL_1)>[enter start]) AND ((PED.TERMINAL_1)<[enter end]));
Thanks for any help.
View 2 Replies
View Related
Aug 19, 2007
Dear All:
I have a problem in calculating distance's mileage.Eg: Distance from town A to town B is 10km, town A to town C is 20km and vice versa. I have a table named "Location" as per below:-
Town From , Town To , Distance
A , B , 10km
A , C , 20km
A , D , 30km
B , A , 10km
C , A , 20km
D , A , 30km
My question now is: if there are 26 locations, (Eg: A - Z), then I need to key in the distance one by one and it is very tedious. Because Town A to Town B is 10km and Town B to Town A also 10km.
Is there any method that Access will consider A to B and B to A is same distance?
Can we use crosstab to calculate?? and what is the step?
Pls help & thanks in advanced.
View 2 Replies
View Related
Aug 22, 2006
I would like to have a back-end Database on a host server and link a
front-end Database to the tables several hundred miles away. The problem is I have no experience whatsoever in doing this.
My questions are:
(1) Can tables be linked via the Internet?
(2) If they can, is this the best way to link the tables?
(3) If it is possible to link the tables by the internet or by some other way; how do I do it?
I really would appreciate any help you can give.
Kind regards
Eddie
View 1 Replies
View Related
May 3, 2013
I am using Access 2010 and am developing a form where the user provides a full address - street number, street name, city, province and postal code.
I want a control to calculate the distance from this address and a fixed address.
View 2 Replies
View Related
Sep 28, 2013
However Instead of entering the postal code continually or selecting from the combo box. How do I set zipcode 1 and zipcode 2 based on fields in a form. I would like to use the current FROM (Default zip based on the current job in form) and TO zipcode [Project Postal Code] that is on the form at that time. Not necessarily combo box.
Currently you have
zip1 = Me.Combo2.Value
zip2 = Me.Combo4.Value
I want Zip 1 to be Default zip (however I can still change it if needed) ZipCode field is [Project Postal Code]
Here is the full code:
Private Sub Command6_Click()
Dim zip1 As String, zip2 As String
Dim sResponse As String
Dim sLink As String
On Error GoTo Command6_Click_Error
zip1 = Me.Combo2.Value
[code]....
View 1 Replies
View Related
Mar 8, 2015
I use Access 2003 and want to make a query by specifying the start and finish within the city, I send files. a
Attached file ...
View 1 Replies
View Related
Feb 27, 2007
I am creating a database that basically holds product information. The different fields I have is Supplier, Product Code, Product Description.
For each product I have a product specification in a word document the names of these specifications follow this convention: [Supplier]&[Product Code] e.g. Coca Cola012345
I need a hyperlink to link to the relevant word document, but rather than going through and setting them up one by one I want the hyperlink to be self calculating depending on the information entered in the fields.
I tried typing in the following in the hyperlink address part in the properties:
=[Supplier]&[Product Code]&".doc"
but it seems to read it exactly as I type it in and obviously does not work.
Can anyone suggest a way round this or perhaps a completely different way of doing it which may be more effective???
Thanks in anticipation of your help.
View 9 Replies
View Related
Nov 20, 2007
I am working on a system to store financial information. I will be extracting our accounts payable journal entries on a monthly basis into Excel. I want to import that data into an Access table. I have several calculations to perform to create new datafields that I need to store in my Access table. Is it possible to perform these calculations as I load the data? If so what the best method to do this? Here is an example. I will be downloading our monthly hardware depreciation and need to split it among departments based on % stored in another Access Table.
Thank you for any help you can provide me.
Teresa
View 1 Replies
View Related
May 1, 2007
Hi Everyone,
I have been trying to calculate Percentile through Access 2003. Does anyone know of a code or function that would help me do that ?
Regards
Mandy:D
View 1 Replies
View Related
Feb 28, 2005
Hello MS Access Experts,
I designed a form for my place of business. We do estimates for roofing and construction and the form is really basic in terms of MS Access and it's potential.
But I'd like to modify it to have it make certain calculations. The way I have it setup is... on the left of the form are different fields for. Shingles, Plywood, Metal Drip Edge, so on and so forth.
This is a line pretty much of the entire form: (noted this is only what it shows)
[checkbox] Tear Off [Shingles Text Field] First Layer [# of Sqs. Field] X [FIELD = Per Square] Per Sq. = [Field = Total]
This is the way I would like to set it up.
I dont' know if the check box would complicate things but here is my idea:
If Check - # of Sqs. X Price Per Sq. = Total Price
Then I would also like to have Total Price + All Checked Total Prices = Grand Total.
I don't know if that is too complicated. I don't know anything about MS Access other than adding fields to keep data into the Database. I played with the expressions but I couldn't figure it out.
View 4 Replies
View Related
Aug 8, 2006
I have a query that is looking to calculate staff absence.
Absence Start date & Return to work date
Looking to calculate number of days (not a problem) but to exclude weekends ie saturday and sunday ????
Not sure if this can be done --- any assistance would be greatly received.
thanks and regards
ian watson
Yarm Cleveland UK
View 10 Replies
View Related
Jun 23, 2005
Hi,
I wonder if someone could point me in the right direction with this one....
I need to be able to check at any time which person is working a shift on a specific day, and whether they are working a day or night shift. In effect I have 4 engineers, who work on shifts A B C & D. All the engineers work a 4 on, 4 off shift pattern, so for example if engineer A is working day shift, engineer B will be working nightshift, C & D will be on rest days. The pattern rotates every 4 days, so in the case of engineer A:
1st - days
2nd - days
3rd - days
4th - days
5th - rest
6th - rest
7th - rest
8th - rest
9th - nights
10th - nights
11th - nights
12th - nights
13th - rest
14th - rest
15th - rest
16th - rest
...................and so on.
I need to be able to pull up a form that tells me which engineer is working which shift on a selected date -I hope I've explained myself properly. Can this be calculated 'on the fly' using VBA & a reference table or lookup? I'd prefer to do this by programming if possible.
Hope that someone can help.
Many thanks,
Mark
View 3 Replies
View Related
Jan 21, 2015
I don't use Access too often but I'm trying to connect a table to some business intelligence software I use.
A. Date B. Price C.Ydayprice
01/01/2015 101.45
02/01/2015 104.70
03/01/2015 103.00
Simple stuff. Once I've connected to the table, I can easily do what I want with Field 'Price' and 'Ydayprice'. However, I can't calculate column C. All I want is row 2 to say 101.45, R3 to say 104.7 etc. I've tried various things but I don't have the knowledge to write the action I require. I don't want to calculate the change in Access either.
View 3 Replies
View Related
Jan 24, 2008
Hi, I am a longtime Excel user, and am now migrating some work to Access.
I have 2 fields dealing with dates in the format mm/dd/yyyy hh:mm, OPEN and CLOSE
I'd like to get the difference between the two in hours, but I have no idea how or where to do this in Access. I'm assuming it is put into the queries, but it would be easier if I could just put it in the table.
Here is an example
1/1/2008 1:00 1/2/2008 2:00
I want the result to be "25"
Thanks in advance!
View 9 Replies
View Related
Feb 28, 2008
Hi everyone
I'm a very very new access user so many apologies in advance for when I have no idea what I"m talking about.
I'm working on creating a report that will display multiple expiration dates. Currently I have an employee database, not created by me, that has all of our employees professional licenses listed.
Prof license, auto license, liability, etc.
I want to create a report that will tell me what has already expired or will expire in the next 30 days.
I did use this
Between DateAdd("d",-30,Date()) and Date() and it is bringing back info up to 2009. which isn't what I need. I'm sure I'm doing something wrong here.
I want anything that has expired regardless of the date from today, before today, and 30 days from today but I don't care about anything more than 30 days from today's date.
I noticed that when I looked at the existing database that the fields are set as text fields. I tried to change them to dates and it gave me a "deleting 106" records error message. Yikes!
Any help would be appreciated. I don't really understand expressions and I don't understand if I'm supposed to put the actual date in parentheses or what. Please pardon my ignorance.
Many many thanks.
View 14 Replies
View Related
Feb 19, 2007
I have a table with 2 coloums with nuberin them. I would like to add those 2 number together and display them in a 3rd coloum. I need to automatically change the 3rd coloums value should any others change. Is this possible?
View 4 Replies
View Related
Jan 19, 2007
age: DateDiff("yyyy",[DOB],Now())+Int(Format(Now(),"mmdd")<Format([DOB],"mmdd"))Dob is stored yyyyddmmI thought this above function looks ok. When I run it, I get a data type mismatch in criteria expression.What am I missing?Any help would be appreciated.Thanks
View 6 Replies
View Related
Sep 20, 2005
hi all,
i have a mainform with a subform.
in the subform i have 2 fields: duur and subtotaal
in duur i enter a number.
in subtotaal a calculation has to occur: =20*([duur]/60)
i tried to do this calculation in VBA but then i got the same value on every record in the subform.
But now the problem:
in the mainform i have a control 'totaal' that needs to do a DSum of subtotaal.
And here i am getting into troubles since subtotaal is not stored in the table but calculated.
The formulla for DSum would be:
Me.Parent!totaal = DSum("subtotaal", "tblFacturenDetail", "[FactuurID] = " & Me.Parent!FactuurID)
but as said, subtotaal is not stored.
How should i proceed?
Thanks!
View 2 Replies
View Related
Jan 6, 2005
If I want to work out how old all my patients will be on the 01 Feb 2005 then why doesn't the expression (in a query)
=(01/02/2005 -[tblPatient]![DateOfBirth]))/365.25 work?
How would I get the answer expressed in months?
View 1 Replies
View Related
Jun 28, 2005
I am designing a new database for our life and disability department and they have several different policies where the base life insurance reduces at certain ages.
Please take a look at the scenarios listed below and give me any suggestions and tips on the best way to get this done. If you have any.
Below are the 12 scenarios:
1.) Reduces 75% at Age 70
2.) Age 65 to 70 the life amount is $9,000 and Age 70 and over the life amount is $6,000
3.) Reduces at age 65 by 92%, age 66 by 84.64%, age 67 by 77.869%, age 68 by 71.639%, age 69 by 65.908% and age 70 and over by 40%.
4.) On the day following the 70th birthday, the life amount will reduce to 70%. On the day following the 75th birthday the life amount will reduce to 40% of the 70th birthday reduced amount.
5.) On the Policy Anniversary Date following the 70th birthday - reduces 50%
6.) On the Premium Due Date following the 70th birthday, the life amount will reduce to 70%. On the Premium Due Date following the 75th birthday, life amount will reduce to 40% of the amount of the 70th birthday reduced amt.
7.) Age 65 life amount reduces to 65%. Age 70 life amount reduces to 35%. Age 75 life amount reduces to 25%.
8.) Terminates on the first of the month following the 65th birthday.
9.) Terminates Age 70
10.) Terminates on date of retirement or 1st or month following 70th birthday
11.) Terminates Age 65
12.) Never Reduces
Thanks for your time, Brian
View 2 Replies
View Related
Nov 5, 2006
I have a database containing values in 16 fields. the fields are filled in over a period of three years. I would like to be able to calculate the average of the last four values entered, regardless of when in the cycle the value is required. I have tryed to use quereies but connot find away to assign the four fields to the expression so that it is the last four values and if four don't exist, avearage what values there are.
View 2 Replies
View Related
Dec 21, 2006
Hi,
I am new to Microsoft Access (2002) and the Access Word Forums. I am in need of a way to calculate timespent on six main topics through an 8 hr. working day. If I worked on Topic "A" from 8:00am to 8:15am, I need it to calculate it to 15 minutes. Then I need to figure a way to calculate how much time was spent doing Topic "A" for the working day, then by the workweek, then by the month.
I'm willing to learn, if someone has the time to teach or can direct me to a link that discusses something similar to what I am looking for. Any and all suggestions welcomed. I am looking forward to doing this in a timesheet format if possible.
Thank you,
Marty6
View 2 Replies
View Related
Mar 17, 2008
Hi,
I think this should be simple, but I am struggling to work it out
In a relational database I have a stock table containing stock and quantities, there is a customer table with an order table used as the link table also containing quantities.
What I am trying to do is place an order using an order form linked to the order table, automatically reducing the stock table by the amount ordered.
I have tried an update query with no success, also tried using the builder to make a query and linked it to the stock table with no success.
I would be grateful for any ideas, I am sure it is relatively simple
View 3 Replies
View Related
Jun 15, 2005
Hi Guys,
New to the forum, and its nice to see how active this place is, and upto date.
My question is, and probably simple to correct. ( Please be patient with me, i`m new to this, and my terminology might be incorrect, also please simple answers )
I`ve searched the forums, but as my teminology is wrong I cant find the results im after :)
Anyway, I have a table with many fields in it, but the parts i`m having problems with are as follows.
I have fields with
Price Inc Vat, Deposit Payment, Stage Payment, Balance Payment & Balance Due.,
The part im trying to get to work is the balance due which I want to automatically update, based in the data inputed into price inc vat deposit payment etc.
The calculation i`m after is as followes
Balance Due = ( Total Ammount Inc Vat - Depost Payment - Stage Payment - Balance Payment )
eg, Total Ammount Inc VAt = £2000
Depost paid is £1000
so far balance due would be £1000
Then Final Payment is made 2 weeks later £1000
So balance due would then show £0.00
Is this possible
Thanks in advance
If I have not made myself too clear, please excuse my crapness, and anyhelp Is much appreciated.
If you need any more info, please do not hesitate to contact me on
max.vernon@claddagh-group.com
Thanks in Advance
Max Vernon
[edit]
Just to let you know, I also need these details kept in the table for future reference so I dont think I can use a query to do it.
I`ve attached a copy of the database with some example data in it if this is needed for any assistance.
View 8 Replies
View Related
Jul 17, 2006
I'm suppose to create a list of 20 clients and let 5 accounts be 90 days past due, 5 over 60 days, 5 over 30 days three of each of the accounts have a balance over $75. Then it asks me to create a total of all account balances so that the total amount of recievables can be known. The second part is calculate the number of days each balance has been outstanding.My question is this can you calculate dates in a table or can you only calculate in a query. I'm new at access so have patience with my question(s)
View 3 Replies
View Related