Shortcuts Good! Direct Nested Reference BAD!

If you have questions or if you want to share your opinion about Aware IM post your message on this forum
Post Reply
BLOMASKY
Posts: 1280
Joined: Wed Sep 30, 2015 10:08 pm
Location: Ocala FL

Shortcuts Good! Direct Nested Reference BAD!

Post by BLOMASKY »

Here is what I learned today.

I have a query using the OrderLines Table (which is owned by Orders) with a column with a presentation rule. My presentation rule WAS:

OrderLines.ob_Orders.deadline IS DEFINED

and the query ran SLOW. With 8 seconds between pages. Vlad told me that this is more costly than using a shortcut.
I changed it to

OrderLines.sc_Deadline IS DEFINED and it went to 2 seconds between paging!

Silly me, I assumed that they were identical. (Of course, now I have to go through my application and find where I thought I was smarter than Aware!

Bruce
PointsWell
Posts: 1125
Joined: Tue Jan 24, 2017 5:51 am
Location: 'Stralya

Re: Shortcuts Good! Direct Nested Reference BAD!

Post by PointsWell »

Interesting - wish there was a way to find deep references...
BLOMASKY
Posts: 1280
Joined: Wed Sep 30, 2015 10:08 pm
Location: Ocala FL

Re: Shortcuts Good! Direct Nested Reference BAD!

Post by BLOMASKY »

Me also. I never knew that it would make that big of a difference. Although, thinking about it, it does sort of make sense. If there is a shortcut, then when the master record is read, the child table(s) are read. However, if I have a presentation rule that says BO.parentBO.someattribute then aware has no clue that the table has been read.


Hummm....

Bruce
aware_support
Posts: 7299
Joined: Sun Apr 24, 2005 12:36 am
Contact:

Re: Shortcuts Good! Direct Nested Reference BAD!

Post by aware_support »

IMPORTANT: Please note that this only applies to "applicability conditions" - for operations, menu items, presentation rules etc.

This does NOT apply to standard business rules used in objects and processes. In standard rules using nested references is better than using a shortcut. Rather, you CAN use a shortcut if it is already defined (for example, it is needed by a query). But it is WRONG to define a shortcut just to use it in a standard business rule!
Aware IM Support Team
Post Reply