That was the ticket. Why did the is null not work appropriately?
With Warm Regards,
Arthur D. Lorenzini
IT System Manager
Cheyenne River Housing Authority
Wk.(605)964-4265 Ext. 130
Fax (605)964-1070
"Valar Dohaeris"
On Tuesday, April 9, 2019, 08:26:44 PM CDT, Duane Hookom duanehookom@hotmail.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:
Hi Art,
I would use Nz()
SELECT SV00300.ADRSCODE AS [Unit No], SV00300.CUSTNAME AS [Tenant Name], SV00300.Service_Call_ID AS [Work Order ID], SV00300.Service_Description, SV00300.DATE1 AS [Work Order Date], SV00300.Type_of_Problem AS Type, SV00300.Status_of_Call AS Status, SV00300.Technician
FROM SV00300
WHERE DATE1>=[forms]![frmWorkOrderlog]![txtDatefrom] And
DATE1<=[forms]![frmWorkOrderlog]![txtDateto] And
Status_of_Call=Nz([forms]![frmWorkOrderlog]![cbostatus],Status_of_Call); Is there a reason you didn't use "BETWEEN":
DATE1 BETWEEN [forms]![frmWorkOrderlog]![txtDateto] And [forms]![frmWorkOrderlog]![txtDatefrom]
This generally easier to understand.
Regards,
Duane
From: MS_Access_Professionals@yahoogroups.com <MS_Access_Professionals@yahoogroups.com> on behalf of dbalorenzini@yahoo.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com>
Sent: Tuesday, April 9, 2019 3:19 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: [MS_AccessPros] Lokkup all values from query
Sent: Tuesday, April 9, 2019 3:19 PM
To: MS_Access_Professionals@yahoogroups.com
Subject: [MS_AccessPros] Lokkup all values from query
I have the following query that supports a from from WOrkOrderLog:
SELECT SV00300.ADRSCODE AS [Unit No], SV00300.CUSTNAME AS [Tenant Name], SV00300.Service_Call_ID AS [Work Order ID], SV00300.Service_Description, SV00300.DATE1 AS [Work Order Date], SV00300.Type_of_Problem AS Type, SV00300.Status_of_Call AS Status, SV00300.Technician
FROM SV00300
WHERE (((SV00300.DATE1)>=[forms]![frmWorkOrderlog]![txtDatefrom] And (SV00300.DATE1)<=[forms]![frmWorkOrderlog]![txtDateto] And (SV00300.Status_of_Call)=[forms]![frmWorkOrderlog]![cbostatus]));
FROM SV00300
WHERE (((SV00300.DATE1)>=[forms]![frmWorkOrderlog]![txtDatefrom] And (SV00300.DATE1)<=[forms]![frmWorkOrderlog]![txtDateto] And (SV00300.Status_of_Call)=[forms]![frmWorkOrderlog]![cbostatus]));
on it I have a combo box(cbouser) to select a status (Open, Close and Completed). It works fine when I select a status but I need it to return all statuses if none is selected in the combo:
Any ideas?
Thank you
Art Lorenzini
Sioux Falls,SD
__._,_.___
Posted by: Art Lorenzini <dbalorenzini@yahoo.com>
Reply via web post | • | Reply to sender | • | Reply to group | • | Start a New Topic | • | Messages in this topic (4) |
Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.
SPONSORED LINKS
.
__,_._,___
Tidak ada komentar:
Posting Komentar