I've encountered a simple problem. =) I have a report based on a query. Of course due to the relations the query table should affect the report. But it does only with the filter parameters I put in the Query Design View, the quick ones ("filter by selection", etc.) that are in the result table view work there but doesn't affect the report. Still the query asks me to save it each time I apply any of these quick filters but make no changes at the end.
Any ideas how to make them work in the report? Or these filters are temporal and shouldn't work in that way? If so, what could I do to simplify customer's life?
I have a parameter query for looking up a specific lot number in my database. The lot number table has 4 related material tables that deal with material issued, reworked, and rejected for that lot number. They lot number table is in a one to many relationship with the related tables.
I have a report based on this parameter query with 4 subreports. I want the report to display the lot number data and sub reports to display the related data in the material tables (all linked by the lot number defined in the parameter)
I want to know if I change the menu bar in an Access db (such as take out every thing, edit, view, format, tools, etc. except file and exit) would it remain that way in every other db that was opened on that pc?
I want to restrict access to every tool except file, exit on only one pc (a public pc) and I am afraid to mess around with this in the event I screw something up again like I almost did yesterday...Security on that one pc is all I need, because the program needs to be accessible to managers for reports. This pc is in an out of the way place that allows employees to "play around" in it and I am not sure enough about how to secure it any other way. So, I reasoned that if I could restrict ability to roam on that pc then that is all I would need.
In my database you can search on either number or name. I have therefor, two combo boxes. and it works well, except that...
When I pick by number first, and then try to pick another record using the name combobox, the number combobox still shows the first search I did. I would like the two comboboxes to interact with each other...
How does normalizing affect current queries and forms?I need to normalize a database here at work, the original creator made one BIG table.My concern is how will that normalization affect the current queries and forms I have created based on the current table?I tried the Wizard but that wont do the job I will have to do it manually.Thanks
i've got a report which pulls its data from a query. it pulls these fields:TestCode...Price...HID...Month...etc . . .
There are names of "TestCode" that we don't want to display, is there a way to filter certain "TestCodes" out? if so, how?
Here's my current SQL Code: I have a query which pulls certain records from a table, here is my SQL statement: SELECT [qryGroupByAMCount].[TestCode], [qryGroupByAMCount].[Price], [qryGroupByAMCount].[HID], [qryGroupByAMCount].[Month], [qryGroupByAMCount].[CountOfAutoNumber], IIf([TESTCODE]="PTCGCD",[CountOfAutonumber]*2,IIf([TESTCODE]="LSHABC",[CountofAutonumber]*4,IIf([TESTCODE]="HPVPNL",[CountOfAutonumber]*2,IIf([TESTCODE]="TOXOAB",[CountofAutonumber]*2,[CountofAutonumber])))) AS Extended FROM qryGroupByAMCount
I have a query that has a field that reads DateReceived By Month: Format$([Workorders].[DateReceived],'mmmm yyyy') The criteria line is Like "*" & [Enter Month & Year (Leave Blank for all)] & "*" And this works when I run the query. If I enter october 2013 it shows only records for this date range like it should.
Then I built a bar chart report that will show the workorders only for the month entered. The problem is, If I leave this field in my query the chart does not update . When I open the chart it will prompt for the month and year but the data in the bar chart doesnt change. If I remove this field the chart updates as expected.
If I go into design view for the report and then right click on the chart and go to properties , then to row source, it reads as this:
TRANSFORM Sum([Workorders Query2].MyTime) AS SumOfMyTime SELECT [Workorders Query2].SerialNumber FROM [Workorders Query2] GROUP BY [Workorders Query2].SerialNumber PIVOT [Workorders Query2].[MXDPrinter];
If I click on the elipstical to go into query tools for this line , and click on run I get the error : The microsoft Access database engine does not recognize '[Enter Month & Year (Leave Blank for All)]' as a valid field name or expression.
So my criteria runs normally in the query and returns the correct records, but I can't get it to work in the chart .
The report is bound to a query that has 2 group by fields, 1 count field a a further field, a date field ([Part Date], that I put a default criteria on. This field is not displayed. If I don't put a criteria on this field disappears when I close and open again.
I pass a date to the program via a form and this ultimately ends up in SQLDate. When I run this I get promted to enter [Part Date] even though I'm setting it equal to SQLDate above. I can out garbage to a proper date in here either way the report picks up the default date entered in by the query.
1. Get rid of all of the parameters off the query.
2. Then you can use the Where Clause of the DoCmd.OpenReport code to specify the parameters based on your variables.
1.Not sure what this means but when I get rid of the criteria for the parameter the field disappears (I'm setting the show field to no as I don't want totals group by date). Getting rid of the field gives me all parts used.
2.I think I'm doing this in the above but will bow to superior knowledge!!
or is it I can't pass a parameter to a report run by a query that is grouping fields together to produce a count.
Incidentally once the report has been run (albeit with the wrong parameters) and I go into design mode and look at the property sheet for the report the correct filter is there (i.e., the date that has been input) but it quite clearly ignores this.
I have created an Access 2010 Database for tracking inventory. As parts move to each location, quantities automatically subtract from the previous location. I now realized that some parts are destroyed.
The problem is the if I simply enter a negative value to indicated that a part was destroyed at one location, it appears as a positive value in the previous location. Is there a way to make negative values not affect a specific query?
I want to automate the distribution of individuals Vacation Balance and Usage via email. The data is being pulled from 2 tables related by an Employee ID#. tbl-Employees provides the Header Info for each employee and tbl-VacLog provides the detailed Usage data.
I want the output to appear as follows in the body of the email:
Name Start Date Vac. Bal TotVacToEOY Personal Bal. John Doe 1/1/99 120 160 8
Usage Date Hours Reason Code 1/1/13 8 V 2/15/13 12 V 3/6/13 8 V
I've got a handle on creating the email and sending but where I'm having trouble is in making the link between the two tables with the Employee ID# and printing the corresponding detail data with Parent Record.
Code below...
Option Compare Database Sub SendMails() Dim DB As Database Dim RecordSetA As DAO.Recordset Dim RecordSetB As DAO.Recordset Dim TotalRecordsA As Integer
The ProjRevMRC field is an expression that reads:ProjRevMRC: IIf([ProjRevDate]>=DateSerial(Year(Date()),Month(Date()),1),[CurrentMRC]*[qry303a_ SFADetailMRC_ONLY]![Rev Flow Through],0)
When I run the query, it works perfectly, but when I created a crosstab query to show totals by month, I wanted the totals to be zero for the months less than the current month. Is there a way for the crosstab query to execute the expression and put zeroes for those months?
I have a list of class sessions. To help with maintaining attendance, each session has its own roster. I just need to add a functionality so user can make sure the attendance roster is synchronized with the past sessions and future sessions in events of last minute additions/drop or updating names/contact infos. The sessions are related to themselves as below:
ClassID PreviousClassID 1 Null 2 1 3 2 4 Null 5 4
So therefore to propagate the changes into all sessions how would I instruct the query to look for each related ID then checks if it's also related...
I'm thinking I may have to use VBA to do what, but I hope that can be done with a append query.
I'm building a report for annual software license renewals. The report data source is a query that combines the customer information, their computer information, and the licenses purchased for that computer. I am having no trouble with the form displaying the customer info page, then a page with the computer info at the top and a list of licenses purchased for that computer underneath.
That would be great, if that's what my boss wanted. However, she wants the whole list of available licenses displayed on each page, in the event someone want to purchase additional licenses with this year's renewal.
I'm trying to figure out how I can set up a query/report grouping to do that. I've tried making a new query, relating the qryLicense!licenseID to the qryPurchase!purchLicense and setting the relationship option to show all records from qryLicense and only those related from qryPurchase. I added the qryPurchase!purchCPU field to my query, hidden it, and set the criteria to “=1” (the computer ID of one of my dummy computer records). I also have a Sum of the qryPurchase!purchQty field included in the new query that I want to display the total number of that particular license purchased (and 0 if there are no corresponding records). All fields except for the quantity field are set to Group By.
What I’m getting from this is simply a list of the licenses purchased for that computer, not the complete list of licenses available showing the quantity purchased where applicable.
I want to execute a delete query on a table of account records. The query contains two tables linked on account number, one with a list of unique records, linked to the other with "many" records to be deleted. For each unique record from table A, I want the delete query to delete all records with a matching account number in table B. However, I get a message stating that I "could not delete from the specified table." Huh???
I can manually delete from table B, or I can get the query to work if I don't try using table A as the control table and instead specify literal criteria. I have tried all three join types but still no luck. Any ideas?
I have an access query that I run on a regular basis but that doesn't always sort. It sorts most of the time, but once in a while it won't, which makes it really annoying and impractical.
If I copy paste the SQL from a query (View->SQL) to a macro it doesn't work. Why? I've tried removing quotes,Caps, adding quotes, parenthesis nothing worked. Any ideas?
I created a database that contains 2 tables. I then created a query that simply groups the data and calculates a row total. And it works as expected. However, when I try to create a report, using the query, I get, "The wizard was unable to generate fields from the record source you chose. Perhaps you chose a query that doesn't return any fields."
Hi :confused: I am trying to set up a query. i have to work out the cost of a phone call with the use of three fields-- i have: lenght of call, country call code-e.g england is +44(these are fields in my query) and then the cost per minute values for each country call code(but these are in a table) e.g.Country CodeRegion Cost per minute +1 United States, Canada, Caribbean£0.20 +20Egypt £0.30 +212Morocco £0.30 How would i set up a query to solve this problem?#Can someone please help me???
I have a table which shows telemarketing that has been completed on a weekly basis where the caller places the date they called in one field and a followup date (if needed) into another field if a followup call needs to take place.
I want to create a query which will show me all calls that have got a followup date put inplace but the followup call has not been made.
E.g i call mum on 29/11/06 i put down followup on 30/11/06. I call on the 30/11/06 so the followup has been completed but need to follow up again on the 01/12/06 but i do not complete this one.
Hello, I apologize in advance if there have been lots of questions like this, but the search won't let me use AND as a search term!
I have two related 1 to many tables. The parent table contains clients, and the child table contains categories, each client can have many categories. (i originally intended to have the categories be columns in the client table, in which case what i want to do is easy, however, then it becomes a nightmare when the user wants to add a new category hence the related situation described.)
Is there an easy way to find all the clients who have both category 7 and category 10? I can do it writing a query to find all the 7s, then another to find all the 10s, and a third to find those which have both. I am hoping there is an easier way, as i need to give the user a way to search via categories in whatever combination they fancy. The OR's i can do easily it's the AND's that are causing the problem.
The only idea i have at the moment is to make a temp table with the the clientid, and a long field holding each of the category ids, seperated by commas, and then searching using like "*7*" and like "*10*".
Does anyone have any better ideas, i'm hoping i'm missing something really obvious......
Set rs = db.OpenRecordset("select * from [entered_date] where Date = # " & enter_date & " # ") If Not rs.RecordCount = 0 Then DoCmd.Beep Msgbox "Selected Date's report already been created", vbInformation + vbOKOnly, "Error" Exit Sub End If
rs.Close Set rs = Nothing
suppose,i have one record in the table [entered_date] which matches the user input - enter_date = "08/06/2007",but whne i run the above coding,i get the rs.recordcount = 0. it suppose to be rs.recordcount = 1. can anybody pls help? thanks
Upon closing my frmInventory the amount stock of stock is checked against a minimal stock value. If the stock amount is below a set minimal value a subsequent form is opened telling you that stock is low and an email message is generated to notify a manager. I have a checkbox on that form which is set to "True" upon close using an update query. The checkbox is there to give users the option to either send or not send a reminder message that stock is low when a message has already been sent earlier.
The problem is that using that update query ALL records are set to "sent=true" and not just the 1 record I intend.
This is my code in the "on close" event:
DoCmd.OpenQuery "qryUpdateEmailMinimal_True
and here's the SQL:
UPDATE tblInventory SET tblInventory.emailSentMinimal = True;
I assume what is missing is a reference to an inventoryID number. How do I do that?
I have a query for a subform which is displayed in datasheet mode (see attachment). I've created a form based on a query and used it as a subform. The "casenumbers" per clients are displayed from 1 and upwards, I would like to have them sorted Descending. So in the query I sorted them that way. When I run the query they are displayed in descending order. When I open the subform based on that query however it is not. I can sort descending anyway by clicking the column on which I want to sort and do it that way, but that becomes bothersome and it doesn't need to be that way.
Record source is ok: SELECT KlantNAW.ClientNumber, CaseInfoTable.Casenumber, CaseInfoTable.DateInitialCall, CaseInfoTable.DateCaseCreation, CaseInfoTable.CaseAccepted, CaseInfoTable.[1stAppointmentDate], CaseInfoTable.DateCaseClosed, CaseInfoTable.About1 FROM KlantNAW INNER JOIN CaseInfoTable ON KlantNAW.ClientNumber=CaseInfoTable.ClientNumber;
Order by: Casenumber DESC
I thought, well, lets create a new form based on the query to see if that changes anything, maybe I've changed something I shouldn't have.
But nope, same result.
How can make the form sort descending in datasheet mode?
Hi, I'm a total newbie at Access, and know nothing about scripts. I've been operating at the level of using the Wizards and drop-down menus. I am trying to create a report that does two things: 1. Displays the results of queries that sum data from a table (I think I have this figured) and 2. Displays those sums as a percentage of a number that is input each time the report is run. (This is only one number that comes from a totally different place and has no prior relation to the data.) Any help/advice that anyone could offer would be much appreciated! Thanks!
I have a table of 'things' and two related tables, type and subtype. Each thing has a type and a subtype. The types table contains simply Index (autonumber) and Type (text). The Subtype table Index (autonumber), type (number) and subtype (text), where index and type form the primary key and type is a foreign key to the types table. Thus each type has its own sub-set of subtypes. In the design of the Things table I have set the lookup for Type and Subtype to be a dropdown, but of course the subtype drop-down shows all subtypes, not just valid ones. If I select a subtype that is incorrect for the selected type then of course I get an error, but it would be nice to set the query in the subtype lookup's Row Source to just display the valid subtypes. At the moment it just says "SELECT index, type FROM subtype" How do I put in a WHERE clause that references the Type field for the current row: "SELECT index, type FROM subtype WHERE type=<type selected in current row>"?