Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

ABAP Compiler or Interpreter?

Former Member
0 Kudos

Hi guys

This question has been asked several times and been answered in several ways.

But still i am repeating the same question since i couldnt found an exact answer.

Does ABAP have a compiler or an Interpreter or both ?

I have gone through several answers and documents regarding this.

Some says YES but some says NO.

If it is YES, could someone please explain why?

Also is this compilation takes place at OS level?

Expecting your kind response

Thank and Regards

Hareesh

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Hareesh,

Essentially ABAP uses the same model as Java, so ABAP programs are compiled to a byte code, which is then interpreted/run by a virtual machine. The generated byte code is platform dependent though for ABAP.

It's basically similar to the [write once run anywhere|http://en.wikipedia.org/wiki/Write_once,_run_anywhere] approach as opposed to the compilation to native processor instructions, which means that your resulting code is platform dependent (thus requiring code changes when [porting|http://en.wikipedia.org/wiki/Porting] it to another platform). So for ABAP you only need to regenerate the code for different platforms, but you don't need to adapt the source code (omitting changes though here for possible updates due to language changes, e.g. due to Unicode enabling).

E.g. see the short comment in [Overview of SAP Netweaver AS|http://help.sap.com/saphelp_nw2004s/helpdata/en/fc/eb2e97358411d1829f0000e829fbfe/frameset.htm]:

All ABAP applications run on software processors (virtual machines) within this component.

And in the guide [System Copy for SAP Systems Based on NW 7.0 SR3 ABAP|http://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/00f3087e-2620-2b10-d58a-c50b66c1578e] you'll find:

34. ABAP Program Loads

The ABAP loads are platform-dependent programs that are generated during runtime and stored in database tables.

Cheers, harald

14 REPLIES 14

Former Member
0 Kudos

Hi Hareesh,

Essentially ABAP uses the same model as Java, so ABAP programs are compiled to a byte code, which is then interpreted/run by a virtual machine. The generated byte code is platform dependent though for ABAP.

It's basically similar to the [write once run anywhere|http://en.wikipedia.org/wiki/Write_once,_run_anywhere] approach as opposed to the compilation to native processor instructions, which means that your resulting code is platform dependent (thus requiring code changes when [porting|http://en.wikipedia.org/wiki/Porting] it to another platform). So for ABAP you only need to regenerate the code for different platforms, but you don't need to adapt the source code (omitting changes though here for possible updates due to language changes, e.g. due to Unicode enabling).

E.g. see the short comment in [Overview of SAP Netweaver AS|http://help.sap.com/saphelp_nw2004s/helpdata/en/fc/eb2e97358411d1829f0000e829fbfe/frameset.htm]:

All ABAP applications run on software processors (virtual machines) within this component.

And in the guide [System Copy for SAP Systems Based on NW 7.0 SR3 ABAP|http://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/00f3087e-2620-2b10-d58a-c50b66c1578e] you'll find:

34. ABAP Program Loads

The ABAP loads are platform-dependent programs that are generated during runtime and stored in database tables.

Cheers, harald

former_member536879
Active Contributor
0 Kudos

Hi,

Please See the SCN Rules Before Posting.

With Regards,

Sumodh.P

0 Kudos

Hi Sumodh

Could you please be more specific on your valueble sugession .

Please See the SCN Rules Before Posting.

Hareesh

0 Kudos

Hi Hareesh,

Interview Type Questions are not allowed in the Forum. Only Technical help will be Provided for the issue your are facing while doing the coding.

With Regards,

Sumodh.P

0 Kudos

Sumodh,

I think we could give the benefit of doubt to this particular question. Though it sounds like an interview question, I guess it could be entertained, especially when you get an insighful answer to the same like the one provided by Harald.

pk

0 Kudos

Hi Pk,

I understand that. But in the beginning of this thread he posted this questions has posted for many times and several answers he got. For these types of questions we are having help.sap.com . There it completey tells you the flow.

But in the Forum rules these are not entertained. Thats why i posted like that.

With Regards,

Sumodh.P

0 Kudos

Hi Sumodh

Interview Type Questions are not allowed in the Forum. Only Technical help will be Provided for the issue your are facing while doing the coding.

Does it means that SDN forum is only for solving issues and not for sharing knowledge.?

Let me make this point very clear that it is not an interview question.

I respect your concern about the forum rules.

It would have been more appreciated if you might have presented it in a better way by providing a exact link or answer to my question

like what Harald did and then adding your comment.

But in the beginning of this thread he posted this questions has posted for many times and several answers he got.

But this doesnu2019t mean that I have received an exact answer.

But still I am repeating the same question since I couldnu2019t found an exact answer.

I think you have missed out this line.

Since I am not a beginner to SDN, me too is aware of forum rules and do respect it.

Any way I appreciate your positive turn around for avoiding repetition in forum questions and I hope down the line

you will deal these situations in a more diplomatic way.

Hareesh

0 Kudos

>

> I think we could give the benefit of doubt to this particular question. Though it sounds like an interview question, I guess it could be entertained, especially when you get an insighful answer to the same like the one provided by Harald.

No one in this forum is stricter than you PK. I agree Harald's answers are really very well-versed & educational for mortals like me.

I second you on this.

Cheers,

Suhas

0 Kudos

Thank you Sumodh for your efforts to keep this forum clean.

The reason why I did not click the Abuse Button is that, I did not find it as a lazy post. There clearly has been a genuine effort from Hareesh before posting.

Yes Suhas, Harald as always has the best of the answers for mortals like us.

pk

0 Kudos

Hi Pk,

I understand what you wrote and i completely agree with you . I Just want to covey him that there are answers for these type of questions in help.sap.com. If i done any thing wrong Sorry for my first posting.

With Regards,

Sumodh.P

0 Kudos

> especially when you get an insighful answer to the same like the one provided by Harald.

> I agree Harald's answers are really very well-versed & educational for mortals like me.

> Yes Suhas, Harald as always has the best of the answers for mortals like us.

It's what I thought too, Harald is not a human being, that's impossible for a human being to provide these awesome answers! He's the latest version of [Daryl|http://en.wikipedia.org/wiki/D.A.R.Y.L.] project. Harald = Human Alive Robot Advanced Life Development 😄

0 Kudos

>

Harald = Human Alive Robot Advanced Life Development 😄

Wowwie ... Did u make this up ??

Hope he keeps enlightening us with his answers 😄

0 Kudos

@Sumodh: I agree that some quite a few questions in this forum are silly and could have been answered if the poster would have done some research. However, before I start giving a generic answer or point to forum rules I personally like to take this small challenge: If you think something is really a stupid question that's answered in the documentation, give it a quick try and find a reference that answers the question. If I don't have the time or the question is really silly, I tend to ignore it.

I'm quite often surprised how hard it actually is to prove something seemingly obvious with an official reference from SAP. So if I know the answer, but still am not able to find some official reference (or need some time), then maybe it's not that obvious at all... (well, or possibly my searching techniques suck, but at least from that perspective I'd be at best as skilled as the original poster)

So in this particular case, if you have a good reference, please share it with us. I couldn't find anything really useful and had to give rather odd links in my answer. I usually don't like to just quote some previous forum postings, because among the really insightful answers there's also lots of rubbish out there (and let's be honest, some of the stuff might have been right at some point, but is now simply outdated).

@Hareesh: As you can tell from my perspective your question was completely legitimate: Any question that shows the original poster did some research before asking and is specific enough is ok, but hey, that's just my opinion. So don't get discouraged, obviously in a large community opinions differ from time to time...

@Sandra/PK/Suhas: Thanks for the kind words, but I'm just another one of the tons of average and confused SAP techies (though rather opinionated and a stickler for detail) trying to make sense out of all those applications. Be assured it's me who's following your insightful postings!

Cheers, harald

p.s.: The questions that really amuse me are the really generic ones listing basically the requirements for a task somebody has to solve/implement. Whenever I see nice and detailed answers to such questions I'm really tempted to write to the posters asking them if they'd consider working for me - no salary, health benefits or any of that crap, but I'd offer some really nice highscore system, where I would publish top employees with their scores...

p.p.s.: Darn, another overlong posting. My bad.

0 Kudos

> obviously in a large community opinions differ from time to time...

hopefully. And even in small communities

> p.p.s.: Darn, another overlong posting. My bad.

I like reading this kind of long answer!