Question

Quick Report (Crystal Report) web_util_api and SQL Expressions

  • 20 May 2020
  • 2 replies
  • 366 views

Userlevel 7
Badge +18

I am trying to create a Fire Roll Call that lists current employees when they are classed as present. 

 

When you look at the Present Employees screen in IFS the view is COMPANY_PERS_ASSIGN_BASIC. The Present column calls the following API to get the result of whether they are present or not:

 

Time_Pers_Diary_Clock_Util_Api.Is_Present_Offset(company_id, emp_no,null ) 

 

and returns a 1 or 0.

This was working fine in my Crystal Report but is not available when you add the WEB_UTIL_API.  I have tried adding it as a custom field within the COMPANY_PERS_ASSIGN_BASIC view but cannot seem to get this to work.  

 

How can I get the result of the API into my report?  

 

Any advice gratefully received. 


2 replies

The purpose of the CRYSTAL_WEB_UTIL_API.CR_WEB_INIT is to prevent unauthorize execution of the database statements thus you need to grant permission for the method that you need to execute for the actual executing user. May be you can verify the security permission for the end user?

Userlevel 3
Badge +8

I have similar issues than @johnw66 . After adding the CRYSTAL_WEB_UTIL_API.CR_WEB_INIT to the report I’ll loose the SQL expressions from the crystal report developers client. The SQL expressions Used are either API get functions or sub queries.

 

As this happens to the person who develops the Crystal Report not IFS end user it causes difficulties. To which user should I add the permissions mentioned in order to see the SQL expressions in the Crystal Report development UI? Many thanks for Your advice!

Reply