14 Replies Latest reply on Jan 8, 2015 2:03 PM by bhagara

    Script required to copy from one table to another

    MarkNZ

      Hi all,

      I am creating a new Telemarketing Table with layouts to suit.

      However i would like to Commit / send the positive contacts from the telemarketer table to a seperate CONTACTS TABLE NEW RECORD area.

      How is this best done? Create a commit button on the Telemarketing contact layout form, scripted somehow to send the potential contact into the Main New CONTACT RECORDS Form.

      I want to avoid a lengthy, hassled importing procedure. Also would like the new contact to receive its serial number only when its introduced into the the Main CONTACT form layout.( module)

      I feel it best for the telemarketer to export/ commit the records from there end to be picked up from someone else to follow the enquiry through. There would need to be a sort done on the TeleM side to find all positive potential customers, then actioned ( sent from there )

      I presume a script would best do this, could someone be so kind to suggest

       

      Your Thoughts GREATLY Appreciated :D Mark

        • 1. Re: Script required to copy from one table to another
          comment

          mark0123 wrote:


          i would like to Commit / send the positive contacts from the telemarketer table to a seperate CONTACTS TABLE NEW RECORD area.

          How is this best done?

           

          IMHO, it's best not done. Instead of shuffling records around, keep them in the same table and mark "real" contacts (as opposed to potential ones) as such.

           

           

          mark0123 wrote:

           

          Also would like the new contact to receive its serial number only when its introduced into the the Main CONTACT form layout.

           

          For what purpose?

          • 2. Re: Script required to copy from one table to another
            usbc

            Mark,

            I can certainly see why in some situations it is preferable to keep yet unqualified contacts out of your main data base so as not to explode its size and keep the speed as good as can be.

             

            Like most things in FileMaker there are several methods available. Most of them will involve using a set field step or look up. If you search these forums for create duplicate records etc. you will see various approaches. Essentially, you will have a relationship for this purpose and swap the key field content either via a global or variable between the two tables. Once the "Tele-Source" relationship is established you can decide which suits you best. It's much like creating a invoice record from a Contacts table. HTH.

            • 3. Re: Script required to copy from one table to another

              Hi Mark,

               

              It is simple to add a Type field which designates whether Prospect or Client.  If Joe Smith call, you will have to search two tables.  If you track information while someone is prospect and then move the person to Clients you must deal with moving their history as well.  And if wishing a report of ALL contacts summarized by state or other generalized statistics, the reporting will be difficult, requiring temp table and complex scripting.

               

              But the biggest issue with moving records is risk of break during system failure, glitch, network issue.  Why expose your data to needless risk when setting a single field from Prospect to Client will work?  As for number of records being good reason to split data which is actually one entity, it can be good reason but only when numbers are very high and that is not the situation presented.

              • 4. Re: Script required to copy from one table to another
                MarkNZ

                Hi thanks for your reply..I wondered about putting the telemarket fields into the one main CONTACTS table...I may have to consider this again

                As for the serial numbers, I just wanted to keep the numbers running true in the Main CONTACTS

                Thanks again.

                • 5. Re: Script required to copy from one table to another
                  MarkNZ

                  Hey thanks..Im going to revisit the thought you mentioned refering to an Invoice & Contacts relationship

                  cheers. Mark

                  • 6. Re: Script required to copy from one table to another
                    MarkNZ

                    Hi very good points you have made..especially if someone rings in, searching in 2 areas..could become a pain.  History deatails from telemarketer, i was just going to create a notes area in the main CONTACTS to give a breif mention of notes..

                    Thanks for your thoughts..

                     

                    ALSO

                    Can I limit the access for the telemarketer to just the telemarketer BUTTON which goes to 3 different TeleM layouts only...so they dont have access visually to any other parts of the Main Database??

                    • 7. Re: Script required to copy from one table to another
                      MarkNZ

                      Can I limit the access that the telemarketer has to just the Telemarketer section ( Layouts) If I put all fields into the One CONTACTS Table, instead of having two tables

                      Would it be worth while to placing a triger script to sort the Main Contacts ( non TelM ) when the main contacts button is pushed.

                      & do the same for the teleM button?....your thoughts

                       

                      ALSO

                      Can I limit the access for the telemarketer to just the telemarketer BUTTON which goes to 3 different TeleM layouts only...so they dont have access visually to any other parts of the Main Database??

                       

                      Mark

                      • 8. Re: Script required to copy from one table to another
                        comment

                        Which fields are unique to which type of contact?

                        • 9. Re: Script required to copy from one table to another
                          MarkNZ

                          Hi Mike,

                          Ive opted to put additional fields into the one main CONTACT table & uniquely identify them differently ( doing away with the Telemarketer table. This will avoid the importing and or copy & paste option.

                          I will script the teleM button to find all teleM contacts. what do you think?

                           

                          Thanks Mark

                          • 10. Re: Script required to copy from one table to another
                            comment

                            I don't think you have answered my question. If I understand correctly, a person is first a prospect, then (possibly) a customer. What information - if any - needs to be added at the point where a prospect becomes a customer?

                            • 11. Re: Script required to copy from one table to another

                              Mark asked, "Can I limit the access for the telemarketer to just the telemarketer BUTTON which goes to 3 different TeleM layouts only...so they dont have access visually to any other parts of the Main Database??"

                               

                              You can use privileges to restrict User view of certain records particularly if critical but to control display you can use script trigger which looks at the type field and changes the layout to the proper display OnRecordLoad.

                               

                              But Michael's question is important... your TeleM can use same fields for same purpose (website, name, address etc) and it is only fields which aren't in common that should to be considered further (for possibly placing in secondary table).  And different layout may NOT be required since you can possibly place those different fields behind tab control or in portal.

                               

                              Structure first and only then worry about the display of it. :*)

                              • 12. Re: Script required to copy from one table to another
                                MarkNZ

                                Hi Michael, The only extra information would be a Action list ( send or email brouchures, company profile etc) for the person to follow throught the prospect.

                                The main thing is setting up layouts to suit the telemarketer flow & speed.

                                 

                                thanks

                                Mark

                                • 13. Re: Script required to copy from one table to another
                                  MarkNZ

                                  Hi LaRetta, yes I think we are solving the issues now, Iam going back to the one table idea with extra tab to adopt the additional fields.

                                   

                                  Would i need to put a trigger on each button which searches for the account user to see if they are allowed access. is this the best way?

                                   

                                  Regards Mark

                                  • 14. Re: Script required to copy from one table to another
                                    bhagara

                                    this kind of restricted access is certainly possible by just removing their access to layouts except for where you take them with buttons... having said that, the fall-back plan to make certain a user cannot see anything they shouldn't is to use the Privilege Set and the restrictions there.  That's pretty much what it's for.