SeedCodeHierarchy

Speed

SeedCodeHierarchy.Speed History

Hide minor edits - Show changes to output

Changed lines 5-6 from:
There are a few things you can do to make the hierarchy feel faster.
to:
There are a few things you can do to make the hierarchy feel faster:
Changed lines 19-20 from:
Edit the script "Build Hierarchy Level 1" and find the comment "Record the ID of the Level 1 Record". Right below that we set a variable $$Hy_ID to a calc using "Evaluate...". Replace this...
to:
Edit the script "Build Hierarchy Level 1" and find the comment "Record the ID of the Level 1 Record". Right below that we set a variable $$Hy_ID to a calc using "Evaluate...". In that step, replace this...
Added lines 1-37:
!! How Can I Speed Up the Hierarchy?

'''Usage Tips'''

There are a few things you can do to make the hierarchy feel faster.

-> If you're creating or deleting records, do so with formatting set to "plain" instead of outline or legal.

-> Use the filter in example two to show just the top-level record(s) you're interested in.

-> Switching formats re-draws the whole hierarchy, so switch formats when everything is closed, ''then'' open and close records as needed.

'''Code Changes'''

There is one code change you can make to increase the speed of the hierarchy about 12%. In the "Build..." scripts like "Build Hierarchy Level 1" we use global variables containing the ''names'' of your primary key fields instead of using the primary key fields themselves. This is a bit slower than using the actual field names, but it means you don't have to edit these scripts when hooking up the hierarchy.

You can speed the hierarchy up a bit by removing the reference to these global variables and using your own fields instead. Here's how:

Edit the script "Build Hierarchy Level 1" and find the comment "Record the ID of the Level 1 Record". Right below that we set a variable $$Hy_ID to a calc using "Evaluate...". Replace this...

-> Evaluate ( "HierarchyDataLevel1::" & $$Hy_IDFieldNameLevel1 )

...with the name of your primary key at level 1. In our sample data this would be:

-> HierarchyDataLevel1::CompanyID_kprime

Continue down this script to the next set variable line. There replace this...

-> not IsEmpty ( Evaluate ( "HierarchyDataLevel2::" & $$Hy_IDFieldNameLevel2 ) )

...with this, using the primary key of your level 2 record:

-> not IsEmpty ( HierarchyDataLevel2::ProjectID_kprime )

Do the same for the similar lines in each of the other level "Build..." scripts.

(855) SEEDCODE
[email protected]
Follow us: