Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 2175

Re: change audit level with JDK doesn't work

$
0
0

Hi Sophie,

 

I gave a quick try on the below code snippet & it is working as expected. I have tried this on BI 4.1 SP3.

I am posting my code snippet below for your reference:

-----------------------------------------------------------------------------

import com.businessobjects.sdk.plugin.desktop.auditeventinfo2.IAuditEventInfo;

import com.businessobjects.sdk.plugin.desktop.auditeventinfo2.IAuditEventInfo.AuditEventLevel;

import com.crystaldecisions.sdk.exception.SDKException;

import com.crystaldecisions.sdk.framework.CrystalEnterprise;

import com.crystaldecisions.sdk.framework.IEnterpriseSession;

import com.crystaldecisions.sdk.occa.infostore.IInfoObjects;

import com.crystaldecisions.sdk.occa.infostore.IInfoStore;

public class ConfigureAuditLevel {

  public static void main(String[] args) throws SDKException {

  IEnterpriseSession enterpriseSession=CrystalEnterprise.getSessionMgr().logon("Administrator", "<Password>", "<Your BO-Server Name>", "secEnterprise");

  IInfoStore infoStore=(IInfoStore) enterpriseSession.getService("", "InfoStore");

  IInfoObjects objs= infoStore.query("SELECT * FROM CI_SYSTEMOBJECTS  WHERE SI_KIND='" + IAuditEventInfo.KIND + "'");

  IAuditEventInfo auditEventInfo = (IAuditEventInfo) objs.get(0);

  auditEventInfo.setCurrentAuditLevel(AuditEventLevel.COMPLETE);

  infoStore.commit(objs);

  System.out.println("Audit Level Changes Done!!!");

  enterpriseSession.logoff();

  System.out.println("Log off Success!!!");

  }

}

-----------------------------------------------------------------------------

The changes are reflected back once we logoff from CMC & relogin again.

Can you please confirm that Auditing level changes are not reflected after relogging to CMC, after running the code?

 

Thanks,

Shailendra


Viewing all articles
Browse latest Browse all 2175

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>