There seems to be a problem when updating the new in memory session vars.
Stuff that works fine using LoggedInSystemUser (LISU) do not work when using the session vars. It almost seems like there is a transaction that is started and not letting me have access to the data.
Example, I have a Parent / child grid on a VP.
In the parent when I click on a row, I have a process that saves the ID in a session Var. Then I have the child grid refresh with the query "FIND Child where Child.ob_parent = SessionVars.parentID. This does not work but changing the sessionVars to LISU it works fine.
Bruce
SessionVars not working as should
-
- Posts: 7559
- Joined: Sun Apr 24, 2005 12:36 am
- Contact:
Re: SessionVars not working as should
This seems to work fine for us. Would you be able to create a small BSV that demonstrates the problem?
Aware IM Support Team
-
- Posts: 7559
- Joined: Sun Apr 24, 2005 12:36 am
- Contact:
Re: SessionVars not working as should
Definitely works for us. Please send the BSV
Aware IM Support Team
-
- Posts: 1471
- Joined: Tue Jan 24, 2017 5:51 am
- Location: 'Stralya
Re: SessionVars not working as should
Bruce,
Did this ever get fixed? I am having the same problem.
I am assuming it is a typo your example code seems to have an error
It seems that an object is being matched with an ID
Did this ever get fixed? I am having the same problem.
I am assuming it is a typo your example code seems to have an error
Code: Select all
FIND Child where Child.ob_parent = SessionVars.parentID.
-
- Posts: 2425
- Joined: Mon Jul 02, 2012 12:24 am
- Location: Ulaanbaatar, Mongolia
Re: SessionVars not working as should
Wouldn't it need to be....?
FIND Child where Child.ob_parent.ID = SessionVars.parentID
FIND Child where Child.ob_parent.ID = SessionVars.parentID
Cheers,
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
Mark
_________________
AwareIM 6.0, 8.7, 8.8, 9.0 , MariaDB, Windows 10, Ubuntu Linux. Theme: Default, Browser: Arc
Upcloud, Obsidian....
Re: SessionVars not working as should
ParentID WAS pointing to a BO. (sorry, bad naming).
Bruce
Bruce
Re: SessionVars not working as should
I have found earlier that the in memory session object (which by definition is not persisted) cannot be used for multiple reference attributes (1-n). It seems that the additional cross reference tables that are used for those attributes are not stored in the session object, therefore the reference attributes are not resolved. The work around is either to store the ID itself in the session object (rather than using multiple reference attributes), or use a persisted object for this purpose.
See also this earlier thread.
However, single reference attributes are possible I think.
See also this earlier thread.
However, single reference attributes are possible I think.
Niels
(V9.0 build 3272 - MariaDB - Windows)
(V9.0 build 3272 - MariaDB - Windows)