Alpha Software Mobile Development Tools:   Alpha Anywhere    |   Alpha TransForm subscribe to our YouTube Channel  Follow Us on LinkedIn  Follow Us on Twitter  Follow Us on Facebook

Announcement

Collapse

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

List New Record Save is creating duplicate records

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    List New Record Save is creating duplicate records

    HELP - SOS

    Version 12.4.6.2.6, Build 7295

    I have kind of a "more complex" form with 4 list controls and 4 detail window containers. Nothing extremely crazy and the form seems to load quickly and without any issues.

    List 1 is Parent list
    List 2 is a Child list of List 1
    List 3 is a Child list of List 2
    List 4 is a Child list of List 2

    Each list has a detail view with Field Map and as stated these detail views are accessed via embedded popup window containers.

    Synchronization Policy is Client to Server, so edits are automatically pushed to the server when a user does a save.

    Each time a record is added/edited/deleted from any list then all lists need to refresh data to update calculated fields based on sums of fields in their respective child lists.

    The issue I'm having is that in any of the lists, when I add a record and then click save two duplicate records are created. The first one immediately and then the second one after a slight delay. Has anyone experienced this situation with list controls?

    Thanks,
    Jeremy



    #2
    It's even worse than I thought. As I continue to debug this problem, the last 2 new records I added, created 3 triplicate records of the one I was adding.

    Comment


      #3
      Seems to have something to do with the views I created for each child list that I used to calculate the totals for display. I removed all joins to views and am no longer getting duplicate entries.

      Comment


        #4
        more than likely - and this is just a guess is that you were adding a record to the multiple views as well as the records original table.
        NWCOPRO: Nuisance Wildlife Control Software My Application: http://www.nwcopro.com "Without forgetting, we would have no memory at all...now what was I saying?"

        Comment


          #5
          Originally posted by CharlesParker View Post
          more than likely - and this is just a guess is that you were adding a record to the multiple views as well as the records original table.
          Anything's possible on certain days between Alpha and myself. However, I specifically set the views to read only in the Table Settings. I'd hope that would cover the issue you mentioned but again, it's hard to tell. In any event, thanks for the reply. The forums become far more useful when experts tackle the tougher questions rather than everyone just looking at the simple ones.

          Comment


            #6
            There are times when the best way to control changes to your sql table(s) is to write the code yourself.
            You also gain the advantage of being able to use any UDFs you may have created.
            Gregg
            https://paiza.io is a great site to test and share sql code

            Comment


              #7
              It turns out the view had nothing to do with it. I removed all views from the equation and the issue still exists. I've submitted a bug report and expect they will need copies of the project and database in order to dig deeper into this.

              In the event someone stumbles on this issue down the road I'll post a follow up if I get anything figured out with this.

              Comment


                #8
                I would add a record using your favorite sql editor or even the Alpha Anywhere SQL command window.
                If it doesn't do it there, then I would turn the feature to display sql commands on to see what it's doing.
                Gregg
                https://paiza.io is a great site to test and share sql code

                Comment


                  #9
                  Jeremy,

                  This may have nothing to do with you problem, but I never use Alpha's built-in parent-child list sync feature. I simply keep the lists separate and refresh as needed when changing or adding rows in the parent. In the past when I had a parent list with a bunch of child lists, it was too slow to load. Hand-coding it brought the speed up to what you expect. But again, maybe this has nothing to do with your situation.
                  Peter
                  AlphaBase Solutions, LLC

                  [email protected]
                  https://www.alphabasesolutions.com


                  Comment


                    #10
                    I agree with Peter write the record yourself - and I would add this, if your application is a web application and not an app, then I take the view if users are online they can use it - or they are offline and can't. Where else in this age have your seen a sync button on any application or webpage you use daily - I've never seen it - and I don't use it in aa unless, as I have found it better to just not offer offline capability, and then if specifically asked, answer yes and price it accordingly. Clients will say yes and them most will never use it, and they do not understand the work involved making it work reliability, the World has moved on from offline, these days it's everywhere.
                    As always tread your own path, but remember the well worn path is worn for a reason.
                    Pete
                    Insanity: doing the same thing over and over again and expecting different results.
                    Albert Einstein, (attributed)
                    US (German-born) physicist (1879 - 1955)

                    Comment


                      #11
                      I figured out the cause of this problem and it's rather bizarre. I am working in a multi developer scenario with Git. Here's what I was able to figure out and repeatedly trigger the error.

                      If I had the live application open in a browser and another developer deployed some changes that threw something out of sync internally that was causing my duplicate records. If I didn't have the live application open and went into it fresh after a deployment there is no issue. If I had the application open and did a full browser refresh no problem. Only when I had the application open, someone deployed some changes (not necessarily changes to the component I had open but changes to other components in the project), and I didn't refresh I would get duplicate errors.

                      The bizarre part is that I found a direct correlation between the number of times the other developer deployed updates and how many duplicate records I would get.
                      1 Deploy = 2 records (original + 1)
                      2 Deploys = 3 records (original + 2 duplicates)
                      3 Deploys = 4 records (original + 3 duplicates)

                      I didn't test beyond 3 deploys but proved without question this was the cause. I even turned the tide and had the other developer who was not having any issue open the page I was getting duplicates on. I then deployed the project and sure enough he started getting duplicates. I can't say for certain how widespread this is. Is it specific to my scenario with Parent/Child/Grandchild lists? Would it happen with a grid? Is it a session issue? We deploy updates pretty regularly and this is the first time I've seen this issue, but it's hard to tell with so many end users who has what open and at what time.

                      I have submitted the issue to Alpha, we'll see what they come back with.

                      Thanks,
                      Jeremy


                      Comment


                        #12
                        You might want to activate the sync log feature and see if it helps.

                        Comment

                        Working...
                        X