Experience the Magic: How to Setup Your Own ABAP on HANA in the Cloud
Are you an ABAP developer who can’t wait to explore the intricacies of ABAP on HANA coding? Do you want to set up a sandbox environment where you can try out things such as consuming HANA Calculation Views or Stored Procedures from ABAP programs, and learn how to accelerate your ABAP applications with HANA or build entirely new ones? Then this is for you.
Set up your HANA One system
HANA One is a 60 GB HANA instance in the cloud. It runs in Amazon’s EC2 cloud and is very easy to set up. My system was in fact up and running within minutes. Here’s the link to the Quick Start Guide: http://www.saphana.com/docs/DOC-2437.
Please note that it isn’t free. Explore http://www.saphana.com/community/learn/cloud-info for more detailed information.
Download and install SAP HANA Studio
Once your HANA One instance is up and running, you can download the HANA Studio and HANA Client libraries directly from it. Start playing around with HANA Studio.
(Note: You’ll need to install Java 1.7 before you can install SAP HANA Studio, for example the Java SE Development Kit 7u17 for Windows x64 from http://download.oracle.com/otn-pub/java/jdk/7u17-b02/jdk-7u17-windows-x64.exe.)
Import the SFLIGHT sample dataset
There is a database schema available for download which contains a number of tables from the SFLIGHT tutorial data model. You can download it from the following location: http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/c0c49112-c9ab-2f10-d591-9d40e658f7ce?QuickLink=index&overridelayout=true&55963423911188
To import it into your HANA One instance, execute File > Import > SAP HANA Studio > Catalog Objects.
The result will be visible under schema SFLIGHT.
Set up a Windows server for your ABAP system
I also run my ABAP system in the cloud, although this isn’t necessary if you have a server that meets the requirements, most notably:
- Windows Professional or Server 2008R2 (English)
- 4 GB RAM
I use Amazon EC2 as my cloud provider. You can get started by going to http://aws.amazon.com/en/ec2/. Because I was impatient and wanted the installation to complete quickly, I chose a relatively large instance type: “m1.large”, with 7.5 GB RAM and 4 CPU units (2 cores).
You might want to check the hourly fee and perhaps go for a smaller one (in terms of RAM and CPUs) if you plan to spend many hours with the system.
The image I chose is “Windows_Server-2008-R2_SP1-English-64Bit-Base-2013.03.14 (ami-ceb129a7)”.
The default 30 GB of storage isn’t enough for the installation of the ABAP Systems. I chose 100 GB just to be on the safe side, especially during the installation process when more space is needed. Now that my system is up and running, 75 out of the 100 GB are in use:
Setup your AS ABAP 7.03 server
Download and install the AS ABAP 7.03 SP04 64-bit Trial system from SAP Community Network: http://www.sdn.sap.com/irj/scn/downloads?rid=/library/uuid/30a6dbb2-a774-2e10-ee83-9f6432973545
Because I’m running this on a large and fast virtual machine, the installation went through rather quickly. I didn’t use a stopwatch, but I think it took about 30 to 60 minutes until the system was up.
Install SAP HANA Client on your ABAP server
You can download SAP HANA Client directly from your HANA One instance to your ABAP server. Extract the Rev48ClientWin86_64.zip archive and run the hdbsetup.exe binary:
Copy the HANA database libraries to your ABAP server’s directory
Locate the following libraries:
- libSQLDBCHDB.dll
- dbhdbslib.dll
You will find them in the directory to which you installed SAP HANA Database Client – probably in one of the following locations:
- C:\usr\sap\NSP\hdbclient
- C:\Program Files\SAP\hdbclient
Copy them into a directory where there ABAP kernel finds them. The easiest way is to copy them to directory “C:\usr\sap\NSP\DVEBMGS00\exe”, so that they can be found at the following locations:
- C:\usr\sap\NSP\DVEBMGS00\exe\libSQLDBCHDB.dll
- C:\usr\sap\NSP\DVEBMGS00\exe\dbhdbslib.dll
Configure a secondary database connection
Go to transaction SM31 and maintain entries for table DBCON.
Create a new entry with the following information:
- DB Connection: the symbolic name you give this database connection (similar to the name of an RFC destination)
- DBMS: enter “HDB” for SAP HANA
- User Name: enter the name of the HANA database user (typically this is also the name of the database schema you’re going to work in)
- DB password: enter the password of the HANA database user
- Connection info: enter the IP address with the one assigned to your HANA One instance by Amazon EC2, followed by “:30015”.
(I recommend you to use Amazon EC2’s “Elastic IP” feature and reserve an IP address you can keep using. Otherwise, you will have to change the IP address each time your HANA One instance starts because a new address will be assigned each time.)
Start coding: ABAP on HANA
Disclaimer: At this point I have to confess that I had to use some black magic to open the system for development. Normally in NSP trial systems, user BCUSER comes with a pre-installed developer key and can start creating programs directly. I don’t know why this wasn’t the case with my installation or where to get the developer key – applying my black magic (which I’m not at liberty to share) was faster but you might have to find your own way around it if the same obstacle occurs here.
Update: Ian MacGregor was so kind to share this in the comment section – I’ve copied it into the blog post so readers won’t miss it:
“Other readers could try 14421119653247674476 as the developers access key for BCUSER, it worked for the SAP-INTERN installation when following this blog to setup AS ABAP 7.02 (and 7.03) with Gateway on AWS.”
Thanks a lot, Ian.
*&———————————————————————*
*& Report Z_ABAP_ON_HANA
*&———————————————————————*
REPORT z_abap_on_hana.
DATA:
lt_sflight TYPE TABLE OF sflight,
lr_salv TYPE REF TO cl_salv_table.
START-OF-SELECTION.
SELECT * FROM sflight INTO TABLE lt_sflight
CONNECTION sflight.
CALL METHOD cl_salv_table=>factory
IMPORTING
r_salv_table = lr_salv
CHANGING
t_table = lt_sflight.
lr_salv->display( ).
Finally – the beginning!
Get into the flow – happy HANA modeling and ABAP coding!
Things left to be desired
Because I don’t have any Basis/administration skills worth mentioning, there are still some things left to be desired:
- LT replication from ABAP to HANA,
- FQDN configuration,
- ICM configuration (server ports for HTTP and HTTPS),
- installation of the Cryptolibs for HTTPS connections.
Still, it’s a start and there are many things we can now try out!
Hi Thorsten
Thanks a lot for the guiding steps. 🙂 will be up and running soon.
But will ping you if got stuck somewhere in-between. 😉
Regards
Kumar. 🙂
Kumar, thanks a lot for the feedback. Have fun setting this up - and doing some HANA magic. 🙂
HI Thorsten,
I tried downloading AS ABAP 7.03 server from the link provided.
http://www.sdn.sap.com/irj/scn/downloads?rid=/library/uuid/30a6dbb2-a774-2e10-ee83-9f6432973545
It downloads only up-to 2.4GB and then gives some unknown error. I have tried to download this many time using different Internet connections and Internet service provider and even on different system but never been successfully downloaded. 🙁
If possible Can you please provide the entire setup (64 BIT) on different server (say sharing it on Dropbox or skydrive). ??
Regards
Kumar.
Kumar,
Really sorry, but unfortunately I can't do this. Firstly, it would probably illegal. Secondly, I've set up my personal system with my favorite "for real" passwords, which means that sharing the system would compromise my work passwords, etc. I'm sure you understand.
Best,
Thorsten
Hi Thorsten,
I do understand the Legal issues and security concern in doing so. Just wanted to discuss the other way out.
Regards
Kumar. 🙂
Hi Thorsten,
Thanks for the blog post... simple steps making it easy to experiment with ABAP for HANA - just what I was looking for.
Other readers could try 14421119653247674476 as the developers access key for BCUSER, it worked for the SAP-INTERN installation when following this blog to setup AS ABAP 7.02 (and 7.03) with Gateway on AWS.
Cheers,
Ian
Ian,
Thanks a lot for helping out with the developers access key! I've copied it into the body of the blog post so others won't accidentally miss it.
Please keep us posted on your experiments, I'd love to read about them as I will try to make time for a blog post on HANA consumption in ABAP. 🙂
Best,
Thorsten
Brilliant.
Thanks for not only stepping through this but for being so good as to screen-shot it and share it with us so any developer can get started step-by-step. This sort of thing should be also most illuminative for any SAP folks working on making HANA barrier-free to entry -- cc the good folks at Anne Hardy's team.
I didn't see a total time requirement -- I see you referencing "minutes" for HANA components. Am I correct that the AS ABAP was the most time-consuming part of the install, at up to one hour?
What single thing or what things can we do at SAP to make this even easier? I see references to black magic such as manually copying libraries and hunting for developer keys - as well as overlarge downloads. Are these the most prominent barriers to overcome?
thanks again
Excellent questions, Moya. Generally speaking, I think SAP is doing a really great job here and everything has become spectacularly simple in recent years. I've been around the block a few times - working in SAP development since 1998 - and remember how difficult everything was in the olden times. Especially Anne Hardy's team deserves credit for lowering barriers and making technology easily accessible to developers. They're doing such a good job!
Speaking from my own experience, the things I find difficult or am slightly afraid of when trying out new development tools are always the Basis/installation parts. I'm a developer, not an admin, so I know less than I need to know for many purposes when it comes to things like:
kernel upgrades
patching a system
configuring ICM (FQDN, HTTP, HTTPS, SMTP)
generally all low-level (e.g. OS level) post-install activities such as configuring ITS, IGS
configuring TMS
installing add-on components such as SWT2DB
setting up LT replication (installing the add-on components and configuring them)
Installing additional database drivers
By now I have actually accomplished most of these tasks at one or the other time but it's usually a painful process because I'm a developer and way out of my comfort zone (and, more importantly, out of the zone I find interesting) when I have to be an admin for my trial systems.
That's why I'm so happy when installing an ABAP system is really just starting a setup.exe (once I wrote a blog post titled "ABAP as a Setup.exe"), or when setting up a HANA system is a breeze because all the post-install activities are perfectly scripted and a wizard guides me through everything. The HANA One installation process is just perfect.
Hope this answers your question. 🙂
Thorsten
let us talk about the costs...
is it really more than 5000 $ (as listed on the AWS site) for a month (720 hrs) ?
or have I missed stomething 🙂
grx Andreas
Black Magic is fun. A purely hypothetical example: In a system where I can't develop, because I don't have a developer key, reprogram the part of the server that checks for a valid developer key to be a bit more generous. A bit of a hen and egg problem, logically similar to the problem of giving myself the authorization to give myself authorizations.
Of course I'd never do any of these highly irresponsible things.We all know that magic doesn't really exist.
Hi Thorsten,
Huge Thanks for sharing this with SCN folks . 🙂
Nice Blog Thorsten.
Did the same last year with my Linux installation to try out the secondary database connection (see also the great blog by Thomas Jung http://scn.sap.com/community/hana-in-memory/blog/2012/04/11/test ) but didn't have the guts to blog about it.
(still don't know whether it's legal to copy the missing libs of HANA DB to my Linux installation).
Outstanding blog, as usual
I've set up a Hana system before on Amazon but not ABAP; your blog makes me *think* I could do that, and also may inspire me to do it.
Excellent
Regards,
Tammy
Thanks a lot for this Post . Much appreciated !!!
Regards,
Rahul 🙂
Thanks a lot. So excited to try this out.
This is a phantastic blog again. I got my first ABAP system on Amazon EC2 by following one of Torstens blogs years ago and now he is combining this with HANA! Many thanks
SAP NetWeaver Application Server ABAP 7.4 - expensive with AWS
Hi,
I had installed SAP HANA studio ver 1.56 and AWS with SAP HANA1,was learning concepts.
Being an ABAP developer looking for more ABAP stuff on HANA.
Later replaced HANA studio with 1.60 with same AWS backend connectivity, but
didn't success in creating any programs in ABAP as it was not able to connect
ABAP GUI from HANA due to issues like
"User xxxxxx is not authorized to access system E66 via
ABAP in Eclipse (No authorization to access the resource
/sap/bc/adt/compatibility/graph".
On Saturday (07-27-2013) tried to move to "SAP NetWeaver
Application Server ABAP 7.4", looks these it bit expensive ($42.00 per day
and $212.00 per week) Do you have any other options I can look into to work on SAP Net Weaver Application Server ABAP 7.4.
Looking for your updates.
Thanks in advance.
Regards
Harikrishna Yoga