Wrong Formula gives Right Answer???

mboe

Registered User.
Local time
Today, 11:34
Joined
Dec 27, 2000
Messages
51
I have two identical formulas to compare some dollar values. I need to compare two numbers in two different tables, [pymt_amt] and [SPrinciple]. The first formula returns the Value if two fields equal each other. The second returns a value if they don’t. The problem is the second formula is returning a value when the first should and the first will not. They are all stored as numbers in the tables but it acts like it’s comparing two differently formatted fields. Because even though the numbers equal each other the formulas are saying they are not. ….???.... Any ideas would be great.


Prinp: DLookUp("[amttxn]","fhlb_activity","[effectiveDate] = #" & [effectiveDate] & "# and [Loan_no] = '" & [loan_number] & "' and " & [pymt_amt] & " = " & [SPrinciple] & " and [txn_code] = 856")

AddPrin: DLookUp("[amttxn]","fhlb_activity","[effectiveDate] = #" & [effectiveDate] & "# and [Loan_no] = '" & [loan_number] & "' and " & [pymt_amt] & " <>" & [SPrinciple] & " and [txn_code] = 856")
 
Prinp: DLookUp("[amttxn]","fhlb_activity","[effectiveDate] = #" & [effectiveDate] & "# AND [Loan_no] = '" & [loan_number] & "' AND [pymt_amt] = " & [SPrinciple] & " AND [txn_code] = 856")

AddPrin: DLookUp("[amttxn]","fhlb_activity","[effectiveDate] = #" & [effectiveDate] & "# AND [Loan_no] = '" & [loan_number] & "' AND [pymt_amt] <> " & [SPrinciple] & " AND [txn_code] = 856")
 

Users who are viewing this thread

Back
Top Bottom