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

Capturing Customer Options in their profile

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

    Capturing Customer Options in their profile

    Hi All

    We install and maintain tropical plants in our client's offices. As part of the installation of the plants we select containers that we plant the tropical plants in.

    We want to capture the limited number of containers chosen for that client (there would never be more than say 20 and usually it is 2 to 4) and make that info available in the future. The container choices are already loaded into another A5 table.

    I am assuming that I would add a field or fields to the client table to record a pointer back to the original container part record. Should I add say 20 extra fields to the client table, or can I add multiple container names into one field in the client table. I would prefer the one field option but don't know how I would be able to use that info in the future.

    Does anyone have any ideas that I can use?

    Thanks for the help.

    Steve

    #2
    Re: Capturing Customer Options in their profile

    I would highly suggest you create a table that maps the client ID to the container ID. The combination of client ID & container ID can be used as your primary key. At a minimum, the combination of the two fields should be unique and both fields should never be NULL. This allows you to map a variable number of containers to clients.

    You would use a join on the Client table with the Container table using the intermediate Client to Container table.

    I would advise against creating 20 extra columns in your client table for this information. For starters, that's 20 extra fields that are added to every record - taking up space. And if your average case is 2-4 containers per client, you've created 16-18 columns of waste. Also, it's much MUCH MUCH easier to generate reports, grids, etc, if your data is normalized out to 3rd normal form (client --1:many-> client2container <-many:1-- container).
    Alpha Anywhere latest pre-release

    Comment


      #3
      Re: Capturing Customer Options in their profile

      Hi

      Thanks for the reply.

      Yes I see where you are going with a second table. We already have a unique Customer field that we can use as a link betwen tables. That is what we will do.

      Within the table, I was thinking along similar lines with avoiding many unused fields in the new table but how do I structure the info so that I can capture and then reuse several container part numbers in a single record?

      The end result I want is to use the container part number as a list that we can select from for online forms that staff would fill out so that they only see the types of containers installed at that site and when they select the part number we would fill in the form using other info from the underlying container profile record.

      This is what I am stuck on and any help would be appreciated.

      Comment


        #4
        Re: Capturing Customer Options in their profile

        Originally posted by Stephen Schell View Post
        Hi

        Thanks for the reply.

        Yes I see where you are going with a second table. We already have a unique Customer field that we can use as a link betwen tables. That is what we will do.

        Within the table, I was thinking along similar lines with avoiding many unused fields in the new table but how do I structure the info so that I can capture and then reuse several container part numbers in a single record?

        The end result I want is to use the container part number as a list that we can select from for online forms that staff would fill out so that they only see the types of containers installed at that site and when they select the part number we would fill in the form using other info from the underlying container profile record.

        This is what I am stuck on and any help would be appreciated.
        I'm moderately confused about what you're trying to do.

        If you wanted to store all the part numbers in a single field, you could dump them in a field and use a delimiter of sorts to separate each ID. This would not be very fast to search/join. Maybe that's a non-issue for you?

        There are lookups available for textboxes and combo boxes in alpha. For example, for a combo box you can specify a dynamic lookup using a connection string & query.

        There is an additional tool called "lookup and fill in fields". You can add that action to the on change event for the combo box or textbox. Look up the container info using the container_id & populating relevant fields.

        Ascii below. Because I'm not following what you're talking about having unique Customer fields for use as a link between tables.

        Code:
        Customer table:
        +------------------------------+
        | Customer                     |
        +------------------------------+
        | Customer_Id                  |
        +------------------------------+
        | ........                     |
        +------------------------------+
        
        Container table:
        +------------------------------+
        | Container                    |
        +------------------------------+
        | Container_Id                 |
        +------------------------------+
        | ...                          |
        +------------------------------+
        
        Mapping table (one entry per customer per container; so if your customer has 4 containers, there would be 4 entries):
        +------------------------------+
        | ContainerToCustomer          |
        +------------------------------+
        | Customer_Id                  |
        +------------------------------+
        | Container_Id                 |
        +------------------------------+
        
        
        List of all container records available for that customer:
        
        SELECT Container.*
        FROM Container 
        	INNER JOIN ContainerToCustomer 
        		ON ContainerToCustomer.Container_Id = Container.Container_Id
        WHERE ContainerToCustomer.Customer_Id = :CUSTOMER_ID
        Alpha Anywhere latest pre-release

        Comment


          #5
          Re: Capturing Customer Options in their profile

          Hi Sarah

          Thanks for the effort that you have made to help. It has all clicked in now and I can move forward.

          Thanks

          Comment

          Working...
          X