Hi Everyone, We have a requirement where we need to Store data in Session O

Hi Everyone,
We have a requirement where we need to Store data in Session Object. I tried to fetch session object but i am getting error while fetching it.
So I tried storing data in servicecontext object using a custom function by using the following methods
sc.setAttribute(attributeName,AttributeValue) and sc.getAttribute(attributeName) . But they are not working as expected.Can any one suggest me how to fetch a session object or Any other alternate approach to store data in a session...

OriginalPostID-81082

OriginalPostID-81082

  Discussion posts and replies are publicly visible

Parents
  • We have 3 applications in our project. The database selected in Homepage should be used in all the 3 applications. Each application has several PortalPages/Processmodels. How can we pass the database name as a parameter to every Processmodel?
    Do you mean that ,In all the pages we have to use a common processmodel where user selects a database instance and then redirect to the respective processmodel with database as a parameter? I think this is not possible because client doesn’t want to select a database everytime he navigates to another page/application.He prefers to choose the database only once at login page/homepage.
    Even in User’s CustomFields/Session approach we are fetching database name when the processmodel starts and storing it in processvariable and then passing it to all subprocesses.
    And regarding your “session Independent Framework” comment , I think it wont be a big problem in our project because most of our usecases are like “Searching a particular table(say Contact/claims/XXX) and Performing actions on that table like Add a new xxx/Update XXX/delete XXX” or Importing Zip/sql/dump files to import data into tables or Changing Table constraints like primary key,unique validations etc.What I want to say is there are no tasks assigned to any users and all the processmodels are completed by the initiator himself in a single run. As of now there are no long time running processes and almost all the processes are short(Activity chained with 1 or 2 forms) and are expected to be completed in a single run and are not supposed to be running between multiple logins
Reply
  • We have 3 applications in our project. The database selected in Homepage should be used in all the 3 applications. Each application has several PortalPages/Processmodels. How can we pass the database name as a parameter to every Processmodel?
    Do you mean that ,In all the pages we have to use a common processmodel where user selects a database instance and then redirect to the respective processmodel with database as a parameter? I think this is not possible because client doesn’t want to select a database everytime he navigates to another page/application.He prefers to choose the database only once at login page/homepage.
    Even in User’s CustomFields/Session approach we are fetching database name when the processmodel starts and storing it in processvariable and then passing it to all subprocesses.
    And regarding your “session Independent Framework” comment , I think it wont be a big problem in our project because most of our usecases are like “Searching a particular table(say Contact/claims/XXX) and Performing actions on that table like Add a new xxx/Update XXX/delete XXX” or Importing Zip/sql/dump files to import data into tables or Changing Table constraints like primary key,unique validations etc.What I want to say is there are no tasks assigned to any users and all the processmodels are completed by the initiator himself in a single run. As of now there are no long time running processes and almost all the processes are short(Activity chained with 1 or 2 forms) and are expected to be completed in a single run and are not supposed to be running between multiple logins
Children
No Data