How to return rows from a declare/begin/end block in Oracle?

Viewed 43368

I want to return rows from a select statement within a declare/begin/end block. I can do this in T-SQL but I would like to know how to do it in PL/SQL.

The code looks a bit like the following:

declare
     blah number := 42;
begin
     select *
     from x
     where x.value = blah;
end;
2 Answers
Related