[flexcoders] Re: Eeeeek! Development grinds to a halt due to stupid syntax problem
--- In flexcoders@yahoogroups.com, Paul Andrews [EMAIL PROTECTED] wrote: Why do you have to use the database field names inside the flex application? What alternative approach would you suggest Paul? I use them to help me keep track of everything, as I'm using both a MS SQL database and an ODBC linked database to a proprietry format. I'm open to alternative method suggestions.
Re: [flexcoders] Re: Eeeeek! Development grinds to a halt due to stupid syntax problem
- Original Message - From: candysmate [EMAIL PROTECTED] To: flexcoders@yahoogroups.com Sent: Saturday, September 22, 2007 6:12 PM Subject: [flexcoders] Re: Ek! Development grinds to a halt due to stupid syntax problem --- In flexcoders@yahoogroups.com, Paul Andrews [EMAIL PROTECTED] wrote: Why do you have to use the database field names inside the flex application? What alternative approach would you suggest Paul? I use them to help me keep track of everything, as I'm using both a MS SQL database and an ODBC linked database to a proprietry format. I'm open to alternative method suggestions. I'd be looking to try and map the fieldnames to something more acceptable, perhaps switch that # for an underscore, or _h_. I used to specialise in DB development and have yet to see a schema with field names with a hash in them (not that that's your fault - it's just your problem). Depending on the DB, it might be possible to define a 1:1 view that could map the field names. Paul
[flexcoders] Re: Eeeeek! Development grinds to a halt due to stupid syntax problem
It's actually a Sage Line 100 database if that means anything to you. Sage have now uses SQL Server 2005 i believe, but this old proprietary format that I have to work with doesn't allow for anything 'creative'. Looks like I'm hosed, unless one of you clever people can think of a way around it.
Re: [flexcoders] Re: Eeeeek! Development grinds to a halt due to stupid syntax problem
Multiple people have already said this on both of the threads you posted with the same question: use square brackets to reference your properties. Try: selectedItem[ADDRESS_LINE#2] And if that doesn't work tell us that it doesn't and what happens if you try. On 9/22/07, candysmate [EMAIL PROTECTED] wrote: It's actually a Sage Line 100 database if that means anything to you. Sage have now uses SQL Server 2005 i believe, but this old proprietary format that I have to work with doesn't allow for anything 'creative'. Looks like I'm hosed, unless one of you clever people can think of a way around it.
RE: [flexcoders] Re: Eeeeek! Development grinds to a halt due to stupid syntax problem
If it were me, I'd just change the name of the field in the SQL select statement, like: select [ADDRESS_LINE#2] as addr2, - . . from. Then use addr2 in your app. _ From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of candysmate Sent: Saturday, September 22, 2007 12:12 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: Ek! Development grinds to a halt due to stupid syntax problem --- In HYPERLINK mailto:flexcoders%40yahoogroups.com[EMAIL PROTECTED], Paul Andrews [EMAIL PROTECTED] wrote: Why do you have to use the database field names inside the flex application? What alternative approach would you suggest Paul? I use them to help me keep track of everything, as I'm using both a MS SQL database and an ODBC linked database to a proprietry format. I'm open to alternative method suggestions. No virus found in this outgoing message. Checked by AVG. Version: 7.5.488 / Virus Database: 269.13.28/1021 - Release Date: 9/21/2007 2:02 PM
[flexcoders] Re: Eeeeek! Development grinds to a halt due to stupid syntax problem
--- In flexcoders@yahoogroups.com, Stephen Allison [EMAIL PROTECTED] wrote: Are you able to use the square brackets syntax for accessing properties ? This should work if your data objects are type object or are dynamic (?) var selectedGrowerAddress2:String = StringUtil.trim(String (event.currentTarget.growerSearchGrid.selectedItem[ADDRESS_LINE#2])); That worked Stephen. MANY thanks for your reply. I'd never have figured that on my own. No sleep for me tonight as I have to catch up. :( Thanks again.
[flexcoders] Re: Eeeeek! Development grinds to a halt due to stupid syntax problem
--- In flexcoders@yahoogroups.com, Doug McCune [EMAIL PROTECTED] wrote: Multiple people have already said this on both of the threads you posted with the same question: use square brackets to reference your properties. Try: selectedItem[ADDRESS_LINE#2] And if that doesn't work tell us that it doesn't and what happens if you try. My apologies for the double posting, and thanks to everyone who replied.