on 02-14-2007 6:39 AM
Hi,
I am facing issues while accessing Business Logic in my class. I am using the same types in all the cases(in the class & also in my BSP).
the issue is only coming when I use Business Logic(Select statement) inside a class and if I remove the same, I am getting the things.
My issue is that I am not able to get the value into my BSP from the select statment in the Class.
My BL in the class is as under:
select single zname1
from
zcust_vis
into
eid where zcid = attr1.
attr1 ,zname1 ,zcid and eid are of the same data type.
attr1 is an attribute defined for the class....
BSP looks like this:
call method application->GET_CUSTOMER exporting cid = cust_id
importing eid = c_id.
here above, I was trying to export a value(say 1000) and executing the BL in the class and importing the value of "zname1" into my BSP using but, I could not get any value into the "c_id" parameter....and instead the value is a Blank, and in the table it has got some value and it is not a Blank for the field "zname1".
I hope the problem seems to be clear now... Please let me know what needs to be done to overcome this issue.
Thanks & Regards,
Vishnu.
Hi Vishnu,
let's say your database table zcust_vis has a column zname1 and a column zcid. Now you use the select statement:
select single zname1
from zcust_vis
into eid
where zcid = attr1.
Now eid has to be the same data type as used for zname1 and attr1 has to be the same type as zcid.
To get a value from the select statement you have to fill attr1, so a call from a BSP has to be:
application->GET_CUSTOMER exporting attr1 = 'a value'
importing eid = c_id.
c_id has to be declared in the BSP and has to be of the same type as eid.
Regards,
Rainer
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I am not able to get what you are asking me to do.
When I can see the value in the class(for cid) and assign it to the attribute of the class, I don't see any fault in executing the select statement.
So please kindly let me know "you apply a value for cid, but not for attr1" what it means from your reply.
thanks in advance.
Regards,
Vishnu.
Hi Raja,
Thanks for your answer.
But, I am not able to get into debugging mode while running the BSP Application. And am able to get the return values(only if I do not use a Select Statement in the BL of the Model class) without getting into the debugging mode. Even if I put a debug statment after the Select, I could not get into debugging mode.
So kindly please let me know how to proceed with this case.
Thanks in advance.
Regards,
Vishnu.
You need to put the external break-point not session break-point.
Also you need to Active External break-point for HTTP. YOu can find this option in
SE80, in
Utilites--> Break-point/External break-point or Utilites--> External break-point --> Set External break-point
or if you dont find, then
utilities-->setttings -> ABAP Workbench -> look at the debugger tab
& find the external Debugging check box or External Debugging user ID. Give SAP User ID
Also have a look at this..
http://help.sap.com/saphelp_nw2004s/helpdata/en/17/00ab3b72d5df3be10000000a11402f/frameset.htm
<i>* Reward each useful answer</i>
Raja T
Hello Vishnu...
Is your application is page with flow logic?
Are you calling this method
<b>call method application->GET_CUSTOMER exporting cid = cust_id
importing eid = c_id.</b>
in OnInputProcessing? and Are your doing something with c_id in OnInitialization?
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Saurabh,
Thanks for the information.
Actually, I using a page with flow logic and I am not using any events but, I was trying to call the method from my Layout itself by using "<% %>" (scriptlet).
Here, I am getting values from the class but, only if I use some manipulation of data (and this is not with a Select statement logic).
If I use a Select statement to get data from a table, I am not able to get the things into the attributes of the class....
So please let me know what needs to be done in this regard and let me also have your experiences over this kind of issue.
Thanks & Regards,
Vishnu.
Hello Vishnu
if your <b> cust_id </b> is string or char type and you are using it in where condition, please check, if it has any leading space. Or better condense this cust_id.
I am not sure whether your select query is working or not. And my thought may be one of the cause.
regards
Saurabh Garg
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.