Skip to main content
Question

How to use the API of getting CFV columns

  • December 17, 2025
  • 3 replies
  • 27 views

Forum|alt.badge.img+2

How to use the API for getting CFV columns?
I'm creating a Quick Report,so I tried using the following API but it didn't work.
・SITE_DISCOM_INFO_CFV_API.Get_Cf$_Ordermanager(S.Contract)

However, by joining the views as shown below, I was able to retrieve the columns.

SELECT
SDI.Cf$_Ordermanager AS "ORDER MANAGER"
FROM 
 SHIPMENT_CFV S
  INNER JOIN SITE_DISCOM_INFO_CFV SDI
   ON S.Contract=SDI.Contract

3 replies

Forum|alt.badge.img+21
  • Superhero (Employee)
  • December 17, 2025

First issue is that the generated package is called: SITE_DISCOM_INFO_CFP

Second issue is that the in parameter to the generated method is not the key column CONTRACT. Instead it is the OBJKEY column.

So in almost all cases it is easier to join with the SITE_DISCOM_INFO_CFV view as you have done.

You can join with SITE_DISCOM_INFO to get the OBJKEY value and then use that into the get method. But that is not as fast performance wise as using SITE_DISCOM_INFO_CFV and reference the column from that view.


Forum|alt.badge.img+2
  • Author
  • Do Gooder (Partner)
  • December 18, 2025

@Tomas Ruderfelt 

Thank you for your reply.

 

I encountered an error in Quick Report when I tried to use the OBJKEY as a parameter in the API to create the following SQL statement:

SELECT
SITE_DISCOM_INFO_CFP_API.Get_Cf$_Ordermanager('3E43192E970C0BEBE063E45DEE0AF50B')
FROM
SHIPMENT S

 

Could you share a sample SQL query?


Forum|alt.badge.img+21
  • Superhero (Employee)
  • December 18, 2025

Something like this:

SELECT SITE_DISCOM_INFO_CFP.Get_Cf$_Ordermanager(SDI.objkey)
FROM 
 SHIPMENT_CFV S
  INNER JOIN SITE_DISCOM_INFO SDI
   ON S.Contract=SDI.Contract

WHERE shipment_id = 123

As you see you need the OBJKEY from SITE_DISCOM_INFO view so your select below is better:
SELECT
SDI.Cf$_Ordermanager AS "ORDER MANAGER"
FROM 
 SHIPMENT_CFV S
  INNER JOIN SITE_DISCOM_INFO_CFV SDI
   ON S.Contract=SDI.Contract

WHERE shipment_id = 123