Infopath gets wrong data from calculated field in Access db

P

Patti M

My InfoPath form (secondary) pulls data from an Access database. The form is
autopopulated based on the name selected on the form in a pulldown list. All
fields populate correctly except one. This InfoPath field points to an Access
field with a formula in it (sums 5 fields). The Access query gets the
correct result, however Infopath adds about 30 extra points to the result.
Selecting different names from the dropdown gets slightly different results,
between 31-35 extra points. This problem is consistent. If I select the same
name in a different session, I get the same wrong answer in that field.
Help, please!

Patti M.
 
C

Clay Fox

It sounds like the data is correct but that the formating is wrong. My guess
is the Access field is a decimal or float and InfoPath is not formatting it.
Try to change the field type (is it s string? try using a decimal field)
and/or the format in the control properties. This should display the data
correctly without all of the decimal precision.
--
Thanks

Clay Fox

Qdabra Software
http://www.qdabra.com

InfoPathDev.Com
The Largest InfoPath Forum in the World
http://www.infopathdev.com
 
P

Patti M

Both the Access field and the InfoPath field are formatted as numbers with 2
decimals. Access field is defined as "Fixed, 2" with type of "Expression,"
and InfoPath is defined as "Decimal (Double)" with Display set to 2 decimal
places. The amount InfoPath is off is not an even amount, for instance, is
31.28 MORE than the Access query shows in that field. So that's why I don't
understand how InfoPath is getting its result. Why isn't it just reading the
field from the Access query and giving me back that result? It seems to be
calculating the field based on the Access formula, which InfoPath is
apparently not understanding.
 
C

Clay Fox

I would create a dump of the data from Access on another view. That way you
can verify what is coming across.

Also try putting the value in a text box or an expression box. This should
show it to you without formatting.

If it is already formatted correctly in Access then you might not need any
formatting in InfoPath.
--
Thanks

Clay Fox

Qdabra Software
http://www.qdabra.com

InfoPathDev.Com
The Largest InfoPath Forum in the World
http://www.infopathdev.com
 
P

Patti M

OK, I will give that a try and see if the results are any different.

Thanks,

Patti M.
 
P

Patti M

Not getting any difference in the results. No matter how I change the
formatting (on either Access or InfoPath), or even use an Expression Box on
InfoPath, I still get incorrect results. I don't understand why InfoPath
just doesn't read the query results from the Access field I point it to. The
form correctly brings up over 100 pieces of data associated with the person's
name selected, with the exception of this one field. I am using multiple
rules to auto-populate each section of the form for the person selected, and
all rules work perfectly except for this one field. This does not make sense
to me at all. Any other suggestions?

Patti M.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top