For example: I have a VIEW called \"view1\" which contains \'name\' and \'slno\' columns, now i want it to be display using FUNCTION called \"f1\" as shown below:
--Func
This is dynamic SQL, so you need EXECUTE.
EXECUTE
RETURN QUERY EXECUTE format('SELECT * FROM %I', "name");
Separately, that's a weird thing to want to do.