Dcount: Combining two criterias - stuck

C.D

Registered User.
Local time
Tomorrow, 00:29
Joined
Sep 29, 2007
Messages
42
[solved]Dcount: Combining two criterias - stuck

Hey,
I'm trying to calculate the number of episodes downloaded from one animation series. I've managed to find two working criterias, but I fail to combine them:

This counts the total amount of episodes for each induvidual anime:
DCount("AnimeFansubberEpisodeID";"AnimeFansubberEpisode";"[AnimeFansubberID]=" & [AnimeFansubberID])



This counts the TOTAL number of episodes from ALL series which have "Download status = Yes"
DCount("AnimeFansubberEpisodeID";"AnimeFansubberEpisode";"[AnimeEpisodeDownloadStatus] = -1")



What I really want is to calculate the totl amount of episodes for each individual anime, which has "Download status= Yes"


DCount("AnimeFansubberEpisodeID";"AnimeFansubberEpisode";"[AnimeFansubberID]=" & [AnimeFansubberID] And "[AnimeEpisodeDownloadStatus]=-1")
This is the only code I've come up with that works - but it counts ALL episodes from ALL series, which is kind of not important..


I hope this is possible.. Thanks in advance
 
Last edited:
Heisann,

the criterion of the domain aggregate functions are really a string, and it's also the same as an SQL WHERE clause, without the keyword WHERE, so perhaps

DCount("AnimeFansubberEpisodeID";"AnimeFansubberEp isode";"[AnimeFansubberID]=" & [AnimeFansubberID] & " And [AnimeEpisodeDownloadStatus]=-1")

Note the difference in the concatentations.
 
Heisann,
Det fungerte veldig bra - tusen takk for hjelpen! Lærte en nyttig regel der.
Det er utrolig morsomt å se at ting begynner å ligne det bildet man har forestilt seg :)

Thanks alot, that worked out fine! An important lesson learned there :)
 

Users who are viewing this thread

Back
Top Bottom