Hi there,
hopefully somebody can help me out because I'm having some strange problem with Databinding in one of my MVC-BSPs.
When executing I am running into an "SAP Internal Server Error" telling me that there is a parameter missing for a dynamic function call.
After some debugging and testing the code triggering this is within my view:
<htmlb:dropdownListBox id = "x_y_ddb" table = "<%=w_table%>" selection = "//mymodel/my_table[1].w" nameOfKeyColumn = "name" nameOfValueColumn = "value" disabled = "<%=flag%>" > </htmlb:dropdownListBox>
This code was running ok last week. After some modifications in the model- and the controllerclass it is not running anymore. The strange thing is that I did not change anything regarding the used table or the attributes...
When debugging I found out that the method causing the error is "selection_model->get_attribute( attribute_path = selection_path )."
The attribute selection_path is correctly filled with "my_table[1].w". So all needed parameters are filled as this is the only one passed.
The method is called from "RESOLVE_MODEL_BINDING" of class "CL_HTMLB_DROPDOWNLISTBOX".
After trying a few things I have no more ideas. The error only occurs when binding to the table. Upon binding to a structure or to a field ev erything works fine.
Thing is, Im am 99% sure this worked last week and I can't remember having changed anything directly connected to this. I am still able to see the data that was created during testing last week.
Any ideas for me?
Thanks,
Alex
Hi again,
I finally found the solution to my problem.
First of all I really like to credit Thomas Jung for his answers in this thread:
I didn't realize that there is a shortdump generated in the system in case of a RABAX_STATE. This definitly saved my day because I was able to track my problem down to this:
As stated above I have an attribute named "my_table" defined in the modelclass. This attribute is called via databinding from within the view.
Something else I have is a method within the model which is called "get_my_table". This method was meant to read some more informations from other databasetables to achieve a more user-friendly output in a tableview (via iterator).
The shortdump told me that it is not the "selection_model->get_attribute( ... )" method which misses a parameter but "get_my_table".
After renaming my method to sth. like "get_my_table_text" everything works fine - no more shortdumps.
My conclusion is that during runtime a method called "get_my_table" is created dynamically for the databinding. Because I allready defined this method the wrong one gets called.
Only remainig question: is it my fault because one should never name a method "get_<i>attributename</i>" which is not returning the parameter itself but something else or is this some sort of bug?
For the record: we are on 620 SP41 with some fixes from note 616900.
Any information/documentation on this?
Regards,
Alex
Add a comment