in reply to Re: Difference between inline SQL and bound data
in thread Difference between inline SQL and bound data
The difference seems to be at one point Perl converts the decimal representation to float, and in the other occasion it's the database. If their algorithms differ, and result in just one bit being set differently, it would explain what you observe.Not to me. There are three queries: the insert, the successful fetch, and the unsuccessful fetch. Both the insert and the unsuccessful fetch have ->execute(50.530998, -4.949000) (so Perl is doing the literal-to-float conversion), while in the successful fetch, the coordinates are hardcoded in the query, making MySQL do the literal-to-float conversion. If the problem lies in the difference between the algorithms used by Perl and MySQL, you would expect the now successful fetch to be unsuccessful, and the now unsuccessful to be successful.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: Difference between inline SQL and bound data
by polettix (Vicar) on May 17, 2010 at 15:46 UTC |