Subject VIEW with parameter
Author Christian Kaufmann
Hi,

maybe it's so simple, that I missed it. I have the following view:

CREATE VIEW V_SWISS_ATHLETES
AS

select A.ATHLETEID, A.LASTNAME, A.FIRSTNAME, A.GENDER, A.BIRTHDATE from
ATHLETE A
join CLUB C on A.CLUBID = C.CLUBID
join CLUB CA on A.CLUBID_ALT = CA.CLUBID
where
(C.CLUBTYPE <= 2 and C.CLUBIDNATION = 346) or
(CA.CLUBTYPE <= 2 and CA.CLUBIDNATION = 346)

;


Now instead of having the constant 346 for the nation, I would like that
to be a parameter to do something like this:

select * from V_SWISS_ATHLETES where NATIONID = 346


How do I have to do that?

cu Christian