Homelab, Linux, JS & ABAP (~˘▾˘)~
 

[CAP] Query teamMembersSize from SuccessFactors

const sfsfSrv = await cds.connect.to('sfsf')

// Option 1: Query Notation
const response = await sfsfSrv.run(SELECT`teamMembersSize`.from`User`.where`userId = ${req.user.id}`)
console.log("option 1: " + response[0].teamMembersSize)

// Option 2: HTTP method-style
const response2 =  await sfsfSrv.get(`/User('${req.user.id}')/teamMembersSize/$value`)
console.log("option 2: " + response2)

Leave a Reply

Your email address will not be published. Required fields are marked *