Here's a thought:
 
If I'm reading this correctly, is there any reason that this functional
implementation wouldn't be more appropriately handled in the database layer?
Me thinks the query request that's doing the read should group the data on
approval types before it's even returned to the Flash/Flex client, then
you've got a single data source (the Array) already processed and containing
only the data necessary AND grouped according to the requirement. This
reduces the code footprint and client layer processing, and additionally
allows the database server to use it's resources which are usually better
suited for this (one would think). Then you'd just iterate through the
returned data array and do some old-school control break processing of the
array data inside said iteration...
 
However, as always "your actual mileage may vary..."
 
Peace...
 
Glenn J. Miller
 

  _____  

From: [email protected] [mailto:[email protected]] On Behalf Of Jason West
Sent: Friday, January 09, 2009 11:40 AM
To: [email protected]
Subject: Re: [AFFUG Discuss] Best way to split CF query result for multiple
UI elements


I agree with Jay on the solution but I would add some additional
functionality to it, may an AJAX call back to the server to allow any kind
of refresh on the data in the case that there are multiple transactions
happening on the data.
 
If this is not the case then Jay's solution would be the best.
 
Thanks

Jason L. West
http://blog.wezbiz.net <http://blog.wezbiz.net/> 

/***************************************
* One of Einstein's colleagues asked him for his telephone number one day.
Einstein reached for 
* a telephone directory and looked it up. "You don't remember your own
number?" the man asked, startled.
*
* "No," Einstein answered. "Why should I memorize something I can so easily
get from a book?"
*
* In fact, Einstein claimed never to memorize anything which could be looked
up in less than two minutes.
* (Quoted from: http://oaks.nvg.org/sa5ra17.html)
/***************************************



On Fri, Jan 9, 2009 at 9:09 AM, <[email protected]> wrote:



You can define a filter function like this 

           public function filterType(item:Object):Boolean { 
                   var result:Boolean = false; 
                 if (item.Approval_type ==
dgType.selectedItem.Approval_type) 
                     result = true; 
                      
           return result;           
           } 
and on change event of the combobox(dgtype is the id for the combobox
containing approval types), bind the above filter function like this 

                           ApproverList.filterFunction = filterType; 
                           ApproverList.refresh();

Jay Jayaraman
Central Billing Services
Financial Management and Planning
(404) 498-8453 (W)
(404) 273-7131 (C) 



"Fox, Andrew J" <[email protected]> 
Sent by: [email protected] 


01/09/2009 08:07 AM 


Please respond to
[email protected]



To
discussion <[email protected]> 

cc

Subject
[AFFUG Discuss] Best way to split CF query result for multiple UI elements


                





Sorry if this is a re-post, it sisn't seem to go through yesterday...

I'm working on an application that handles workflow routing for a document.
There is a stored procedure that returns all of the approvers for the
document, along with the type of approval they are providing (i.e internal,
external, special.)  I need to split the different types out in order to
show the selected users in either a DataGrid or BindableComboBox of all
possible users of that type.

What is the best way to split this incoming data and then reference it? I
have been able to do a query of queries to get 3 arrays of Object but think
this is probably not the right way of doing it. I'm also not clear on how to
reference the different arrays now that they are split.

Any suggestions (especially with a bit of sample code) would be greatly
appreciated!

-- 
Andy Fox
Systems Analyst III
Georgia Tech OIT-EIS


-------------------------------------------------------------
To unsubscribe from this list, simply email the list with unsubscribe in the
subject line

For more info, see http://www.affug.com <http://www.affug.com/> 
Archive @ http://www.mail-archive.com/discussion%40affug.com/
List hosted by http://www.fusionlink.com <http://www.fusionlink.com/> 
-------------------------------------------------------------





------------------------------------------------------------- 

To unsubscribe from this list, simply email the list with unsubscribe in the
subject line 

For more info, see http://www.affug.com <http://www.affug.com/>  
Archive @ http://www.mail-archive.com/discussion%40affug.com/ 

List hosted by FusionLink <http://www.fusionlink.com/>  
------------------------------------------------------------- 



------------------------------------------------------------- 
To unsubscribe from this list, simply email the list with unsubscribe in the
subject line 

For more info, see http://www.affug.com 
Archive @ http://www.mail-archive.com/discussion%40affug.com/ 
List hosted by FusionLink <http://www.fusionlink.com>  
------------------------------------------------------------- 



-------------------------------------------------------------
To unsubscribe from this list, simply email the list with unsubscribe in the 
subject line

For more info, see http://www.affug.com
Archive @ http://www.mail-archive.com/discussion%40affug.com/
List hosted by http://www.fusionlink.com
-------------------------------------------------------------

Reply via email to