Skip Query Parameter

Dear All
I Have a combo box that is feeding a query parameter to filter some rows. 
sometimes I want to view all records.
the row source for this combo box is a table assigned only for that. and I 
want to add this option to be displayed in the combo box "View All". So I 
will add a new record in that table that will have the value of "View All" 
then the filter will not work. how can i solve it ?
The data type in this combo box is "text". and I have similar case for 
"Date" Data type in text box.
12/10/2007 8:02:01 PM
access 16762 articles. 3 followers. Follow

1 Replies

Similar Articles

[PageSpeed] 54

Dear "M.A.Halim".

"M.A.Halim" wrote:
> I Have a combo box that is feeding a query parameter to filter
> some rows. Sometimes I want to view all records.
> The row source for this combo box is a table assigned only for
> that. And I want to add this option to be displayed in the combo
> box "View All". So I will add a new record in that table that will
> have the value of "View All" then the filter will not work.
> How can i solve it ?

If a value other than "View all" is selected, only records containing
that entry will be displayed, otherwise all records have to be shown.
So when will a record with a certain value in the filter field be
- When that value or "View All" is selected in the combo box.
Therefore, the criteria for the query should be something like this:
Where FilterField = Forms!FormWithComboBox!TheComboBox
   Or Forms!FormWithComboBox!TheComboBox = "View All".
In query design grid, you can add a new calculated column containing
the value of the ComboBox (I guess that you already used that value
as criterion for the field you use to filter the records) and use
the criterion "View All" in a row with the "Or" heading.


12/10/2007 8:51:02 PM

Similar Artilces:

Need help with query summing hours
Tring to get total worked hours and total maintenance hours summary. I have a table with the clock hours WorkID WorkDate WorkEmployeeID WorkHours And have a maintenace table MaintID MaintDate MaintEmployeeID MaintHours Needing help combining the information to get summary something like this.. Date - Employee - Clock Hours - Maintenance Hours 1/1/10 Joe Billy Bob 8 6 1/1/10 Billy Joe Bob 8 7 Whay type of query do I need to build, any help would be great. Thanks -- Message posted via http://www.accessmo...

Linking queries on a report
Hello all, I built a number of queries that all tie to the same table. Each query sorts the data differently, but comes from the same data source. I would like to show the results of these queries on the same report, but I get and error message that the wizard can't connect the queries. How can I display multiple queries on the same report. I've tried subreports, but they don't seem to export as well. Thanks b Brennan What does "export" have to do with this? If I have multiple sets of results I want to show in one place, I create an empty "main"...

min query
Hi, How do I get the 2nd minimum value and the 3rd minimum from a table after I have done MIN query for the 1st minimum value? SELECT dbo_CON.SC, dbo_CON.SN, Min(dbo_CON.SQ) AS MinOfSQ FROM dbo_CON GROUP BY dbo_CON.SC, dbo_CON.SN HAVING (((dbo_CON.SC)<>49)); Thanks, Hi Jerry, This will give me three different SC SN records. I am looking for same SC SN records that has next min SQ. table SC SN SQ 1 100 1 1 100 2 1 100 3 1 100 ...

make query from to 64 bit system
I have a application need to be compile for 64 bit system. how can i read data from 2005. hi Jennifer, On 09.12.2009 17:36, Jennifer wrote: > I have a application need to be compile for 64 bit system. how can i read > data from 2005. First of all, I don't see the point why you're asking this question in an Access newsgroups. Further more, you should really be more spefific... mfG --> stefan <-- ...

Report Asking For a Parameter
So I had a report that called with its Record Source set to TableA. I then made a copy of this report, but change the Record Source to TableB. TableB is a summary of TableA, and is missing one field, NAME So when I run my report, it pops up asking for the paramater for NAME. I looked at the report and deleted the feild that was linked to NAME. The report is still asking for NAME, even though no feilds on the report ask for it now. How do I go about fixing this? On Mon, 3 Mar 2008 15:19:03 -0700, "James" <> wrote: NAME (which by the way is a Reserved Wor...

<> data query
I have two tables and both have a field called tag_id. The first table "my2003" has about 5000 records. The second table "monitor2003" is a subset of table "my2003" and has about 3000 records. I need help building a query that will give me the records in table "my2003" where the "tag_id" field is <> to the "tag_id" field in the "monitor2003" table. Also which type of joining of the two tables is needed? Use the query wizard to create an unmatch record query that will list all the records in my2003 but are n...

Different queries but the same?
Hi Everyone, Access 2003. I accidently double clicked on the wrong thing in a new query based on another query. In the query grid, I added the qryVentThpyWithinLastArea and double clicked on the *. It only filled one column of my grid but when I ran the query, it showed all the fields from the query. I then dragged down Area field and added my criteria. I had been taught to double click on the blue title bar and then drag all the fields to the grid then add my criteria. Both ways give me the same data. What is the differnce? I pasted the sql below so you can see what's going...

trim in query
Hi All I am trying to trim a leading space at the start of each field in my "Customers" table which is an Exel spreadsheet imported using "TransferSpreadsheet" After researching the internet I have been able to get this to work using, for example: CustomerName: Trim([F3]) in the Field line of a select query ("CustomersTrimQry"). My promlem is that when I append the data from "CustomersTrimQry" to the "Customers" table the space returns. Prior to using trim I ran 3 queries from the original "CustomersImport" table, "C...

Database SQL query
Sorry for this post here. If someone knows a group I can go to for this question, please let me know. I have a program in MFC that accesses and updates an Access database. The problem is I can't figure out how to add a field which contains a word with a single apostrophe ie (St. Vincent's). I'm using the CDaoDatabase and CDaoRecordset classes. I understand that DAO is interpreting the apostrophe as some type of terminator but there must be a way around the issue. MS Access has information on how to do it in Access VB but that doesn't seem to work in MFC. Thanks Ughh ...

