Missed reserved keywords

Hello,

It seems that PL/SQL Developer is missing some reserved words from its Oracle dictionary.
Here is my custom.kwf that fixes this issue:

round
rownum
userenv
chr
length
initcap
ceil
floor
last_day
instr
ltrim
rtrim
trim
lpad
rpad
lower
upper
nvl
decode
substr
trunc
to_date
to_char
to_number
ascii

I guess, it will not be a huge change for the following release of PL/SQL Developer.

Thanks for great tool!
Boris :)
 
@Boris: These are not reserved keywords: they are SQL functions. Only language syntax elements are included. If you prefer, you can add them to plsql.kwf, sql.kwf and command.kwf though.

@BWendling: We'll add these.
 
I think the vast majority of us don't care whether these are called "reserved words", "functions", "keywords" or anything else. We just want the editor to highlight language elements like SELECT and UPPER differently from table and column names and program variables.

My current list is:

ASCII
CEIL
CHR
CORR
COVAR_POP
COVAR_SAMP
CUME_DIST
DECODE
DENSE_RANK
FIRST_VALUE
FLOOR
GROUPING_ID
GROUP_ID
INITCAP
INSTR
LAST_DAY
LAST_VALUE
LEAD
LENGTH
LOWER
LPAD
LTRIM
NTILE
NULLIF
NVL
NVL2
OVER
PERCENTILE_CONT
PERCENTILE_DISC
PERCENT_RANK
RANK
RATIO_TO_REPORT
ROUND
ROWNUM
ROW_NUMBER
RPAD
RTRIM
SIGN
STDDEV_POP
STDDEV_SAMP
SUBSTR
SYSTIMESTAMP
SYS_CONTEXT
TO_CHAR
TO_CLOB
TO_DATE
TO_NUMBER
TO_TIMESTAMP
TRANSLATE
TRIM
TRUNC
UPPER
USERENV
VAR_POP
VAR_SAMP

Spurious keywords, sorry, Language Elements:

LABEL
NAME -- Part of ALTER SESSION syntax
SECTION
SWITCH -- Part of ALTER SYSTEM SWITCH LOGFILE
SYS
UPPERCASE
UPSERT
 
how about adding another class of word?
"Functions" maybe..

this way, they will have their own colour and can be coloured anywhere from beige to brown, green to grey or yellow to ... ( some other colour that starts with y )
 
Attempts to colour types of keywork differently just complicate things IMHO. For example analytic windowing elements such as OVER and PARTITION BY would be in a different colour to the analytic functions. If you decide they are part of the function, then ORDER, BY and PARTITION have other contexts where they are not. And what about ELSE? It's both a SQL keyword (part of CASE, arguably the same colour as DECODE) and a PL/SQL one (part of IF).

I recently edited the syntax highlighting files for PL/SQL in Vim and simplified things a lot. Previously AND was a different colour to WHERE, etc etc.
 
Back
Top