| 1 |
{ |
| 2 |
"fileTypes": ["sql", "ddl", "dml", "pkh", "pks", "pkb", "pck", "pls", "plb"], |
| 3 |
"foldingStartMarker": "(?i)^\\s*(begin|if|loop)\\b", |
| 4 |
"foldingStopMarker": "(?i)^\\s*(end)\\b", |
| 5 |
"keyEquivalent": "^~S", |
| 6 |
"name": "plsql", |
| 7 |
"patterns": [ |
| 8 |
{ |
| 9 |
"begin": "/\\*", |
| 10 |
"end": "\\*/", |
| 11 |
"name": "comment.block.oracle" |
| 12 |
}, |
| 13 |
{ |
| 14 |
"match": "--.*$", |
| 15 |
"name": "comment.line.double-dash.oracle" |
| 16 |
}, |
| 17 |
{ |
| 18 |
"match": "(?i)(?:^\\s*)rem(?:\\s+.*$)", |
| 19 |
"name": "comment.line.sqlplus.oracle" |
| 20 |
}, |
| 21 |
{ |
| 22 |
"match": "(?i)(?:^\\s*)prompt(?:\\s+.*$)", |
| 23 |
"name": "comment.line.sqlplus-prompt.oracle" |
| 24 |
}, |
| 25 |
{ |
| 26 |
"captures": { |
| 27 |
"1": { |
| 28 |
"name": "keyword.other.oracle" |
| 29 |
}, |
| 30 |
"2": { |
| 31 |
"name": "keyword.other.oracle" |
| 32 |
} |
| 33 |
}, |
| 34 |
"match": "(?i)^\\s*(create)(\\s+or\\s+replace)?\\s+", |
| 35 |
"name": "meta.create.oracle" |
| 36 |
}, |
| 37 |
{ |
| 38 |
"captures": { |
| 39 |
"1": { |
| 40 |
"name": "keyword.other.oracle" |
| 41 |
}, |
| 42 |
"2": { |
| 43 |
"name": "keyword.other.oracle" |
| 44 |
}, |
| 45 |
"3": { |
| 46 |
"name": "entity.name.type.oracle" |
| 47 |
} |
| 48 |
}, |
| 49 |
"match": "(?i)\\b(package)(\\s+body)?\\s+(\\S+)", |
| 50 |
"name": "meta.package.oracle" |
| 51 |
}, |
| 52 |
{ |
| 53 |
"captures": { |
| 54 |
"1": { |
| 55 |
"name": "keyword.other.oracle" |
| 56 |
}, |
| 57 |
"2": { |
| 58 |
"name": "entity.name.type.oracle" |
| 59 |
} |
| 60 |
}, |
| 61 |
"match": "(?i)\\b(type)\\s+\"([^\"]+)\"", |
| 62 |
"name": "meta.type.oracle" |
| 63 |
}, |
| 64 |
{ |
| 65 |
"captures": { |
| 66 |
"1": { |
| 67 |
"name": "keyword.other.oracle" |
| 68 |
}, |
| 69 |
"2": { |
| 70 |
"name": "entity.name.function.oracle" |
| 71 |
} |
| 72 |
}, |
| 73 |
"match": "(?i)^\\s*(function|procedure)\\s+\"?([-a-z0-9_]+)\"?", |
| 74 |
"name": "meta.procedure.oracle" |
| 75 |
}, |
| 76 |
{ |
| 77 |
"match": "[!<>:]?=|<>|<|>|\\+|(?<!\\.)\\*|-|(?<!^)/|\\|\\|", |
| 78 |
"name": "keyword.operator.oracle" |
| 79 |
}, |
| 80 |
{ |
| 81 |
"match": "(?i)\\b(true|false|null|is\\s+(not\\s+)?null)\\b", |
| 82 |
"name": "constant.language.oracle" |
| 83 |
}, |
| 84 |
{ |
| 85 |
"match": "\\b\\d+(\\.\\d+)?\\b", |
| 86 |
"name": "constant.numeric.oracle" |
| 87 |
}, |
| 88 |
{ |
| 89 |
"match": "(?i)\\b(if|elsif|else|end\\s+if|loop|end\\s+loop|for|while|case|end\\s+case|continue|return|goto)\\b", |
| 90 |
"name": "keyword.control.oracle" |
| 91 |
}, |
| 92 |
{ |
| 93 |
"match": "(?i)\\b(or|and|not|like)\\b", |
| 94 |
"name": "keyword.other.oracle" |
| 95 |
}, |
| 96 |
{ |
| 97 |
"match": "(?i)\\b(%(isopen|found|notfound|rowcount)|commit|rollback|sqlerrm)\\b", |
| 98 |
"name": "support.function.oracle" |
| 99 |
}, |
| 100 |
{ |
| 101 |
"match": "(?i)\\b(sql|sqlcode)\\b", |
| 102 |
"name": "variable.language.oracle" |
| 103 |
}, |
| 104 |
{ |
| 105 |
"match": "(?i)\\b(ascii|asciistr|chr|compose|concat|convert|decompose|dump|initcap|instr|instrb|instrc|instr2|instr4|unistr|length|lengthb|lengthc|length2|length4|lower|lpad|ltrim|nchr|replace|rpad|rtrim|soundex|substr|translate|trim|upper|vsize)\\b", |
| 106 |
"name": "support.function.builtin.char.oracle" |
| 107 |
}, |
| 108 |
{ |
| 109 |
"match": "(?i)\\b(add_months|current_date|current_timestamp|dbtimezone|last_day|localtimestamp|months_between|new_time|next_day|round|sessiontimezone|sysdate|tz_offset|systimestamp)\\b", |
| 110 |
"name": "support.function.builtin.date.oracle" |
| 111 |
}, |
| 112 |
{ |
| 113 |
"match": "(?i)\\b(avg|count|sum|max|min|median|corr|corr_\\w+|covar_(pop|samp)|cume_dist|dense_rank|first|group_id|grouping|grouping_id|last|percentile_cont|percentile_disc|percent_rank|rank|regr_\\w+|row_number|stats_binomial_test|stats_crosstab|stats_f_test|stats_ks_test|stats_mode|stats_mw_test|stats_one_way_anova|stats_t_test_\\w+|stats_wsr_test|stddev|stddev_pop|stddev_samp|var_pop|var_samp|variance)\\b", |
| 114 |
"name": "support.function.builtin.aggregate.oracle" |
| 115 |
}, |
| 116 |
{ |
| 117 |
"match": "(?i)\\b(bfilename|cardinality|coalesce|decode|empty_(blob|clob)|lag|lead|listagg|lnnvl|nanvl|nullif|nvl|nvl2|sys_(context|guid|typeid|connect_by_path|extract_utc)|uid|(current\\s+)?user|userenv|cardinality|(bulk\\s+)?collect|powermultiset(_by_cardinality)?|ora_hash|standard_hash|execute\\s+immediate|alter\\s+session)\\b", |
| 118 |
"name": "support.function.builtin.advanced.oracle" |
| 119 |
}, |
| 120 |
{ |
| 121 |
"match": "(?i)\\b(bin_to_num|cast|chartorowid|from_tz|hextoraw|numtodsinterval|numtoyminterval|rawtohex|rawtonhex|to_char|to_clob|to_date|to_dsinterval|to_lob|to_multi_byte|to_nclob|to_number|to_single_byte|to_timestamp|to_timestamp_tz|to_yminterval|scn_to_timestamp|timestamp_to_scn|rowidtochar|rowidtonchar|to_binary_double|to_binary_float|to_blob|to_nchar|con_dbid_to_id|con_guid_to_id|con_name_to_id|con_uid_to_id)\\b", |
| 122 |
"name": "support.function.builtin.convert.oracle" |
| 123 |
}, |
| 124 |
{ |
| 125 |
"match": "(?i)\\b(abs|acos|asin|atan|atan2|bit_(and|or|xor)|ceil|cos|cosh|exp|extract|floor|greatest|least|ln|log|mod|power|remainder|round|sign|sin|sinh|sqrt|tan|tanh|trunc)\\b", |
| 126 |
"name": "support.function.builtin.math.oracle" |
| 127 |
}, |
| 128 |
{ |
| 129 |
"match": "(?i)\\b(\\.(count|delete|exists|extend|first|last|limit|next|prior|trim|reverse))\\b", |
| 130 |
"name": "support.function.builtin.collection.oracle" |
| 131 |
}, |
| 132 |
{ |
| 133 |
"match": "(?i)\\b(cluster_details|cluster_distance|cluster_id|cluster_probability|cluster_set|feature_details|feature_id|feature_set|feature_value|prediction|prediction_bounds|prediction_cost|prediction_details|prediction_probability|prediction_set)\\b", |
| 134 |
"name": "support.function.builtin.data_mining.oracle" |
| 135 |
}, |
| 136 |
{ |
| 137 |
"match": "(?i)\\b(appendchildxml|deletexml|depth|extract|existsnode|extractvalue|insertchildxml|insertxmlbefore|xmlcast|xmldiff|xmlelement|xmlexists|xmlisvalid|insertchildxmlafter|insertchildxmlbefore|path|sys_dburigen|sys_xmlagg|sys_xmlgen|updatexml|xmlagg|xmlcdata|xmlcolattval|xmlcomment|xmlconcat|xmlforest|xmlparse|xmlpi|xmlquery|xmlroot|xmlsequence|xmlserialize|xmltable|xmltransform)\\b", |
| 138 |
"name": "support.function.builtin.xml.oracle" |
| 139 |
}, |
| 140 |
{ |
| 141 |
"match": "(?i)\\b(pragma\\s+(autonomous_transaction|serially_reusable|restrict_references|exception_init|inline))\\b", |
| 142 |
"name": "keyword.other.pragma.oracle" |
| 143 |
}, |
| 144 |
{ |
| 145 |
"match": "(?i)\\b(p(i|o|io)_[-a-z0-9_]+)\\b", |
| 146 |
"name": "variable.parameter.oracle" |
| 147 |
}, |
| 148 |
{ |
| 149 |
"match": "(?i)\\b(l_[-a-z0-9_]+)\\b", |
| 150 |
"name": "variable.other.oracle" |
| 151 |
}, |
| 152 |
{ |
| 153 |
"match": "(?i):\\b(new|old)\\b", |
| 154 |
"name": "variable.trigger.oracle" |
| 155 |
}, |
| 156 |
{ |
| 157 |
"match": "(?i)\\b(connect\\s+by\\s+(nocycle\\s+)?(prior|level)|connect_by_(root|icycle)|level|start\\s+with)\\b", |
| 158 |
"name": "keyword.hierarchical.sql.oracle" |
| 159 |
}, |
| 160 |
{ |
| 161 |
"match": "(?i)\\b(language|name|java|c)\\b", |
| 162 |
"name": "keyword.wrapper.oracle" |
| 163 |
}, |
| 164 |
{ |
| 165 |
"match": "(?i)\\b(end|then|deterministic|exception|when|declare|begin|in|out|nocopy|is|as|exit|open|fetch|into|close|subtype|type|rowtype|default|exclusive|mode|lock|record|index\\s+by|result_cache|constant|comment|\\.(nextval|currval))\\b", |
| 166 |
"name": "keyword.other.oracle" |
| 167 |
}, |
| 168 |
{ |
| 169 |
"match": "(?i)\\b(grant|revoke|alter|drop|force|add|check|constraint|primary\\s+key|foreign\\s+key|references|unique(\\s+index)?|column|sequence|increment\\s+by|cache|(materialized\\s+)?view|trigger|storage|tablespace|pct(free|used)|(init|max)trans|logging)\\b", |
| 170 |
"name": "keyword.other.ddl.oracle" |
| 171 |
}, |
| 172 |
{ |
| 173 |
"match": "(?i)\\b(with|select|from|where|order\\s+(siblings\\s+)?by|group\\s+by|rollup|cube|((left|right|cross|natural)\\s+(outer\\s+)?)?join|on|asc|desc|update|set|insert|into|values|delete|distinct|union|minus|intersect|having|limit|table|between|like|of|row|(range|rows)\\s+between|nulls\\s+first|nulls\\s+last|before|after|all|any|exists|rownum|cursor|returning|over|partition\\s+by|merge|using|matched|pivot|unpivot)\\b", |
| 174 |
"name": "keyword.other.sql.oracle" |
| 175 |
}, |
| 176 |
{ |
| 177 |
"match": "(?i)\\b(define|whenever\\s+sqlerror|exec|timing\\s+start|timing\\s+stop)\\b", |
| 178 |
"name": "keyword.other.sqlplus.oracle" |
| 179 |
}, |
| 180 |
{ |
| 181 |
"match": "(?i)\\b(access_into_null|case_not_found|collection_is_null|cursor_already_open|dup_val_on_index|invalid_cursor|invalid_number|login_denied|no_data_found|not_logged_on|program_error|rowtype_mismatch|self_is_null|storage_error|subscript_beyond_count|subscript_outside_limit|sys_invalid_rowid|timeout_on_resource|too_many_rows|value_error|zero_divide|others)\\b", |
| 182 |
"name": "support.type.exception.oracle" |
| 183 |
}, |
| 184 |
{ |
| 185 |
"captures": { |
| 186 |
"3": { |
| 187 |
"name": "support.class.oracle" |
| 188 |
} |
| 189 |
}, |
| 190 |
"match": "(?i)\\b((dbms|utl|owa|apex)_\\w+\\.(\\w+))\\b", |
| 191 |
"name": "support.function.oracle" |
| 192 |
}, |
| 193 |
{ |
| 194 |
"captures": { |
| 195 |
"3": { |
| 196 |
"name": "support.class.oracle" |
| 197 |
} |
| 198 |
}, |
| 199 |
"match": "(?i)\\b((htf|htp)\\.(\\w+))\\b", |
| 200 |
"name": "support.function.oracle" |
| 201 |
}, |
| 202 |
{ |
| 203 |
"captures": { |
| 204 |
"3": { |
| 205 |
"name": "support.class.user-defined.oracle" |
| 206 |
} |
| 207 |
}, |
| 208 |
"match": "(?i)\\b((\\w+_pkg|pkg_\\w+)\\.(\\w+))\\b", |
| 209 |
"name": "support.function.user-defined.oracle" |
| 210 |
}, |
| 211 |
{ |
| 212 |
"match": "(?i)\\b(raise|raise_application_error)\\b", |
| 213 |
"name": "support.function.oracle" |
| 214 |
}, |
| 215 |
{ |
| 216 |
"begin": "'", |
| 217 |
"end": "'", |
| 218 |
"name": "string.quoted.single.oracle" |
| 219 |
}, |
| 220 |
{ |
| 221 |
"begin": "\"", |
| 222 |
"end": "\"", |
| 223 |
"name": "string.quoted.double.oracle" |
| 224 |
}, |
| 225 |
{ |
| 226 |
"match": "(?i)\\b(char|varchar|varchar2|nchar|nvarchar2|boolean|date|timestamp(\\s+with(\\s+local)?\\s+time\\s+zone)?|interval\\s*day(\\(\\d*\\))?\\s*to\\s*month|interval\\s*year(\\(\\d*\\))?\\s*to\\s*second(\\(\\d*\\))?|xmltype|blob|clob|nclob|bfile|long|long\\s+raw|raw|number|integer|decimal|smallint|float|binary_(float|double|integer)|pls_(float|double|integer)|rowid|urowid|vararray|natural|naturaln|positive|positiven|signtype|simple_(float|double|integer))\\b", |
| 227 |
"name": "storage.type.oracle" |
| 228 |
} |
| 229 |
], |
| 230 |
"scopeName": "source.plsql.oracle", |
| 231 |
"uuid": "28DCE4DD-F5E1-4ED3-8847-64DA6B1F9163" |
| 232 |
} |
| 233 |
|