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: 

"Statement is not accessible." - Error

Former Member
11,395

Hi,

am working for an ECC upgradation project and am getting the above error "Statement is not accessible." at the below coding.

WS_VBELN = XLIPS-VBELN.

Kindly get me a solution <removed by moderator>

Thanks in adv,

Siva

Edited by: Mike Pokraka on Sep 5, 2008 12:26 PM

17 REPLIES 17

former_member188685
Active Contributor
0 Kudos
2,296

> WS_VBELN = XLIPS-VBELN.

where are you writing this..?

show the code before and after the line.

Former Member
0 Kudos
2,296

Hi,

WS_VBELN = XLIPS-VBELN.

Insteas use like this.

move xlips-vbeln to ws_vbeln.

or

ws_vbeln eq xlips-vbeln.

matt
Active Contributor
0 Kudos
2,296

>

> Hi,

>

>

> WS_VBELN = XLIPS-VBELN.

>

> Insteas use like this.

>

> move xlips-vbeln to ws_vbeln.

>

> or

>

> ws_vbeln eq xlips-vbeln.

Total nonsense

ThomasZloch
Active Contributor
0 Kudos
2,296

that seems to be outside of any event block (as in START-OF-SELECTION etc.)

This was tolerated before Netweaver 700 but not any longer.

Move the statement inside such a block.

Thomas

0 Kudos
2,296

Hi all,

Pls check the code below :

DATA: WS_SPLITTOR(3) TYPE C,

WS_SPLIT(1) TYPE C,

WS_SPLIT1(1) TYPE C,

WS_SPLIT2(1) TYPE C,

WS_SPLIT3(1) TYPE C,

WS_VBELN TYPE LIPS-VBELN,

WS_POSNR TYPE LIPS-POSNR,

WS_NO_OF_LOOP(1) TYPE C,

WS_NO_OF_ITEM(1) TYPE C,

WS_BAL(1) TYPE C,

WS_MODNO(10) TYPE C,

PAR_ID(20) TYPE C.

  • DECLARATION OF INTERNAL TABLE

DATA: INT_XLIPS LIKE XLIPS OCCURS 0 WITH HEADER LINE,

INT_XLIPS2 LIKE XLIPS OCCURS 0 WITH HEADER LINE.

WS_VBELN = XLIPS-VBELN.

WS_POSNR = XLIPS-POSNR.

MOVE SY-MODNO TO WS_MODNO.

CONCATENATE 'SPLIT' WS_MODNO INTO PAR_ID.

.......

Regs,

Siva

0 Kudos
2,296

hi ,

place the code in an event.

DATA: WS_SPLITTOR(3) TYPE C,

WS_SPLIT(1) TYPE C,

WS_SPLIT1(1) TYPE C,

WS_SPLIT2(1) TYPE C,

WS_SPLIT3(1) TYPE C,

WS_VBELN TYPE LIPS-VBELN,

WS_POSNR TYPE LIPS-POSNR,

WS_NO_OF_LOOP(1) TYPE C,

WS_NO_OF_ITEM(1) TYPE C,

WS_BAL(1) TYPE C,

WS_MODNO(10) TYPE C,

PAR_ID(20) TYPE C.

DECLARATION OF INTERNAL TABLE

DATA: INT_XLIPS LIKE XLIPS OCCURS 0 WITH HEADER LINE,

INT_XLIPS2 LIKE XLIPS OCCURS 0 WITH HEADER LINE.

Start-of-selection.WS_VBELN = XLIPS-VBELN.

WS_POSNR = XLIPS-POSNR.

MOVE SY-MODNO TO WS_MODNO.

CONCATENATE 'SPLIT' WS_MODNO INTO PAR_ID.

Former Member
0 Kudos
2,296

Hi,

What is WS_VBELN? Is it a work area?

Regards,

Ramya

Former Member
0 Kudos
2,296

write 'START-OF-SELECTION' before the subject statement...

I think its not able to locate which event it belongs to...so inserting above statement would suffice.

~Piyush Patil

Former Member
0 Kudos
2,296

Hi,

The code doesnt have any select query! From where does the value of XLIPS-VBELN come from?

Regards,

ramya

0 Kudos
2,296

Hi Ramya,

It is a (sub)Include prgm..

0 Kudos
2,296

HI Siva,

On seeing the code you have provided...i assume that XLIPS is a DB table .If it is so, there is no value stored in that.

If it is an internal table, pls write this statment after the select query within the event Start-of-selection.

And please put all declaration in one include itself, and dont put any piece of code within it. And keep this include as the 1st include in your main program.

Regards

Winnie

0 Kudos
2,296

Hi,

i guess your include program before this statement has subroutine. If so you get the error message...

One thing you can do is place Start-of-selection statement before the assignment

regards

padma

Former Member
0 Kudos
2,296

Issue resolved

0 Kudos
2,296

This message was moderated.

former_member770121
Participant
0 Kudos
2,296

Kindly tell how the issue is resolved. I also write the start of selection but then debugger is not trigger on statement. Kindly its urgent.

moshenaveh
Community Manager
Community Manager
2,296
Hello, While we're happy that you've come to SAP Community to get an answer to your question, you posted your question as an answer in an old thread.
I've converted your answer to a comment, but even so -- posting in older threads is not the best way to get guidance.
If you're looking for help, you should ask a new question: https://answers.sap.com/questions/ask.html.
Here are some tips to help you craft an effective question for our community: https://community.sap.com/resources/questions-and-answers, https://developers.sap.com/tutorials/community-qa.html, https://groups.community.sap.com/t5/welcome-corner-discussions/advice-from-sap-champions-questions-a....
I encourage you to follow this guidance, as I'd really like to see you get a solution to your problem.
I hope you find this advice useful!

shekhar01
Explorer
0 Kudos
2,032

check if the query is inside START-OF-SELECTION ... END-OF-SELECTION, you could check if the previous query has ended with dot(.)