![]() | |
![]() |
| | Thread Tools | Display Modes |
#11
| |||
| |||
|
|
I'm trying to generate an Age Analysis Report where the foll SQL statement will executed be in a loop for each customer. I was always under the impression that the "ValueIfNull" i.e. 2nd argument of the NZ function was optional and so far it has worked for me. However, if you feel I should change it and compulsorily include the 2nd argument, then I'll go ahead and do so. I'd really appreciate an explanation as to why though. |
#12
| |||
| |||
|
|
prakashwadhw... (AT) gmail (DOT) com wrote innews:f3f5cad9-cf25-4dcc-978a-163f561cab2c (AT) z9g2000yqi (DOT) googlegroups.com : I'm trying to generate an Age Analysis Report where the foll SQL statement will executed be in a loop for each customer. I was always under the impression that the "ValueIfNull" i.e. 2nd argument of the NZ function was optional and so far it has worked for me. *However, if you feel I should change it and compulsorily include the 2nd argument, then I'll go ahead and do so. I'd really appreciate an explanation as to why though. The reason is that Access makes a "best guess" as to the value to be returned, either 0 for a numeric or "" (empty string) for all other types. Sometimes it guesses wrong. Also, having the default value explicitly stated makes your intentions clear to a future maintainer of the database. -- Bob Quintal PA is y I've altered my email address. |
#13
| |||
| |||
|
|
On Apr 18, 5:01*pm, Bob Quintal <rquin... (AT) sPAmpatico (DOT) ca> wrote: prakashwadhw... (AT) gmail (DOT) com wrote innews:f3f5cad9-cf25-4dcc-978a-163f561cab 2c (AT) z9g2000yqi (DOT) googlegroups.com : I'm trying to generate an Age Analysis Report where the foll SQL statement will executed be in a loop for each customer. I was always under the impression that the "ValueIfNull" i.e. 2nd argument of the NZ function was optional and so far it has worked for me. *However, if you feel I should change it and compulsorily include the 2nd argument, then I'll go ahead and do so. I'd really appreciate an explanation as to why though. The reason is that Access makes a "best guess" as to the value to be returned, either 0 for a numeric or "" (empty string) for all other types. Sometimes it guesses wrong. Also, having the default value explicitly stated makes your intentions clear to a future maintainer of the database. -- Bob Quintal PA is y I've altered my email address. Thanks Bob !!! This really puts it in perspective. As the age-old adage goes ... Better safe than sorry !! I've finally got the module ready but it's running a bit slowly. Should I start another thread for it or post the code here and continue with it ? Best Rgds, Prakash. Create a new thread. Responders often skip over threads which have |
#14
| |||
| |||
|
|
prakashwadhw... (AT) gmail (DOT) com wrote innews:d29036ac-8e00-442b-b3fc-657f57b59cbe (AT) a7g2000yqk (DOT) googlegroups.com : On Apr 18, 5:01*pm, Bob Quintal <rquin... (AT) sPAmpatico (DOT) ca> wrote: prakashwadhw... (AT) gmail (DOT) com wrote innews:f3f5cad9-cf25-4dcc-978a-163f561cab 2... (AT) z9g2000yqi (DOT) googlegroups.com : I'm trying to generate an Age Analysis Report where the foll SQL statement will executed be in a loop for each customer. I was always under the impression that the "ValueIfNull" i.e. 2nd argument of the NZ function was optional and so far it has worked for me. *However, if you feel I should change it and compulsorily include the 2nd argument, then I'll go ahead and do so. I'd really appreciate an explanation as to why though. The reason is that Access makes a "best guess" as to the value to be returned, either 0 for a numeric or "" (empty string) for all other types. Sometimes it guesses wrong. Also, having the default value explicitly stated makes your intentions clear to a future maintainer of the database. -- Bob Quintal PA is y I've altered my email address. Thanks Bob !!! *This really puts it in perspective. As the age-old adage goes ... Better safe than sorry !! I've finally got the module ready but it's running a bit slowly. Should I start another thread for it or post the code here and continue with it ? Best Rgds, Prakash. Create a new thread. Responders often skip over threads which have multiple answers. -- Bob Quintal PA is y I've altered my email address. |
![]() |
| Thread Tools | |
| Display Modes | |
| |