4 weeks ago - last edited 4 weeks ago
Hi Everyone,
I'm working on a BTP service using CAP with Java, and need some help with OData functions. Here's a simplified version of what I have in my `service.cds`:
function testfunction(id: String, secondparam: String) returns String;
The issue I'm facing is that both `id` and `secondparam` are required parameters. However, I want secondparam to be optional. Currently, if I omit `secondparam` when calling the function, I get an error.
Does anyone know how to make the `secondparam` optional in this case? Any guidance or examples would be greatly appreciated!
Thanks in advance! 😊
Request clarification before answering.
User | Count |
---|---|
54 | |
10 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.