UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Need to select records with empty currency field    
 
   
sync00
post Jan 16 2006, 03:54 PM
Post #1

UtterAccess Addict
Posts: 146



I tried the following WHERE clauses to return records where the 'costper' field is empty and neither return any results.

WHERE NZ([Transactions].[CostPer])=0

WHERE [Transactions].[CostPer]=0

WHERE IsNull([Transactions].[CostPer])
Go to the top of the page
 
+
HiTechCoach
post Jan 16 2006, 04:00 PM
Post #2

UtterAccess VIP
Posts: 18,396
From: Oklahoma City, Oklahoma



Try:

WHERE [Transactions].[CostPer] is Null


Tip: If you will use the query design in design mode, it will validate your SQL syntax and also help you write it.
Go to the top of the page
 
+
sync00
post Jan 16 2006, 04:09 PM
Post #3

UtterAccess Addict
Posts: 146



I just realized that the other clauses actually were working.

I am working in design mode when I can figure out how to use it. Could Access have helped me figure out to use 'is null' as the criteria?
Go to the top of the page
 
+
HiTechCoach
post Jan 16 2006, 06:26 PM
Post #4

UtterAccess VIP
Posts: 18,396
From: Oklahoma City, Oklahoma



QUOTE
Could Access have helped me figure out to use 'is null' as the criteria?

Yes.

QUOTE
I am working in design mode when I can figure out how to use it

This mode is the easiest mode to work in. It will be worth taking a little time to learn it.
Go to the top of the page
 
+
sync00
post Jan 16 2006, 07:38 PM
Post #5

UtterAccess Addict
Posts: 146



How could Access have helped me figure out to use 'is null' as the criteria?
Go to the top of the page
 
+
sync00
post Jan 16 2006, 07:48 PM
Post #6

UtterAccess Addict
Posts: 146



I see now how to use the Expression builder to enter 'null' as the criteria and it gets converted to 'is null'.

Today I experimented with using Query design mode to create various joins and I was pleasantly surprised to see how easy it is.
Go to the top of the page
 
+
HiTechCoach
post Jan 16 2006, 08:28 PM
Post #7

UtterAccess VIP
Posts: 18,396
From: Oklahoma City, Oklahoma



If you have defined relationship for your tables, then when you add tables with defined relationships in the Query designer, it will automatically create the joins for you.
Go to the top of the page
 
+
sync00
post Jan 16 2006, 08:49 PM
Post #8

UtterAccess Addict
Posts: 146



I'm working with a third party app that uses Access as a back end. So I have no control over the table definitions.
Go to the top of the page
 
+
HiTechCoach
post Jan 16 2006, 10:20 PM
Post #9

UtterAccess VIP
Posts: 18,396
From: Oklahoma City, Oklahoma



I use Access as a report writer for other third party apps.

If you create a front end and link to the back end database of the third party app, you can actually define relationships in your front end, even it the original developer did not create any. This will not effect the back end database.
Go to the top of the page
 
+
sync00
post Jan 17 2006, 11:19 AM
Post #10

UtterAccess Addict
Posts: 146



I have a database with links to the back end tables. I've seen the relationship screen but I didn't know you can add new ones. That will certainly be useful.
Go to the top of the page
 
+

Thank you for your support! Reply to this topicStart new topic

Jump To Forum:
 



RSS Go to Top  ·  Lo-Fi Version Time is now: 21st May 2013 - 06:17 AM