3 Replies Latest reply: Jul 1, 2012 11:33 AM by Lars Breddemann RSS

How can I activate a view programmatically?

Karsten Klein
Currently Being Moderated

We are trying to automate our complete data installation procedure on HANA via JDBC/SFTP.

 

We were able to

  • execute all create schema, create table, the necessary grants statements via JDBC
  • automate the file transfer of the data to the AWS Image via SFTP (jsch) and trigger the actual import via JDBC.
  • install a package with views via JDBC

 

However we were so far not successful in automating the activation of a view. This is still a manual task before one can start accessing the views by whatever means.

 

I would be grateful for any hint to help me activate an existing view with a statement via JDBC.

 

Best regards,

Karsten

  • Re: How can I activate a view programmatically?
    varada santosh
    Currently Being Moderated

    Hi Karsten

     

    It seems to be very interesting,but I don't think that is not possible as of now.because at the back end there are procedures which get executed to make an object activate ,for example if you activate attribute view or analytical view the corresponding column view is created under _SYS_BIC package this is actually done by _SYS_REPO user at the back end.may be it ise possible if any scheduling option is available.If it is added in future,let us wait for others views .

     

     

    Thanks

    Santosh Varada

  • Re: How can I activate a view programmatically?
    Ravindra Channe
    Currently Being Moderated

    Hi Karsten,

     

    I don't know the exact answer, but can recommend one possibility.

     

    Can you try setting up the DB SQL trace and activate the view. I am sure if the activation and subsequent object creation is done through procedures / SQL statements, you will be able to locate them in the trace.

     

    As mentioned, I am not sure if this would work, but worth a try.

     

    Regards,

     

    Ravi

  • Re: How can I activate a view programmatically?
    Lars Breddemann
    Currently Being Moderated

    Hello Karsten,

     

    the API required for these activities is not released for non-SAP usage.

    Using it the wrong way (e.g. by just trying to imitate the statements you may find by tracing whatever HANA Studio sends/receives from the server) may lead to repository inconsistencies.

     

    So the recommendation here is: don't try to fiddle with the repository manually here.

     

    regards,

    Lars

Actions