on 11-05-2015 7:54 AM
Hi all,
We are trying to create an Odata service for Document Number search help.The search help should show (Controlling Area, Document No,Posting date,Document date).The user should pass the Controlling area as a mandatory field to get the search help.
There is no elementary serach help at data element level. So we followed two approaches :
1) Create a CDS view . Call the Get Entity Set method to AMDP which queries from CDS view.
2) Create a Custom Search Help.Import this Search Help in SEGW .
*Now we can have multiple controlling areas as input.
We need to find URI so that we can test our service. For example we tried below :
/sap/opu/odata/SAP/ZCASE_TEST_SRV/Ztest1Set (works fine).
When the user gives Controlling Area :
/sap/opu/odata/SAP/ZCASE_TEST_SRV/Ztest1Set(KOKRS='US00') (No Result , BAd request).
Can we give other parameters as blank like below :
/sap/opu/odata/SAP/ZCASE_TEST_SRV/Ztest1Set(KOKRS='US00',BELNR='') (This also gives no result).
Can we write URI where we can give filter like :
/sap/opu/odata/SAP/ZCASE_TEST_SRV/Ztest1Set?(SIGN='I', OPTION='EQ', LOW='US00', HIGH='') ( Status 200, but no result )
Please suggest URIs so that we can test the Odata service.
Regards,
SHUBHAM
Hi Shubham,
you can specify the filter options in URL but the syntax should not contain phrases. it should be
/sap/opu/odata/SAP/ZCASE_TEST_SRV/Ztest1Set?$filter=<ip1 eq ''> and <ip2 eq ''>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Subham,
A little debug into the Data Provider class will show you why /sap/opu/odata/SAP/ZCASE_TEST_SRV/Ztest1Set(KOKRS='US00',BELNR='') does not return any result.
/sap/opu/odata/SAP/ZCASE_TEST_SRV/Ztest1Set?(SIGN='I', OPTION='EQ', LOW='US00', HIGH='') will not work as SIGN, OPTION, LOW and HIGH are not the properties of the OData service you generated.
Regards
Atanu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
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.