Question

7
Replies
1871
Views
Despot Jevric (DespotJ1)
Sopra Steria AG

Sopra Steria AG
CH
DespotJ1 Member since 2015 4 posts
Sopra Steria AG
Posted: October 5, 2016
Last activity: October 5, 2016
Posted: 5 Oct 2016 2:27 EDT
Last activity: 5 Oct 2016 23:00 EDT
Closed

JavaScript tools.getDatabase

I tired to call the database in a HTML-Rule.
The Script language is JavaScript and i will always get an exception when i try to call a function with tools... (I tried also to import the publicAPI, but it doesn't work)
I need a solution to call the Database in Javascript and to put the result on the var Result

HTML-Rule
<script language="JavaScript">
switch (Action)
  {
     case "openCase" :
          Database db = tools.getDatabase();
      
          ClipboardPage lp = tools.createPage("Code-Pega-List", "");
          lp.putString("pyMaxRecords", "1");
          var aSQL = "select TEST as \"TEST\" from Table where Field = 'ABC'";
          var Result = db.executeRDB(aSQL, lp);
         ...
         break;
  }
</script>

Low-Code App Development Data Integration Java and Activities
Moderation Team has archived post, This thread is closed to future replies. Content and links will no longer be updated. If you have the same/similar Question, please write a new Question.