Hello,

I try the next query:

"SELECT workers.nev, worker_id, item_id, sum(pays.amount) as amount
               FROM pays, workers
               WHERE workers.id=pays.worker_id and year >={$syear} AND 
year<={$eyear} AND month>={$smonth} AND month<={$emonth} and item_id in 
(".join(', ', $ids).")
               GROUP by worker_id, item_id"

But when I retrieving the data I get an array something like this:

[5] => Array
         (
             [workers] => Array
                 (
                     [nev] => Ámon Tamás
                 )

             [pays] => Array
                 (
                     [worker_id] => 5
                     [item_id] => 6
                 )

             [#sql_ae6_0] => Array
                 (
                     [amount] => 0
                 )

         )

The problem is the last sub-array with #sql_ae6_0. And this is always 
changing. How can I retrieve datas from it?

-- 
Ámon Tamás
http://amon.hu


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~----------~----~----~----~------~----~------~--~---

Reply via email to