public.browse_by_category
Documentation | Dell DVD Store |
Schema | public |
Name | browse_by_category |
Brows products(DVD films) by category.
Input/Output
Mode | Name | Data type | Description | |
---|---|---|---|---|
1 | OUT | Returns | products | Returns film's list. |
Returns film's list. | ||||
2 | IN | batch_size_in | integer | Films's limit. |
Films's limit. | ||||
3 | IN | category_in | integer | Category identification number |
Category identification number |
Script
CREATE OR REPLACE FUNCTION public.browse_by_category(batch_size_in integer, category_in integer) RETURNS SETOF products LANGUAGE plpgsql AS $function$ BEGIN RETURN QUERY SELECT * FROM PRODUCTS WHERE CATEGORY=category_in AND SPECIAL=1 LIMIT batch_size_in; RETURN; END; $function$ |
Exported: 2018-11-09 16:14, Last imported: 2018-08-06 09:39