cancel
Showing results for 
Search instead for 
Did you mean: 

Problems creating RFC Service Call when Structure defined with Typing=TYPE

Former Member
0 Kudos

Hi,

I want to do a Service Call from Webdynpro ABAP to an RFC which has an structure that is defined with Typing = TYPE instead of LIKE(cause LIKE is supposed to be deprecated) but when using TYPE the Service Call cant be created and it sends a message that is not a recognized type and it does not finish the creation of the Service Call, on the other hand when using in the Structure definition Typing = LIKE then it works and it creates the Custom Controller.

has somebody faced this same issue?

Hope somebody can help.

Kind Regards,

Gerardo J

Accepted Solutions (0)

Answers (2)

Answers (2)

gill367
Active Contributor
0 Kudos

hello,

the type of the structure is present in DDIC or not?

also at what point you are getting the error.

thanks

sarbjeet

Former Member
0 Kudos

Hi Sarbjeet,

Thanx for answering, the point where I´m getting the "error" is when you right click on the WDA Component, then create > Service Call there you click on continue, type a name of the controler, then select Function Module in the radio button, then slect the RFC you want to call and then you can select in object type if the node/attributes will be Controller atribute | Context | Paramethers of method, and there after seting the node refered to the TABLE as Context, then a message says that is not a known data type and to type one, there is where I got stuck. But when the TABLE is declared with LIKE this is not happening and everything gets created as it should with out any error or warnings.

Have you done this with a RFC that has a TABLE declared as TYPE?

kind Regards,

Gerardo J

Former Member
0 Kudos

> Hi Sarbjeet,

>

> Thanx for answering, the point where I´m getting the "error" is when you right click on the WDA Component, then create > Service Call there you click on continue, type a name of the controler, then select Function Module in the radio button, then slect the RFC you want to call and then you can select in object type if the node/attributes will be Controller atribute | Context | Paramethers of method, and there after seting the node refered to the TABLE as Context, then a message says that is not a known data type and to type one, there is where I got stuck. But when the TABLE is declared with LIKE this is not happening and everything gets created as it should with out any error or warnings.

>

> Have you done this with a RFC that has a TABLE declared as TYPE?

>

> kind Regards,

>

> Gerardo J

Hallo ,

i have done this , You cannot do anything about it . I recommend to accept the tool suggestion ( as controller attribute ). That will create a entry in the component controller a attribute with the type of the table and it generates the code in the method to bind this table.

If you want this to be still a context node then create on your own a node and bind the above table to the node at the end of the method call.

gill367
Active Contributor
0 Kudos

Hi

i tried it with function module having typing = type only for a a table in DDIC.

but i haven't got any error.

can you give me some standard fucntion module which is using typing as type and i will tryit with that.

regards,

Edited by: sarbjeet singh on Jan 14, 2011 9:28 AM

Former Member
0 Kudos

Hi Sarbjeet,

I asked in the morning to one of our ABAP developers to send me one standard RFC but he has not found one yet, he has found just standar ones defined with LIKE wich is working but I hope he can find one with TYPE so I can send it to you.

thanx alot for the help!

Kind Regards,

Gerardo J

gill367
Active Contributor
0 Kudos

Hello,

here is what i am trying ..

[image 1|http://img171.imageshack.us/img171/5403/se371.png]

[image 2|http://img163.imageshack.us/img163/7966/se801.png]

[image 3|http://img808.imageshack.us/img808/742/se802.jpg]

[image 4|http://img267.imageshack.us/img267/143/se803.jpg]

thanks

sarbjeet singh

Former Member
0 Kudos

Hi Sarbjeet,

thanx alot for the help, what version do you have? I see the screens are slightly different from mine.

Thanx Again!

Kind Regards,

Gerardo J

gill367
Active Contributor
0 Kudos

HI

I have this SAP EHP 1 for SAP NetWeaver 7.0 evaluation version.

in my office i have 7.0 there i will try and let you know

thanks

sarbjeet.

Former Member
0 Kudos

We have 7.0 in here.

Thanx Alot Sarbjeet!

Former Member
0 Kudos

Hi Again,

I have an idea and I don´t know if it is goor or not, is that creating the Service Call when the RFC structure is declared as LIKE and after the creation done using the Create Service too then change the RFC to use TYPE instead of LIKE and do some testing to check if it is working, does this sound like a good idea? or that would be a big mistake?

Kind Regards,

Gerardo J

Former Member
0 Kudos

> Hi Again,

>

> I have an idea and I don´t know if it is goor or not, is that creating the Service Call when the RFC structure is declared as LIKE and after the creation done using the Create Service too then change the RFC to use TYPE instead of LIKE and do some testing to check if it is working, does this sound like a good idea? or that would be a big mistake?

>

> Kind Regards,

>

> Gerardo J

Hallo Gerado,

That should not be a problem, i would say it is better to use the type instead of using like to type some structure. With respect to abap runtime it does not matter as in either way the base type is already taken into account.

You might have tested your service , does it give any problem ?.

Former Member
0 Kudos

Hi Baskaran,

Thanx again!

We just tryied to change to TYPE but in TYPE it does not allow to declare it with the structure ddic type directly, and the developer did something else to make it work something like using a type Group, and that way in Webdynpro is sending an error.

So maybe is the way is been declarated on the TABLE TAB but I really don´t know what could be happening.

Kind Regards,

Gerardo J

Edited by: Gerardo Jiménez on Jan 21, 2011 7:39 PM

Former Member
0 Kudos

Hi Sarbjeet,

We look into your images again and I noticed that you declared the structure in the import tab and we have the structure declared in the table tab, there is when it is not working in the creation of the Service Call and also in the table tab is not allowing us to declare the table directly with type as you did in the import tab, it is sending an obsolete error when trying to declare the structure directly to a ddic type.

Thanx in advanced

Kind Regards,

Gerardo J

Former Member
0 Kudos

Here I post you the way the declaration is made:


TYPE-POOL ZVITR .
types: begin of ZVITR_ZST0192_VITROOPC.
          INCLUDE STRUCTURE ZST0192_VITROOPC.
types: end of ZVITR_ZST0192_VITROOPC.

types: begin of ZVITR_ZST0192_VITROOPCB.
          INCLUDE STRUCTURE ZST0192_VITROOPCB.
types: end of ZVITR_ZST0192_VITROOPCB.

types: ZVITR_i_VITROOPC  type ZVITR_ZST0192_VITROOPC occurs 0.
types: ZVITR_i_VITROOPCB type ZVITR_ZST0192_VITROOPCB occurs 0.

and in the table type is declared as TYPE ZVITR_i_VITROOPC

but in the webdynpro Service Call creation is not working, and creating it when it was LIKE ZST0192_VITROOPC to TYPE ZVITR_i_VITROOPC is sending errors.

Thanx in advanced!

Kind Regards,

Gerardo J

Former Member
0 Kudos

Hi,

We are still facing the same, has somebody faced this and solved it?

Hope somebody could help.

Kind Regards,

Gerardo J

Former Member
0 Kudos

Has anyone faced this?

Kind Regards,

Gerardo J