outlook parameters #2
This is a multi-part message in MIME format. ------=_NextPart_000_006C_01C60558.781A0570 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hello everyone!! there is some place where I can see all thje outlook parameters?? like a = /safe=20 Jana ------=_NextPart_000_006C_01C60558.781A0570 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML><HEAD> <META http-equiv=3DContent-Type content=3D"...

MS query and Firebird
I am accessing a Firebird data base with MS Query into Excel. I am trying to change the column heading (column name) but as I writte a "Newname" in Column Heading MS Query dont accept. I try to change directlly the SQL statement with "AS" clause and without "AS" clause but MS Query dont accept. I dont know if the format of select statement is different in Firebird data base or is a problem with MS Query. JC. ...

Outbox Parameter Value Invalid Error
My Gmail is linked to Outlook. Currently, I have a message sitting in the Outbox of email. It won't send after multiple tries, and the error message reads: Task 'Gmail - Sending' reported error (0x80070057) : 'Could not complete the operation. One or more parameter values are not valid.' What does this mean? I am not a very savvy IT person, so layman's terms would be helpful with any offered solutions. Thanks! ...

(Advance Programming) Parameter Returned as Value
Hi, I wish some body could Help Me, I have being loocking for a solution for 2 days. I need to make a simple Query to check if the parameter values are in a Table. I want the Query to return "Founds" and "Not Founds". For Example: Table Definition: TName CREATE TABLE [dbo].[TName] ( [IdName] [bigint] IDENTITY (0, 1) NOT NULL , [Name] [nvarchar] (30) COLLATE Traditional_Spanish_CI_AS NOT NULL ) ON [PRIMARY] Values: Insert Into TName (Name) Values ('Paul') Insert Into TName (Name) Values ('Peter') Insert Into TName (Name) Valu...

