3 Replies Latest reply on Sep 12, 2013 9:13 AM by IT_User

    Editable Portal Numbering



      Editable Portal Numbering



                I'm trying to have portal lines numbered.  The lines are created by a script and can be deleted.  The lines should not be renumbered when something is deleted.  Something may take its place or there is just a gap.

                I was thinking of having the numbering field editable that when a new related item has been created it just puts a higher number until someone changes it.

                I would have it autoenter, but since it is completely blank and at least needs the foreign key field to know what to relate to, then that hasn't really work.

                Also, there is a layout that has the portal on it to create new related items, but there is also another iOS layout that does not have the portal in which related items can be added there.


                Any help would be appreciated.



        • 1. Re: Editable Portal Numbering

               I don't know what your number system is based on so I can't really give you an answer.  (Why would there be a gap in the numbering)   Most of the time the record number is used to number portal lines, but this will renumber if an item is deleted.  You would not need a script to create a number in this method.  Why would someone need to change the number?

               I don't understand your comment.  You would have auto enter, but since it completely blank and at least needs the foreign key field to know what to relate to.    Your foreign key field should be a separate field from any other numbering field.  Key fields should be more of a behind the scene.

               You can have portals on  iOS layout.  You sounds like you need to add your portal to your iOS layout.


          • 2. Re: Editable Portal Numbering

                 Use a script to create new records in your portal instead of the "allow creation.." relationship option. The script can number the record with Max ( PortalRecords::numberField ) + 1 after creating the new portal record.

            • 3. Re: Editable Portal Numbering

                   S Chamblee:

                   Thank you for your reply.

                   Basically the numbering system would be like 1, 2, 3... (We have a separate actual ID field, but don't want to show that one.)  This numbering will not be used for any key field.

                   There would be a gap, if one of the records has been deleted. Ex. If the numbering is 1, 2, 3, 4, 5, and 3 is deleted, then the numbering would be 1, 2, 4, 5.  (Don't want it to renumber to 1, 2, 3, 4)

                   A person then would create a new record, which would need to replace 3, but it would fill in a number like 6, and then the person can edit that number to 3.

                   So, my comment on the one field being blank and the foreign key field.  It would need the foreign to know the parent record, so that from the parent I could get the set of related records.  (Once I get the set of related records, I could count them or get the Max number in that set or whatever.)

                   I can have a portal on an iOS layout, but would prefer not to have one.



                   Thank you, I think that is kind of what I'm looking for.  I had originally done something like that in SQL, but it had caused some problems.