3 Replies Latest reply on Oct 26, 2009 7:44 AM by David_F57

    MYSQL and Flex problems




      I have an application that has to get a group of database entries.

      My first problem is with the "configure return type" utility. If I return the result from the mysql query, I am told it is a "generic object", and can not configure it as a new type.

      In another case, where I use a service that I manually ported from beta 1, and can use the return type I created at the time, I get a list of objects, all of which include a date field. I know the PHP gets the full date-time string from mysql(via file_put_contents logging), but Flex only recieves the year(2009) as an intiger. I need to display the date itself in the a datagrid, but I have no idea how to make it work, since I don't know where I lose the month, day, or time.

      Any help will be appreciated!


      Thanks Alot!


        • 1. Re: MYSQL and Flex problems
          David_F57 Level 5



          The php returns the date as a string, firstly you should look at what the field in the mysql DB as date/datetime/timestamp all return different date strings. in your result function trace the date info to see what string is being returned. The date issue has be discussed at length in a previous post read this it may help you





          • 2. Re: MYSQL and Flex problems
            lee-orr Level 1

            Thre result I get is the string "2009" in the result function. But in the php, when I checked the rows manually and used "file_put_contents" to log, I got the whole string: "2009-10-26 11:10:26". I looked at that thread, and didn't find my problem there... though I didn't read through all the posts intently at the time. Doing that now. Any ideas?


            Thanks alot!



            • 3. Re: MYSQL and Flex problems
              David_F57 Level 5


              Without seeing your code its just guess work.....


              Anyway it sounds like your result string is being truncated, have you tried doing a simple example from scratch as there where some changes in beta 2 and this may be causing your problem. A new generated test case is always a good way to rule out the manual updating to beta 2 instead of chasing what in the end will probably be a very simple change in the generated data objects.