faq: type of CArray as function parameter create errors
Hi, class CMyPoint { public: long x; long y; CArray<int,int&> m_intSegmentNo; CMyPoint(); virtual ~CMyPoint(); CMyPoint(const long &xx, const long &yy); CMyPoint(const CMyPoint &cmpt); CMyPoint(const CPoint &cpt); CMyPoint& operator = (const CMyPoint &assmypt); CMyPoint& operator = (const CPoint &asspt); bool operator == (const CMyPoint &rmypt);//const CMyPoint &lmypt, bool operator != (const CMyPoint &rmypt);//const CMyPoint &lmypt, }; .... class CSegment { public: CList<CMyPoint,CMyPoint&> m_PointList; CSeg...

::PostMessage not delivering the parameter
I have a PostMessage call crossing thread boundaries, but the parameter passed doesn't seem to be right. What could be wrong? Code: -------------------- CClientThread* pThread = (CClientThread*) AfxBeginThread(RUNTIME_CLASS(CClientThread), THREAD_PRIORITY_NORMAL, 0, CREATE_SUSPENDED); if (!pThread) { clientSock.Close(); TRACE("Couldn't create thread\n"); AfxMessageBox("Couldn't create thread\n"); return; } //Keep track of all threads m_ClientThreads.push_back(pThread); // Pass the socket to the thread by passing the socket handle. // You...

Project Manager 2007 queries
I am considering purchasing Proect Manager for my my Planner, we are a small office who a familiar with the basics but have a few queries which are a little more detailed, I hope someone may able to advise on:- 1. Reporting - What are the options for importing and exporting documents and the number of format types, are they clear and easy to learn and use ? 2. Graphs - Is graphical data readily available, are there differing options of graphs and are the tools for producing them clear and easy to use ? 3. Sand pits - Are there areas where 'offline' working is availabl...

UDF XLA and SQL queries
Newbie question. Apologies in advance if it's too simplistic or in the wrong forum. I want to add an UDF to Excel. This UDF queries a SQL database. Say the function name is 'MyFunc'; I want to be able to have (in a cell) =MyFunc("ABC") return some data from the SQL database (for example here, say the Product Description for product "ABC"). The user needs to select the database the first time he uses the workbook. The UDF is called often in the worksheets of a given workbook so I would prefer to open the connection once at the beginning and...

Parse field in query
I have a table called MasterData with a field called Originator. The field data looks like this... Lou Santana Steven Sentry/Miami/PU/WC/US CN=Kathy T. Buon/OU=Miami/OU=BU/O=WC/C=US Terry J Leif I need it to look like this... Lou Santana Steven Sentry Kathy T. Buon Terry J Leif How can this be parsed?? -- deb What a mess that you're stuck with! Below will look for the first / and return the string before it in a query. If there isn't a / it returns the entire string. Of course this doesn't help with the CN= in CN=Kathy T. Buon. Parsed: IIf(InStr([Originator],"/")...

Using form to enter "query criteria" (between values)
Good morning everyone, I want to create a form with two boxes, where first box is lower limit of the value and the second upper limit. This values should be used in my query as filter criteria. Like this (query filter criteria): > "textbox1" AND < "textbox2" Does anyone know how I can build this in a form (i.e. connect my textboxes and query criteria)? Kindly, Mikael Sweden By thinking about for another minute I found the (simple) answer. In the query criteria I put the following expression: BETWEEN [forms].[nameofform].[NameofDatefield1] AND [forms].[name...

Mailbox manager cleanup agent skips mailboxes?
Hi, I have a pretty simple setup, a single Exchange 2003 server, single domain, only one Mailbox policy, it runs the Mailbox manager every Sunday, cleans up items in Sent Items, SPAM, and the Deleted Items folders based on age. It has run for a while now, generates a report to me, and a note to the users. Every week it cleans up about 400MB worth of messages. Lately, I received calls from a few users whose mailboxes went over the size limit, and when I look at the report, I find it didn't run the cleanup agent on that mailbox. I don't see it documented anywhere, but now it's a chic...

Need help getting query to reference a field in a subform
I am trying to run a query using a specific field in a subform as the criteria. The query is displaying one combo box from the Form, as well as several fields from its own subform. My Form name is: FormGrantManagement My Subform name is: TableMOA subform My Subform's subform is: TableCostReports The field in the subform I want to reference is: MOAID I have found other help topics that lead me to think that a criteria along the lines of [Forms]![FormGrantManagement]![TableMOA subform]! [Form]![MOAID] is what I need to use, and I have tried multiple variations of this but witho...

Save Query Results as table to another Access Database
I have an access database that users use to pull reports (stored procs in sql server) and it paste the data on 4 sheets in excel. Occasionally the reports are too big for excel. I'd like to develop a similar database that saves the results of the 4 stored procs as tables in a new Access database. right now I have it returning the results as a query. How do I save the results in another database? Thanks, -- Billy Rogers Dallas,TX Currently Using SQL Server 2000, Office 2000 and Office 2003 Hi Billy The following SQL statement should do it for you: SELECT * INTO [TableName] I...

Append Query Fails, MS Access 2000 bug?
I appear to be having a problem with an append query. I created a select query, converted the query to a make table query. The query created the table, NewTable, and inserted the data. I then modified the query again to an append query. The data in NewTable was deleted, then I ran the append query... everything ran fine. I opened NewTable in Design View, saved the table (NO changes were made). I re-ran the append query and it failed: Microsoft Access can't append all the records in the append query. Microsoft Access set 0 field(s) to Null due to a type conversion failure, and i...

Query help please 04-08-10
I have two combo boxes. Location and Super1 The location box lets you select a location where a staff member is working at.For example U3 B-days. The Super1 box lets you select their supervisor who works U3 B-days. As it stands right now it will work. The problem is that it will show all Supervisors through out the whole place. I found a way where I can select from the Location box where it will pull up just the supervisors for that location in the Super1 box. That works so far so good. Now, where the problem comes in is when the staff member is a supervisor. For example: Staf...

How to query multiple zip codes
I have a database of over 380k records that I need to separate out by zip codes. What I am doing is getting a 50 mile radius of my directors across the country and this program comes up with a list of zip codes in that radius. Just for OR, I have 7 pages of zip codes (182 zips). Is there an easy way in Access to get only those zips? Some I can use the operator between "97005-97024", but I can't do the entire list that way. I've always wanted to figure this out. Thanks for any help to make this easier for me. I have about 48 regions to do. Hi Jerry: I do have ...