CDS View with Parameters
In CDS (Core Data Services) views, you can use parameters to create dynamic views that accept input values at runtime. These parameters can be used to filter or customize the data being retrieved, making the view more flexible and adaptable for different use cases.
Example of a CDS View with a Parameter
Explanation:
➯ Parameter Declaration: The with parameters clause defines a parameter, p_agency, of type /dmo/agency_id , which is utilized to filter the data.
➯ Using the Parameter: The parameter p_agency is referenced as $parameters.p_agency in the where clause of the SQL query, allowing the data to be filtered based on the provided agency ID.
Key Points:
➯ Parameters enable you to filter or tailor the data returned by the CDS view dynamically at runtime.
➯ They allow external applications or reports to pass values into the view, enhancing its flexibility.
➯ You can define multiple parameters within the with parameters clause.
Let’s Run our CDS and give Agency ID as input

