The Alpha Software Forum Participation Guidelines

The Alpha Software Forum is a free forum created for Alpha Software Developer Community to ask for help, exchange ideas, and share solutions. Alpha Software strives to create an environment where all members of the community can feel safe to participate. In order to ensure the Alpha Software Forum is a place where all feel welcome, forum participants are expected to behave as follows:
  • Be professional in your conduct
  • Be kind to others
  • Be constructive when giving feedback
  • Be open to new ideas and suggestions
  • Stay on topic

Be sure all comments and threads you post are respectful. Posts that contain any of the following content will be considered a violation of your agreement as a member of the Alpha Software Forum Community and will be moderated:
  • Spam.
  • Vulgar language.
  • Quotes from private conversations without permission, including pricing and other sales related discussions.
  • Personal attacks, insults, or subtle put-downs.
  • Harassment, bullying, threatening, mocking, shaming, or deriding anyone.
  • Sexist, racist, homophobic, transphobic, ableist, or otherwise discriminatory jokes and language.
  • Sexually explicit or violent material, links, or language.
  • Pirated, hacked, or copyright-infringing material.
  • Encouraging of others to engage in the above behaviors.

If a thread or post is found to contain any of the content outlined above, a moderator may choose to take one of the following actions:
  • Remove the Post or Thread - the content is removed from the forum.
  • Place the User in Moderation - all posts and new threads must be approved by a moderator before they are posted.
  • Temporarily Ban the User - user is banned from forum for a period of time.
  • Permanently Ban the User - user is permanently banned from the forum.

Moderators may also rename posts and threads if they are too generic or do not property reflect the content.

Moderators may move threads if they have been posted in the incorrect forum.

Threads/Posts questioning specific moderator decisions or actions (such as "why was a user banned?") are not allowed and will be removed.

The owners of Alpha Software Corporation (Forum Owner) reserve the right to remove, edit, move, or close any thread for any reason; or ban any forum member without notice, reason, or explanation.

Community members are encouraged to click the "Report Post" icon in the lower left of a given post if they feel the post is in violation of the rules. This will alert the Moderators to take a look.

Alpha Software Corporation may amend the guidelines from time to time and may also vary the procedures it sets out where appropriate in a particular case. Your agreement to comply with the guidelines will be deemed agreement to any changes to it.

Bonus TIPS for Successful Posting

Try a Search First
It is highly recommended that a Search be done on your topic before posting, as many questions have been answered in prior posts. As with any search engine, the shorter the search term, the more "hits" will be returned, but the more specific the search term is, the greater the relevance of those "hits". Searching for "table" might well return every message on the board while "tablesum" would greatly restrict the number of messages returned.

When you do post
First, make sure you are posting your question in the correct forum. For example, if you post an issue regarding Desktop applications on the Mobile & Browser Applications board , not only will your question not be seen by the appropriate audience, it may also be removed or relocated.

The more detail you provide about your problem or question, the more likely someone is to understand your request and be able to help. A sample database with a minimum of records (and its support files, zipped together) will make it much easier to diagnose issues with your application. Screen shots of error messages are especially helpful.

When explaining how to reproduce your problem, please be as detailed as possible. Describe every step, click-by-click and keypress-by-keypress. Otherwise when others try to duplicate your problem, they may do something slightly different and end up with different results.

A note about attachments
You may only attach one file to each message. Attachment file size is limited to 2MB. If you need to include several files, you may do so by zipping them into a single archive.

If you forgot to attach your files to your post, please do NOT create a new thread. Instead, reply to your original message and attach the file there.

When attaching screen shots, it is best to attach an image file (.BMP, .JPG, .GIF, .PNG, etc.) or a zip file of several images, as opposed to a Word document containing the screen shots. Because Word documents are prone to viruses, many message board users will not open your Word file, therefore limiting their ability to help you.

Similarly, if you are uploading a zipped archive, you should simply create a .ZIP file and not a self-extracting .EXE as many users will not run your EXE file.
See more
See less

AA V12 Build 6699_5464 MySQL Issues

  • Filter
  • Time
  • Show
