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

Re: HANA XS

$
0
0

Hi Florian,

 

Yea I have entries ( id=1 && val=6). Once I activate the files and giving call statement in SQL. I am running xs application in web based development workbench. But when I open the application Blank page is diplayed.

 

====================================

 

Hello.xsjs

 

function getDataFromTable() {

var id = $.request.parameters.get("id");

  if (id === null) { 

  $.response.contentType="text/plain";

$.response.setBody("id is null!") ;

 

 

  } 

  var val1 = $.request.parameters.get("val1"); 

  if (val1 === null) { 

  $.response.contentType="text/plain";

  $.response.setBody("val1 is null!");

  }

 

  var output = {}; 

  output.data = []; 

  var conn = $.db.getConnection();

conn.prepareStatement("SET SCHEMA \"NEO_xxxxxxxNGHC4\"").execute(); 

var st = conn.prepareStatement("INSERT INTO \"sxxxxxxrial.p1234567.hello::TESTS\"  values(?,?)");

st.setString(1,id); 

st.setString(2,val1);

st.executeQuery();

st.execute(); 

  conn.commit(); 

  var record = []; 

  record.push(id); 

  record.push(val1); 

  output.data.push(record); 

  conn.close(); 

}

=============================================

.xsaccess :

 

{

"exposed" : true,

"default_file": "hello.xsjs"

}

=================================================

.xapp

 

          "auth_required": true 

}

 

=================================

model_access.hdbrole:

 

role sxxxxxxtrial.p1234567.hello::model_access {

     sql object sxxxxxxtrial.p1234567.hello::TESTS: INSERT, SELECT;

    

     }

 

Could you please tell me any other changes / steps I miss.

 

Are there any configurations do I need to follow?

 

I am using http://scn.sap.com/community/developer-center/cloud-platform/blog/2014/06/19/debug-your-sap-hana-xs-application-on-trial for debugging xs.

But I got struck in step 3 since It is displaying blank page.

 

Thanks in Advance,

 

Vinni

 

 

 

IMG_5250.JPG


Viewing all articles
Browse latest Browse all 3347

Trending Articles



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