• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
Locked
0

Assigned bindable variable change changing MySQL Data !?

Participant ,
Oct 11, 2010 Oct 11, 2010

Copy link to clipboard

Copied

One way Data Binding of an ArrayCollection to a last result is altering MySql Record through Coldfusion?

The following if you click on it increments all the dates once, for each time you click,...

like a counter, it changes the value in MySQL, but as I understand what I wrote

I am assigning the last result value to a bindable variable.

So why is the value stored way back in MySQL (after you pass through cold fusion) changed, and how?

This is  contrary to my understanding of how the software should work. Comments?

[Bindable]
public var theResults:ArrayCollection = new ArrayCollection();
protected function showAllButton_clickHandler(event:MouseEvent):void
{
getAllLineItemsResult.token = lineItemsService.getAllLineItems();
lineItemsService.commit();
}
protected function getAllLineItemsResult_resultHandler(event:ResultEvent):void
{
theResults = getAllLineItemsResult.lastResult
for each(var item:Object in theResults)
{     
item.AptDate = new Date(item.AptDate.getTime() + (1 *  millisecondsPerDay));
}

}
and of course theResults is bound to the dataGrid dataProvider property.
FlashBuilder 4, CF9 and MYSQL

Thanks
Dan Pride

Views

460

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Employee ,
Oct 12, 2010 Oct 12, 2010

Copy link to clipboard

Copied

LATEST

Is the service enabled for datamanagement? Also Have you set autocommit on the service's datamanager, to true?

If the answer is yes for the above, then this can happen, as an edit to the datagrid column or an update would automatically call the appropriate functions that are set as part of Datamanagement?

Thanks

-Sunil

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines