How to get the version values for child article from Kb Knowledge table using business rule

String
Kilo Sage

I'm trying to create a child article from parent and trying to fetch the version value from the child article .So am using business rule :

1.When after 

2.Insert

3.Kb_knowledge

 

In advance ,below is the simple code 

 

(function executeRule(current, previous /*null when async*/ ) {

 gs.info("Checking KB log" + current.getDisplayValue("version"))

})(current, previous);

 

But am unable to get the version ,Please guide me 

If version will take  time to load in Kb_Knowledge table ?

5 REPLIES 5

Anand Kumar P
Giga Patron
Giga Patron

Hi @String ,

In OOB kb_knowledge i cannot see any field with name version
But in kb_knowledge_base_list table i am able to see

AnandKumarP_0-1701970996798.png

Mark it as helpful and solution proposed if it serves your purpose.

Thanks,

Anand

Hi @Anand Kumar P  thanks for your quick reply ,below is the knowledge record looks like in kb_knowledge table and trying to fetch version value 

Screenshot 2023-12-07 at 5.50.12 PM.png

@String Try below script 

gs.info("Checking KB log" + current.version.getDisplayValue());

or

gs.info("Checking KB log" + current.version.toString());

 

Hi @Anand Kumar P  still not returns any value !