Use of the Nz function in a 2k query

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

New to the post.

I am working with a query that was designed by another. In one instance my
query uses an expression like this:
.[ID]-1-1-Nz([Field_Count])
For what I am doing I understand the expression up to this point:
.[ID]-1 "-1-" Nz([Field_Count])
What would this "-1-" seam to do?
When I use the help function I find nothing to signify why I would need this
in my expression.

A liitle more explenation:

Please bear with me, on my crude explenation. Basically I want to Enter a
value into my [Count_Field] where values of a certain set of criteria match
elsewhere in the query. But What effect does this "-1-" have in that action?
I hope this is enough information to get a respone back.
 
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

God knows what the original query designer meant to do w/ that
expression. The "-1-1" part is the same as "-2." Here is a possible
answer with the following values in the fields:

Table.ID = 25; Field_Count = 10

Evaluation: 25 - 1 - 1 - 10 = 13

--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBQX3z54echKqOuFEgEQLVKACfe21YEfHC65rJECcOoWzkf3L0EI4AoI/n
v+Pzi4g9Y96e5mnPmG4Nl2zw
=xy30
-----END PGP SIGNATURE-----
 
Thank you! Sometimes the obivous answer is right in front of you but you just
cant see it.

MGFoster said:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

God knows what the original query designer meant to do w/ that
expression. The "-1-1" part is the same as "-2." Here is a possible
answer with the following values in the fields:

Table.ID = 25; Field_Count = 10

Evaluation: 25 - 1 - 1 - 10 = 13

--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBQX3z54echKqOuFEgEQLVKACfe21YEfHC65rJECcOoWzkf3L0EI4AoI/n
v+Pzi4g9Y96e5mnPmG4Nl2zw
=xy30
-----END PGP SIGNATURE-----

New to the post.

I am working with a query that was designed by another. In one instance my
query uses an expression like this:
.[ID]-1-1-Nz([Field_Count])
For what I am doing I understand the expression up to this point:
.[ID]-1 "-1-" Nz([Field_Count])
What would this "-1-" seam to do?
When I use the help function I find nothing to signify why I would need this
in my expression.

A liitle more explenation:

Please bear with me, on my crude explenation. Basically I want to Enter a
value into my [Count_Field] where values of a certain set of criteria match
elsewhere in the query. But What effect does this "-1-" have in that action?
I hope this is enough information to get a respone back.
 
Back
Top