Clear All
new posts

  • AA V12 Build 6699_5464 MySQL Issues

    I just upgraded my client's AA server to 6699_5464, redeployed their applications from the same Build of the Developer environment and started to receive MySQL connection issues; e.g. "The database cannot find the record specified". I realize this doesn't HAVE to be an issue with AA, but I scoured the Release Notes for special instructions relative to SQL operations, to no avail, and tried the applications locally on my MySQL server as well and received precisely the same errors. It's not all files, just certain ones. This has brought my client's operation to a halt and I'm seriously considering going back to a previous version of the AA server until I can figure this out.

    So my question is: Has anyone experienced this kind of problem with 6699_5464, or are there Notes on this sort of thing? Just trying to see what kind of information is out there before downgrading.

    Thank You all in advance.


  • #2
    I've gotten this before when syncing, then deleting the record from the database, and then syncing again. However, I did notice around version 6311 Alpha had in the release notes that this was fixed. I haven't gotten it recently.

    UX Component - List with Detail View - Fixed an issue where an error would be generated if you tried to synchronize edits to a record that had been been deleted from the database. Now, the record is removed from the List.


    • #3
      The actual message is "The database could not find the data you requested". At first I thought the connection might be broken, but most of the functions in the app seem to find data just fine. But your message got me thinking that it might happen when I try to execute a particular type of SQL statement. I'm going to check. If I can't figure it out I'll have to downgrade, too much of a problem right now.

      Thanks for responding.

      Edit: This message is thrown when I execute an SQL statement of the form "UPDATE Table SET x = a, y = b, WHERE c = z". Not sure if it's pilot error or not.
      Last edited by nlk10010; 07-01-2020, 03:06 PM.


      • #4
        I have created a small test application: A UX with a single button that calls the following XBASIC internal function:

        function Test as c (e as p)
        dim connString as C = "{A5API=MySQL,Server='localhost',Port='3306',UserName='root',Password=':A5:B64:cXVpa3N0ZXA=',Database='cencarrier'}"
        DIM conn as SQL::Connection
        DIM flagResult as l
        flagResult =
        if flagResult = .f. then
        Test = "alert('Error opening initial connection.');"
        exit function
        end if
        'Specify if you are using Portable SQL syntax, or not
        conn.PortableSQLEnabled = .f.
        'Clear out any remnants from old invoicing. Shouldn't happen but just in case.
        SQLSelectStatement = <<%sql%
        UPDATE FreightBillHeaders SET Invoicing = null,InvoiceNumber = null,InvoicingOperator = null WHERE Invoicing = 1
        dim flag as l = conn.Execute(SQLSelectStatement)
        if flag = .f. then
        dim msg as C = "Error :" + rtrim(conn.CallResult.text) + "."
        exit function
        end if
        Test = "Done!"
        end function
        When SQLSelectStatement is run, the "flag = .f." clause is executed and conn.CallResultText = "The database could not find the data you requested". Does there look to be anything untoward that would cause this? If not, then how could I submit a bug report for something that by its very nature requires a MYSQL database?

        Any advice appreciated.



        • #5
          The only difference I see from what I would have done would have been to store my connection string in the AlphaDAO connection strings and then reference it similar to the follow

          DIM connStr AS C = "::Name::AADemo-Northwind"

          Might not make a difference. But besides that I don't see anything that stands out to me as wrong. You have created a pretty simple test case so Alpha should be able to reproduce. Just send them the entire ux, and send them the schema to create the database table on their end in mySQL.


          • #6
            Thanks for the feedback.

            Yes, this is driving me crazy. I've got an idea to make things even simpler, then I'll zip something up and send it in as a "bug" report. Given my experience, I'll never say it can't be pilot error, but I don't see where. By playing around it seems the problem doesn't crop up if I put a field that ISN'T being updated in the WHERE clause. But that shouldn't matter, it should be good SQL as I tested it in MySQL Workbench and got no complaints.

            In the meantime I'm going to revert my client's AA Server to the Feb version. Can't fool around with this.
            Last edited by nlk10010; 07-01-2020, 06:09 PM. Reason: More detail.


            • #7
              OK, I believe I've found the problem, hopefully it saves someone else who runs into it from tearing their hair out: Referencing the code I posted, when the WHERE clause of SQLSelectStatement ("Invoicing = 1") returns no records conn.Execute() returns False. In the version of the AA server I was using prior to 6699_5464 it returned True. True was fine, I didn't want the code to stop executing since no records satisfying "Invoicing = 1" was not an uncommon occurrence, but upgrading caused the code to fail. My guess is Alpha will say this is not a "bug", I may disagree, but it definitely is a change in behavior.

              Of course there could also be other things going on, but that is a particularly nasty little wrinkle which I'm glad I caught (thanks to Rusty's help and some intensive debugging sessions).


              • #8
                I could swear mySQL used to simply return NULL instead of a message stating no records found.
                I use sql_lookup to get a count of records that satisfy the filter (ex : answer = sql_lookup(cn,tablename, "invoicenumber = 1",coalesce(count(*),'NoData') ).

                I the use the if/then statement of
                 if answer <> "NoData" then
                ' Your alternative knowing there are no records that match the filter
                end if
                If your filter uses user defined functions you will need to do a regular query as sql_lookup
                does not works with non-standard mySQL functions.

                Hope this helps.



                • #9
                  Thank you.

                  For all I know MySQL may still return NULL, I'm just using the return value of conn.Execute() to error trap. Used to return .T., now it returns .F.. Exactly which SQL statements this affects I don't know, but I've gotten some more reports that other, similar queries are behaving this way. No UDFs in the WHERE clause, BTW.


                  • #10
                    I've been seeing this response using V11. The query being performed is returning no records. If you try to get a count of records that match the query, You will always get a number of 0 or something greater than 0. This should eliminate the problem.