11. januar 2008 - 15:42
Der er
17 kommentarer og 1 løsning
Hvad er galt ?
SELECT DISTINCTROW KUNDE.DateID, KUNDE.Year, KUNDE.[C/Y], DSum("[C/Y]","KUNDE","Year = '" & [Year] & "' AND DateID <= " & [DateID]) AS [AKK C/Y] FROM KUNDE; Hvorfor kan jeg ikke beregne AKK C/Y pr. YEAR ????
Annonceindlæg tema
Forsvar & beredskab
Cybersikkerhed, realtidsdata og robuste it-systemer er blevet fundamentet for moderne forsvar.
11. januar 2008 - 16:18
#1
Have you tried the dsum in debug window(CTL+G) replacing the values with fixed values EG: ? DSum("[C/Y]","KUNDE","Year = '" & "2008" & "' AND DateID <= " & 1234)
14. januar 2008 - 11:21
#2
Hi Terry I simply can't see what is wrong :-(
14. januar 2008 - 11:37
#3
Have you tried the dsum in debug window?
14. januar 2008 - 11:38
#4
Just a comment, it snever a good idea to use charcaters such as / and - in table/field names.
14. januar 2008 - 12:36
#5
It makes no difference replacing "/" :-(
14. januar 2008 - 12:48
#6
Have you tried the dsum in debug window???? and maybe try DISTINCT instead of DISTINCTROW
14. januar 2008 - 13:19
#7
No difference Debug message : Compile error - Expected list separator or )
14. januar 2008 - 14:51
#8
is it possible to see the dB?
14. januar 2008 - 14:55
#9
I could sent you the part that couses the problem :-)
14. januar 2008 - 15:00
#10
yes thats enough ekspertenATsanthell.dk AT = @
14. januar 2008 - 15:24
#11
AKK: DSum("[C/Y]";"KUNDE";"[Year] = " & [Year] & " AND month(DateMonth) <= " & Month([DateMonth]))
14. januar 2008 - 15:25
#12
The first problem was that year is a number and you were putting it in ''
14. januar 2008 - 15:28
#13
That's not an AKK sum !!!!
14. januar 2008 - 18:29
#14
?
15. januar 2008 - 08:43
#15
Year DateMonth C/Y AKK C/Y 2008 01-01 100 100 2008 02-01 100 200 2008 03-01 100 300 2008 04-01 100 400
15. januar 2008 - 11:49
#16
AKK: DSum("[C/Y]";"KUNDE";"[Year] = " & [Year] & " AND Clng(DateMonth) <= " & CLng([DateMonth]))
15. januar 2008 - 12:14
#17
Thanks :-)
15. januar 2008 - 13:46
#18
selv tak
Dyk ned i databasernes verden på et af vores praksisnære Access-kurser