Skip to Content
0

oData count invalid number

Oct 30, 2017 at 08:51 AM

61

avatar image

Hello community,

i have encountered a question which gives me a pretty hard time.

I developed a oData Service and now it throwing a exception but only with some datasets.

Exception is "[339] invalid number".

This count works perfectly fine and gives me the count of datasets:

But with another date it doesn't work at all, even if the amount of datasets is the same.

Can anybody provide me some idea whats the problem here?

Best regards

Johannes Sonner

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Best Answer
Arjun Biswas Nov 03, 2017 at 03:57 AM
0

Open your OData project and open the DPC_EXT class :

In the DPC_EXT class go to the get_entityset method of your required entity set :

On opening that method, go to the line where you want to debug and set an EXTERNAL BREAKPOINT, remember if you set an session breakpoint, it might not get triggered when you are executing from the front end.

Now, after setting the breakpoint, give your query on the entityset from the netweaver gateway, if it triggers the your method, then the breakpoint will get executed, and you can debug your errors.

Hope this helps,

Regards.


dpc1.png (14.8 kB)
dpc2.png (91.7 kB)
dpc3.png (149.3 kB)
Show 1 Share
10 |10000 characters needed characters left characters exceeded

Hello Arjun,

thanks for this explicit and very detailled description. This is very nice and descriptive.

Unfortunately I currently do development on SAP HANA in SAP Cloud Platform with xsOData-Services, so this does not fit to my case.

I'll accept this answer because of very detailled and good description. I hope this will help someone else in future.

Best regards

Johannes

1
Arjun Biswas Oct 31, 2017 at 09:40 AM
0

From what I understand, this error might occur due to either there are no records for that particular date, or there is a problem, while parsing the date. Why dont you apply breakpoints in your DPC_EXT class methods, and see where the error is actually occuring.

Show 1 Share
10 |10000 characters needed characters left characters exceeded

Hello Arjun,

must have been some kind of parsing error or something. The same logic executed by scripted view works perfectly fine.

Can you give me a hint how you set such breakpoints?

Best regards

Johannes

0