Course guide “Next Steps in SAP HANA Cloud Platform” – week 1
Course Overview
ENROLL TO THE COURSE HERE (in case you haven’t, yet): Course: Next Steps in SAP HANA Cloud Platform
You can find a list of the course guides for each week of this course in the corresponding parent project of this blog post.
Week 1: SAP HANA Native Development
In the first week of this course you learn how you can develop SAP HANA native applications on the SAP HANA Cloud Platform.
Unit 1 – Basics
This unit provides you with the basics around the SAP HANA native development on SAP HANA Cloud Platform. You get to know some specifics around the current trial landscape that is used for your developer license. And you’ll learn how to connect to your HANA instance in the SAP HANA Cloud Platform via Eclipse.
Important/additional links
- The SAP HANA Cloud Platform market place providing you information about the various SAP HANA Cloud Platform offerings.
- A blog post on SCN describing how to connect to an HANA instance on the SAP HANA Cloud Platform via Eclipse
- SAP Development Tools for Eclipse
- openSAP course Introduction to Software Development on SAP HANA
Unit 2 – SAP HANA Applications
In this unit you learn how easy you can import an SAP HANA native sample application into your HANA instance on SAP HANA Cloud Platform.
We use the SHINE application (also used in the openSAP course Introduction to Software Development on SAP HANA) to demonstrate how to accomplish this task.
Important/additional links
- Blogs/documents on the SCN Community page of SAP HCP:
- Using HANA Modeler in SAP HANA Cloud Platform
- Click and Try Sample XS Applications on the SAP HANA Cloud Platform
- 8 Easy Steps to Develop an XS application on the SAP HANA Cloud Platform
- Enhance Your Cloud Application with HANA Search
- Deploy HANA XS apps on SAP HANA Cloud Platform with an Ubuntu VM
- Creating and using HANA native scripted calculation view in SAP HANA Cloud
- Using Predictive Analysis Library (PAL) in SAP HANA Cloud Platform
Unit 3 – SAP HANA Web-based Development Workbench
In this unit we use the SAP HANA Web-based Development Workbench to modify the SHINE application we imported in the former unit. All of this inside a web browser.
Important/additional links
Unit 4 – SAP HANA Predictive Analysis Library
This unit is just around the usage of the SAP HANA Predictive Analysis Library and how you can use it on the SAP HANA Cloud Platform. In the unit we’ll use the ABC analysis function to demonstrate how it can be used on your HANA instance on the SAP HANA Cloud Platform.
Important/additional links
- Official documentation on how to use PAL on the SAP HANA Cloud Platform
- The official SAP HANA PAL documentation
- A blog post: Using Predictive Analysis Library (PAL) in SAP HANA Cloud Platform
Common issues
User has no authorization, privilege: REPO.MAINTAIN_IMPORTED_PACKAGES
This issue comes up if you’ve used the SAP HANA Studio SPS8. Find in the corresponding openSAP forum thread how to get around this issue.
Unit 5 – Extend SAP HANA Applications with HCP Services
In the last unit of week 5 we discover how to use the SAP HANA Cloud Platform Feedback Service by using it in the SHINE application we imported in unit 2 of this week.
Rui,
I am not able to "install new software" on my eclipse kepler 64bit, to get the HANA dev tools. I get an error: " Missing requirement: SAP In-Memory Computing Studio Authorization Depedency Viewer 1.0.7400 (com.sap.ndb.studio.authdepviewer 1.0.7400) requires 'bundle org.eclipse.zest.core 0.0.0' but it could not be found" and it will not continue.
There are a few questions about this on the openSAP forum but no answers. how do we proceed?
Hi Jason,
which version of eclipse kepler do you use? It seems that your version missing some plugins, which are required for HANA dev tools.
Please check whether the following plugin is installed in your eclipse:
"Help" -> "About Eclipse" -> "Installation Details"
If not, you can install it from the Kepler Update Site (the first one in the screenshot):
Or alternatively you can use the Eclipse for JEE Deveopers version of Kepler. This ensures, that you have all required dependencies
Best regards,
Artem
Thanks Artem, I will check this when I"m in the office later today. Interestingly I am on the J2EE version of the Kepler download so I would have thought these dependencies would be there. Thanks.
This fixed it. It seems that even the eclipse kepler EE download is missing the Zest dependency as I downloaded a completely new eclipse and had same issue. Manually adding Zest sorts it all out though. Thx.
Hmm, that's strange. I also downloaded the new eclipse JEE as I started this course. The only difference I can imagine, I installed ALL plugins available from https://tools.hana.ondemand.com in one step. But actually that shouldn't make a difference since the missing dependency is an Eclipse plugin.
However, you can now work and this is the main thing 🙂
Best regards,
Artem
Unable to connect to HANA instance through eclipse, stating error can not connect to cloud, checked error log:
Caused by: java.io.IOException: Failed to find free local ports
at com.sap.core.persistence.commands.tunnel.connection.HanaSpecificHelper.remapIfRequired(HanaSpecificHelper.java:105)
at com.sap.core.persistence.commands.tunnel.connection.DBSpecificHelper.getLocalMappings(DBSpecificHelper.java:35)
at com.sap.core.persistence.commands.tunnel.connection.DbTunnelManager.startTunnelClient(DbTunnelManager.java:82)
... 9 more
tried to change network setting not succeeded.
People are not able to activate the paldemo folder from Week 1 Unit 4. See discussion thread: https://open.sap.com/courses/16/discussion_topics/7371.
It seems that our users are missing a role for "REPO.MAINTAIN_IMPORTED_PACKAGES".
Hi Jason,
did you make the step with granting the role to the user:
call "HCP"."HCP_GRANT_ROLE_TO_USER"('<User>trial.opensap.shine.data::model_admin','<User>')
Best regards,
Artem
Yes - did that... and did it again to test now but still get same authorisation error.
Hi Jason,
Please see the proposed solution in the open sap discussion.
Best regards,
Emil
Hi Emil,
I have another issue with HANA Studio SP8:
Can you please check, whether the problem is already known and forward it to dev team if required?
Thank you and best regards,
Artem
Is it normal that I must remove my HANA instance from eclipse and re-create it with the Add Cloud System menu every time I start up eclipse new....
When you do this you lose the connection with the repository workspace and project explorer projects. No amount of refreshing or trying to create a new repository workspace does anything.
Each time I must delete and start again... Obviously my save artefacts are still in the DB which is good, but it sure seems like a clunky process.
I understand that when using the console client you must continually re-connect as it gives you a temporary username and password each time.... Is is the case that in eclipse the Cloud HANA instance is just doing this under-the-hood and therefore it is absolutely necessary to restart afresh every time...?
Clunky! ;-/
I think it is not normal, since I don't have this issue. Do you see the system after restart of eclipse in the Systems tab of HANA Dev perspective? If yes what happens if you right click on the system and say "Login"?
Regards,
Artem
Guess what - I open up eclipse today and it auto-logged on and all is good. Must have just been a glitch yesterday. Thanks for your help 😉
I have some errors during "checkout and Import Project" step, mostly errors are in below function. Errors line are in BOLD.
function getTableSize() {
function createTotalEntry(rs, table, rs2) {
var record_count = rs.getInteger(1);
var table_size = Math.round(rs2.getInteger(1) / 1024);
return {
"name" : table,
"table_size" : table_size,
"record_count" : record_count
};
}
var i = 0;
var body = '';
var list = [];
var tableArray = [ "addresses", "businessPartner", "constants",
"employees", "messages", "products", "purchaseOrder",
"purchaseOrderItem", "salesOrder", "salesOrderItem", "texts" ];
for (i = 0; i < tableArray.length; i++) {
var query = 'SELECT COUNT(*) FROM \"NEO_CF86K6EKVYTZ7NAPVLCCFSJ6M\".\"s0004184905trial.opensap.shine.data::'
+ tableArray[i] + '\"';
var conn = $.db.getConnection();
var pstmt = conn.prepareStatement(query);
var rs = pstmt.executeQuery();
var query2 = 'SELECT "TABLE_SIZE" FROM \"SYS\".\"M_TABLES\" WHERE \"SCHEMA_NAME\" = \'NEO_CF86K6EKVYTZ7NAPVLCCFSJ6M\' AND \"TABLE_NAME\" = \'s0004184905trial.opensap.shine.data::'
+ tableArray[i] + '\'';
var pstmt2 = conn.prepareStatement(query2);
var rs2 = pstmt2.executeQuery();
while (rs.next()) {
rs2.next();
list.push(createTotalEntry(rs, tableArray[i], rs2));
}
rs.close();
rs2.close();
pstmt.close();
pstmt2.close();
}
body = JSON.stringify({
"entries" : list
});
$.response.contentType = 'application/json; charset=UTF-8';
$.response.setBody(body);
$.response.status = $.net.http.OK;
}
Any suggestions ?
I am unable to assign the required authorizations for the feedback service. In fact my authorizations screen in the HCP cockpit looks very different from what Rui see's on his screen. I do not have a column called Account. I only see columns for Application and Role.
When I try to assign a new role I have no option to specify the account!
Is this yet again another issue where those of use with original HCP trial account user-id's are missing new functionality? My account is p1081110.
3 weeks into the course an I'm still unable to complete the practical exercises from Week 1. Both this accounts issue and also the outstanding issue about not being able to activate the paldemo folder! Anyone from SAP able to help.
Hi Jason,
Your are right, currently the authorizations screen looks differently than the one described in the course materials. This is actually a newly introduced feature in the HCP cockpit, which was delivered after the course materials were prepared.
Here are the steps you need to do in order to assign the Feedback Service roles to your user:
Now you are ready to access the Feedback Service Administration UI and to continue your exercises.
Best Regards,
Stanimir
Hi Stanimir,
Thanks for the reply, but I cannot do this. There is no Account field in the popup for me!
Hi Jason,
Can you please check whether you have subscription to the Feedback Service.
You can do that by executing the following command in the Console Client:
Please let me know whether you have the following entry in the result:
Regards,
Stanimir
Hi again... that command says I have "No subscriptions available". However if I look at the subscriptions menu in the web cockpit I can see the two that were setup for RDE.
Hi Jason,
That is the reason you cannot assign the roles - you do not have subscription to the Feedback Service.
Could you please provide your account name and when it was created?
I will subscribe it to the Feedback Service in order to be able to complete your exercise.
Regards,
Stanimir
p1081110 - not sure of the date but it was soon after HCP was first announced...
Hi Jason,
You are now subscribed to Feedback Service.
Please assign the roles following the steps from my post on July 1st.
Regards,
Stanimir
Thanks for your help Stanimir, works good now. Regards, Jason.
Seems I also have this same problem as I have been able to assign the roles but do not have access to the Feedback admin UI - hence not able to complete unit 5 exercise. Could you please look at this for me as well. p1940705618.
Regards,
Andrew
Hi Andrew,
You are subscribed for the Feedback Service since you have managed to assign the roles.
Have you tried to open the Feedback Service Administration in a new browser session? When you assign the roles you always have to clear the session in order to be able to load the new page...
Best regards,
Stanimir