[Zope] float calculation in ZSQL Method??
Geir Bækholt
Geir Bækholt
Mon, 4 Nov 2002 17:29:51 +0100
Hello Atuc,
Monday, November 4, 2002, 12:26:41 PM, you wrote:
A> i have the problem to make a calculation in an ZSQL Method, i would like to
A> add the two floats like this. what i get is only a string adding!
A> i get this if i give the numbers 1 and 100, i would like to get 101
the problem is not in the way you do the calculation, your code is ok,
but the fact that the passed in numbers are strings.
in your ZSQL-method's argument-list, define them as floats like this:
Position1:float
Position2:float
and it should work fine
:)
--
Geir Bækholt geir@funcom.com
Tools/HCI-developer
Tools/Billing - Product Operations
Funcom Oslo