Plsql:1739 Differences in Validation?

I have the following case in my PL/SQL code

create or replace package body TestPackage as
   procedure TestProc(P_TestIn in pls_integer) is

      cursor c_cursor is
         select * from dual where TEST like '_20%';
   begin
       select count(*) from dual where TEST like '_20%';
   end TestProc;       
end TestPackage;

According to rule RSPEC
I’m wondering why I’m getting an issue on line 5, but NOT on line 7.
Any ideas or an explaination?

Using Sonarqube Version 9.9.1 (build 69595)

Thanks

No idea or explaination on this? (more infos for this case needed?)

Hi @Mathias_Neuner - please accept my apologies for the delay. I’ll try to prioritize looking into this this week.

Thank you for opening this issue and helping us making the products better.

1 Like

Hi,

I’ve opened [SONARPLSQL-820] - Jira as this indeed is a False Negative.

I don’t know why this is happening, it will need more investigation once we’ll do a sprint on the PL/SQL analyzer.

I could reduce the reproducer to:

create or replace package body TestPackage as
   procedure TestProc(P_TestIn in pls_integer) is
   begin
       select * from dual where TEST like '_20%';
   end TestProc;       
end TestPackage;

Could you give more details about the version of PL/SQL that you are using?

Hi!

Thank you for your response!
Currently we are running on Oracle Database 19c.

1 Like

Hi there!
Is there any news on this topic?
Thanks!