MySQL 5/Float

This WebDNA talk-list message is from

2007


It keeps the original formatting.
numero = 68349
interpreted = N
texte = I'm using to WebDNA to pull numeric values from MySQL 4.0.x table and add them up. I upgraded to MySQL 5.0.x and noticed that the addition isn't working any more. For example, a record with "21.1" in the "price" column is displayed as "1077221785" in my WebDNA [founditems] loop. In MySQL, the price column has type "float." Anyone else have problems with MySQL columns with type float? Code example below. Breaks added for legibility. [sqlconnect dbtype=MySQL &host=216.168.63.56 &database=mydatabase &uid=myname &pwd=mypass &conn_var=conn1] [/sqlconnect] [sqlexecute conn_ref=conn1&result_var=rs4] SELECT subtotal FROM transaction WHERE orderid = '103352'; [/sqlexecute] [sqlresult result_ref=rs4] [founditems] [subtotal] [/founditems] [/sqlresult] ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: MySQL 5/Float ( Clint Davis 2007)
  2. Re: MySQL 5/Float ( Jesse Proudman 2007)
  3. MySQL 5/Float ( Clint Davis 2007)
I'm using to WebDNA to pull numeric values from MySQL 4.0.x table and add them up. I upgraded to MySQL 5.0.x and noticed that the addition isn't working any more. For example, a record with "21.1" in the "price" column is displayed as "1077221785" in my WebDNA [founditems] loop. In MySQL, the price column has type "float." Anyone else have problems with MySQL columns with type float? Code example below. Breaks added for legibility. [sqlconnect dbtype=MySQL &host=216.168.63.56 &database=mydatabase &uid=myname &pwd=mypass &conn_var=conn1] [/sqlconnect] [sqlexecute conn_ref=conn1&result_var=rs4] SELECT subtotal FROM transaction WHERE orderid = '103352'; [/sqlexecute] [sqlresult result_ref=rs4] [founditems] [subtotal] [/founditems] [/sqlresult] ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ Clint Davis

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

[Fwd: Rotating Banners ... (was LinkExchange)] (1997) Exclamation point (1997) Emailer file formats (1998) Platform Switch (1997) Running 2 two WebCatalog.acgi's (1996) carriage returns in data (1997) b12 cannot limit records returned and more. (1997) Upgrading old WebCat Database Files (1997) WC2b15 File Corruption (1997) Date problems (1997) Summary search -- speed (1997) Another OS 10.3 Upgrade issue (2003) OK, here goes... (1997) DB Field Name? (2000) Searching Numbers (2004) no global [username] or [password] displayed ... (1997) 3+ Levels of Navigation (2006) [platform] tag? (1998) WebSTAR plugin update (2004) RequiredFields template (1997)