Connecting to #SAP #HANA Instances on #SAPHCP from #Eclipse IDE
I seem to be in a blogging mood recently. 😉 Unfortunately, I missed the chance to give a shout about a cool new feature which was released couple of weeks ago (on March 13, precisely speaking) but apparently has left unnoticed by many folks and friends of SAP HANA Cloud Platform. So – and as a wise man had once said – I thought “better late than never” and decided to try and fix this lapse.
What am I talking about? Well, until March 13, if you wanted to connect to an SAP HANA instance on SAP HCP, you had to open a DB tunnel in the Console Client by executing the open-db-tunnel command, copy the connection details it returned to you (including the instance number, DB user and password), go to your HANA Studio (and yes, it had to be a separate standalone IDE from your other Eclipse IDE which you were using for Java development on HCP and/or any other development you do!) and paste those connection details into the corresponding wizard pages. Oh, and did I mention that you had to keep the DB tunnel in the Console Client open while you were working on the remote HANA instance? Sounds fun? Guess not.
Well, forget about the above. We’ve put an end to all those tedious, awkward and error-prone steps within so many different tools. Now you can do everything in a single tool (Eclipse IDE) with just a couple of clicks. The prerequisite is that you have installed an Eclipse Kepler IDE and the SAP HANA Cloud Platform Tools on top, as described in Setting Up the Tools. (And yes, you got it right – all necessary SAP HANA Tools now can be installed as well from the SAP Development Tools for Eclipse – Kepler Software Repository, so you don’t need a separate HANA Studio installation any longer.)
Now, if you already have a trial or productive SAP HANA instance in your account (see e.g. Creating a Trial SAP HANA Instance), you can just go to the SAP HANA Development perspective in your Eclipse IDE, right click in the Systems view and select Add Cloud System… which should open up this nice wizard:
Enter your account info and click Next. This will lead you to the second page where you have to select an instance from the list:
Click Finish and in a few seconds it will be added in the Systems view. If you are working with a productive instance, you also need to provide your own DB user and password. See in the official documentation how to create it. In this case, as a last step the wizard might ask you to change your DB password if it is an initial one and you haven’t changed it yet.
That’s it! Now you can go on and import some sample apps, play with them, or develop your own XS app – it’s up to you. Enjoy! And don’t hesitate to share your feedback and comments – we are always looking for further improvements and simplifications. 🙂