-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
31 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
PS002: Unsafe function creation: w1() at line 1 | ||
PS005: Function without explicit search_path: w1() at line 1 | ||
PS017: Unqualified object reference: bool in CAST(format1('%s', 'false') AS bool) at line 1 | ||
PS016: Unqualified function call: format1 at line 1 | ||
PS001: Unqualified operator: '<' in 0 < _count at line 1 | ||
PS001: Unqualified operator: '-' in _count - 1 at line 1 | ||
PS016: Unqualified function call: format2 at line 1 | ||
|
||
Errors: 1 Warnings: 6 Unknown: 0 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
create or replace function w1() returns void as $func$ | ||
declare | ||
_count bigint; | ||
begin | ||
select 100 into strict _count; | ||
while format1('%s','false')::bool loop | ||
end loop; | ||
while 0 < _count loop | ||
_count := _count - 1; | ||
PERFORM format2('%s','true'); | ||
end loop; | ||
end | ||
$func$ language plpgsql; |