v8.8.6 - the function list is not working
-
Hi,
Was it only me? I updated to the v8.8.6 version, but the function list was not displaying any functions at all. I re-downloaded and re-installed the version and all that but still missing. I finally re-installed the v8.8.5 and the funtion list is now working properly.
Thank you.
- Vanessa
-
I don’t know if it’s just you, but I can get FunctionList to display functions in v8.6.6:
Do you have example code that you could paste (use the
</>
button)? If so, please show a screenshot of the entire N++ window for both 8.8.5 and 8.8.6. (If you don’t want to uninstall your 8.8.5 for now, I understand. You can download a portable 8.8.6 and run the newer version from a portable directory, to do the comparison.) -
Thank you for showing me your screenshot. Here are mine.
They are the same file.
In v.8.8.5, there is the down arrow symbol showing it is expandable.
In v.8.8.6, there is the dash instead.Thank you.
- Vanessa
-
I was hoping for the whole window in the screenshot, so I could confirm both copies were actually treating the SQL as SQL, and not something else. Ah, well.
Since you didn’t supply any SQL that replicated the problem (the screenshot wasn’t sufficient, because of course an incomplete
create or replace PACKAGE
and a commented-out block of code won’t show any procedures in the FunctionList panel), I grabbed the UnitTest example SQL from the Notepad++ source code (which is the file it uses to verify that the FunctionList is working correctly when Notepad++ is built).You can download the raw version here, and save it as
unitTest.sql
. If you open that with your installed Notepad++, does the Function List look like mine?If so, then it’s something unique to your SQL code.
However, v8.8.6 did change the functionList parser for SQL, compared to v8.8.5, in this change.
If the old version worked the way you liked, and the new version does not, you can override the pre-installed copy with the old one:
- Download the older
functionList\sql.xml
- In Windows Explorer, go to
%AppData%\Notepad++\
- If there’s not a
functionList
subdirectory, create it - save the downloaded
functionList\sql.xml
to that directory (thus save it as%AppData%\Notepad++\functionList\sql.xml
) - If you exit and restart Notepad++, it should use the one in your AppData hierarchy, rather than the one in the installation directory, and should thus use the old rules, so it should start working for you.
Since Notepad++ doesn’t overwrite the files in
%AppData%\Notepad++\functionList\
during upgrades or installations, you should be able to upgrade Notepad++ in the future without it clobbering your preferred functionList definition.IF you can create a dummy (non-proprietary) SQL file that worked under the old FunctionList but shows no functions under v8.6.6 FunctionList, we could report a regression to the Developer, because it means that the “fixed” version doesn’t work with all the SQL functions that the old syntax did.
- Download the older
-
Got it. Here I attached the header of a demo package. I did not include the body, but it does not matter.
The same file loaded in v.8.8.5 and v.8.8.6.
I am happy to use v.8.8.5. I just realized this behavior last week. I have been coding in the same style and using Notepadd++ for the past 5 years. This is just the first time I am seeing this. I am not sure if this was just my code or something else. I do see that you do not have this problem.
demo code for you to recreate.
create or replace PACKAGE jus_general_pkg AS procedure proc01 ( p_id in varchar2 , p_status out varchar2 ) ; procedure proc02 ( p_id in varchar2 , p_status out varchar2 ) ; END jus_general_pkg;
-
Thanks for sharing that. Unfortunately, I cannot replicate.
here’s what I get with v8.8.5:
and here’s what I get with v8.8.6:
The FunctionList results look the same to me.
Oh, wait. I just saw you don’t have a newline at the end, whereas I do. If I delete the newline, and click the refresh, I can see the problem in v8.8.6:
-
Ah… I just saw the same thing. Yes, I downloaded your code and the last / was also something I do not have after END;
The new line was the culprit. That was a easy fix. I could add a new line after.
Thank you.
- Vanessa
-
@tino-tesu said in v8.8.6 - the function list is not working:
That was a easy fix. I could add a new line after.
Great.
Notepad++ has a long-standing bug wherein if you have a FunctionList parser that includes a class, every class must have one or more whitespace after the last “closing” tag. Usually, it shows up with C/C++ classes, which end with
}
… but the bug also occurs for other classes in functionLists.The reason why v8.8.5 worked without the newline is because the v8.8.5 FunctionList parser for SQL didn’t try to do classes, so didn’t trigger that bug.