Results 1 to 2 of 2

Thread: Mysql ODBC driver fails to execute aggrigate functions?

  1. #1
    Join Date
    Jan 2008
    Posts
    1

    Default Mysql ODBC driver fails to execute aggrigate functions?

    Description:
    I am using powerbuilder 5.0 and Mysql 5.0.27-commnunity-nt
    use following statment
    Error Messagee :
    SQLSTATE = S1T00
    [MySQL][ODBC 3.51 Driver][mysqld-5.0.27-community-nt]FUNCTION veg.sum does not
    exist

    Code :

    int it

    select sum(item_id) into :It from item ;

    if SQLCA.SQLCode = -1 then MessageBox("SQL
    error",SQLCA.SQLErrText,Information!)
    messagebox("count",String(it))

    How to repeat:
    I tried this command in powerbuilder database administrator option without using
    into plane statement it works i tried max, min and sum all aggricated funciton
    fail when i try to stored result in variable.
    Powered by Yahoo!

  2. #2
    Join Date
    Jan 2008
    Posts
    1

    Default

    Not sure about the MySQL environment in windows, but i believe the select statement is wrong.

    It should be :

    select sum(item_id) into @It from item ;
    select @it;
    Powered by Yahoo!

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •