Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Queries / December 2005

Tip: Looking for answers? Try searching our database.

all or some records

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
JeffMKlein - 02 Dec 2005 17:08 GMT
My query uses a function (fclinetID) in the clientID criteria.  Sometimes I
want to run this query for all clientID records (not null records).  Is
there a way to use someting like the following code.

IIf(IsNull(fclientid()),"ALL RECORDS" ,fclientid())

I know "ALL RECORDS" is not real but I need something that acts like it.
John Spencer - 02 Dec 2005 17:27 GMT
Guessing here, but you might be able to use the following.

IIf(IsNull(fclientid()),[ClientID],fclientid())

Basically, this should return all records where the ClientID is equal to
itself, if fClientID() returns a null value.  Since NULL is never equal to
anything (including another null), any record where ClientID is null won't
be returned.

> My query uses a function (fclinetID) in the clientID criteria.  Sometimes
> I
[quoted text clipped - 4 lines]
>
> I know "ALL RECORDS" is not real but I need something that acts like it.
JeffMKlein - 02 Dec 2005 17:34 GMT
John, Thanks for the reply.  This works!! Cant believe I did not think of
it.  Sometimes simple is too obvious

> Guessing here, but you might be able to use the following.
>
[quoted text clipped - 13 lines]
> >
> > I know "ALL RECORDS" is not real but I need something that acts like it.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.