Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 4377 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I have a portal that lists the number of steps in a process.

I want, when you first select the portal, for it to populate Step # with 1. And then when going to the next line, Step # = 2.

I've tried messing around with an auto enter calculation, but cannot seem to get it to trigger.

  • 1 month later...
Posted

Do you want the numbering to be part of the portal table's data or instead as a temporary numbering? And either way, what is the purpose of these numbers? Should each user have ability to rank the records differently?

  • 3 weeks later...
Posted

Do you want the numbering to be part of the portal table's data or instead as a temporary numbering? And either way, what is the purpose of these numbers? Should each user have ability to rank the records differently?

Hi Laretta,

 

Sorry for the delayed response here... But yes, I want it to be a part of the portal table's data.. The purpose is to create similar to a list of steps to complete a process..

Posted

The order records appear in a portal depends upon relational sort and portal sort. Are they sorted? How do you determine the order? What if new steps are added - you will need ability to reorder them, right?

So is this a one-time setting of the order through all records and then reorder only 'the portal set' if new portal record is added? Should script just start at first related record and serialize them, starting the serial again with each new parent? How do you envision this will be administered day to day?

Posted

The order records appear in a portal depends upon relational sort and portal sort. Are they sorted? How do you determine the order? What if new steps are added - you will need ability to reorder them, right?

So is this a one-time setting of the order through all records and then reorder only 'the portal set' if new portal record is added? Should script just start at first related record and serialize them, starting the serial again with each new parent? How do you envision this will be administered day to day?

 

It's not quite like that. There are multiple things that can be associated with the same step #.

 

I just want the default value to be incremented by 1 to the previous Step #.

Posted

That is not providing enough information, I'm afraid. If all you want is number just type @@ in the portal row. If you need to enter serialized data to the portal records we need my questions answered. :-)

Posted

Here I am, going to make a suggestion with insufficient information ... which I know never to do ... and it seems I am going to do it anyway, LOL. If you have a Number field called Order then you can add an auto-enter calculation to it which is:

GetNThRecord ( table::Order ; Get ( recordNumber ) - 1 )

But again, it depends upon how the records are created and their sort order and found set at the time. Without more information that is all I can suggest.

Posted

That is not providing enough information, I'm afraid. If all you want is number just type @@ in the portal row. If you need to enter serialized data to the portal records we need my questions answered. :-)

I'm not really sure how more to answer your questions...

 

I'll try explain the scenario a bit better:

 

I have a table 'Protocols'. Each protocol can have many Steps attached to it. There is a portal that displays the 'Steps' associated with that protocol.

 

Protocol 1 contains:

Step 1 -  1x tablet 1

Step 1 - 2x tablet 2

Step 2 - 1x tablet 1

 

So, each step line contains details about a tablet that this person must take. For step 1 which may go for 10 days, they must take 1x tablet 1, and 2x tablet 2. At the end of 10 days, they move to step 2 and only need to take 1x tablet 1.

 

Pretty much If the portal contains the above information, I want the next line to be listed as Step 3.

 

While writing this, I realize I can have a button that creates the new line, finds the highest step #, then adds 1 to it. But I would prefer to have it without a button and just use the standard portal entry for a new line.

Posted

I want, when you first select the portal, for it to populate Step # with 1. And then when going to the next line, Step # = 2

There is no way, under your current construction, for a computer to know that those first two child records should be combined into one step so how can it number them for you? Why not have the Order field (number) in the portal and manually number them when the child records are created? Then portal can be set to sort by Order?

While writing this, I realize I can have a button that creates the new line, finds the highest step #, then adds 1 to it.

And for first time, I now know you want to add new records to the portal. Yes, the additional information was needed.

If you simply want an auto-enter when new record is created which is 'prior value plus 1' then go to your Order field in your child table and set auto-enter by calculation =

GetNThRecord ( Order ; Get ( RecordNumber ) - 1 )

ADDED: I had also asked about your portal or relationship sort and do not see where you answered. We cannot use calculation since I assume the User may need to change the number if system increments when it should be prior step's number.

Posted

AGAIN ... If these records already exist, still not clear, then system can't number because system wouldn't know what to put (when to duplicate the number and when not). Even script would not work.

Or is there a theory we can use to determine if two records should be grouped? A Type field or other indicators?

Posted

Protocol 1 contains:

Step 1 -  1x tablet 1

Step 1 - 2x tablet 2

Step 2 - 1x tablet 1

...

Pretty much If the portal contains the above information, I want the next line to be listed as Step 3.

 

See if the attached works for you. Note that this is not 100% foolproof: if two fools users are happening to create a new step for the same protocol at the same time, they might both get the same step number. But I believe it will work for your purpose, since - IIUC - users will revise the step numbers manually anyway; this is just a data entry aid.

OrdinalAE.fp7.zip

  • Like 1

This topic is 4377 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.