comparison runtime/syntax/sqlforms.vim @ 7:3fc0f57ecb91 v7.0001

updated for version 7.0001
author vimboss
date Sun, 13 Jun 2004 20:20:40 +0000
parents
children 43efa4f5a8ea
comparison
equal deleted inserted replaced
6:c2daee826b8f 7:3fc0f57ecb91
1 " Vim syntax file
2 " Language: SQL*Forms (Oracle 7), based on sql.vim (vim5.0)
3 " Maintainer: Austin Ziegler (austin@halostatue.ca)
4 " Last Change: 2003 May 11
5 " Prev Change: 19980710
6 " URL: http://www.halostatue.ca/vim/syntax/proc.vim
7 "
8 " TODO Find a new maintainer who knows SQL*Forms.
9
10 " For version 5.x, clear all syntax items.
11 " For version 6.x, quit when a syntax file was already loaded.
12 if version < 600
13 syntax clear
14 elseif exists("b:current_syntax")
15 finish
16 endif
17
18 syntax case ignore
19
20 if version >= 600
21 setlocal iskeyword=a-z,A-Z,48-57,_,.,-,>
22 else
23 set iskeyword=a-z,A-Z,48-57,_,.,-,>
24 endif
25
26
27 " The SQL reserved words, defined as keywords.
28 syntax match sqlTriggers /on-.*$/
29 syntax match sqlTriggers /key-.*$/
30 syntax match sqlTriggers /post-.*$/
31 syntax match sqlTriggers /pre-.*$/
32 syntax match sqlTriggers /user-.*$/
33
34 syntax keyword sqlSpecial null false true
35
36 syntax keyword sqlProcedure abort_query anchor_view bell block_menu break call
37 syntax keyword sqlProcedure call_input call_query clear_block clear_eol
38 syntax keyword sqlProcedure clear_field clear_form clear_record commit_form
39 syntax keyword sqlProcedure copy count_query create_record default_value
40 syntax keyword sqlProcedure delete_record display_error display_field down
41 syntax keyword sqlProcedure duplicate_field duplicate_record edit_field
42 syntax keyword sqlProcedure enter enter_query erase execute_query
43 syntax keyword sqlProcedure execute_trigger exit_form first_Record go_block
44 syntax keyword sqlProcedure go_field go_record help hide_menu hide_page host
45 syntax keyword sqlProcedure last_record list_values lock_record message
46 syntax keyword sqlProcedure move_view new_form next_block next_field next_key
47 syntax keyword sqlProcedure next_record next_set pause post previous_block
48 syntax keyword sqlProcedure previous_field previous_record print redisplay
49 syntax keyword sqlProcedure replace_menu resize_view scroll_down scroll_up
50 syntax keyword sqlProcedure set_field show_keys show_menu show_page
51 syntax keyword sqlProcedure synchronize up user_exit
52
53 syntax keyword sqlFunction block_characteristic error_code error_text
54 syntax keyword sqlFunction error_type field_characteristic form_failure
55 syntax keyword sqlFunction form_fatal form_success name_in
56
57 syntax keyword sqlParameters hide no_hide replace no_replace ask_commit
58 syntax keyword sqlParameters do_commit no_commit no_validate all_records
59 syntax keyword sqlParameters for_update no_restrict restrict no_screen
60 syntax keyword sqlParameters bar full_screen pull_down auto_help auto_skip
61 syntax keyword sqlParameters fixed_length enterable required echo queryable
62 syntax keyword sqlParameters updateable update_null upper_case attr_on
63 syntax keyword sqlParameters attr_off base_table first_field last_field
64 syntax keyword sqlParameters datatype displayed display_length field_length
65 syntax keyword sqlParameters list page primary_key query_length x_pos y_pos
66
67 syntax match sqlSystem /system\.block_status/
68 syntax match sqlSystem /system\.current_block/
69 syntax match sqlSystem /system\.current_field/
70 syntax match sqlSystem /system\.current_form/
71 syntax match sqlSystem /system\.current_value/
72 syntax match sqlSystem /system\.cursor_block/
73 syntax match sqlSystem /system\.cursor_field/
74 syntax match sqlSystem /system\.cursor_record/
75 syntax match sqlSystem /system\.cursor_value/
76 syntax match sqlSystem /system\.form_status/
77 syntax match sqlSystem /system\.last_query/
78 syntax match sqlSystem /system\.last_record/
79 syntax match sqlSystem /system\.message_level/
80 syntax match sqlSystem /system\.record_status/
81 syntax match sqlSystem /system\.trigger_block/
82 syntax match sqlSystem /system\.trigger_field/
83 syntax match sqlSystem /system\.trigger_record/
84 syntax match sqlSystem /\$\$date\$\$/
85 syntax match sqlSystem /\$\$time\$\$/
86
87 syntax keyword sqlKeyword accept access add as asc by check cluster column
88 syntax keyword sqlKeyword compress connect current decimal default
89 syntax keyword sqlKeyword desc exclusive file for from group
90 syntax keyword sqlKeyword having identified immediate increment index
91 syntax keyword sqlKeyword initial into is level maxextents mode modify
92 syntax keyword sqlKeyword nocompress nowait of offline on online start
93 syntax keyword sqlKeyword successful synonym table to trigger uid
94 syntax keyword sqlKeyword unique user validate values view whenever
95 syntax keyword sqlKeyword where with option order pctfree privileges
96 syntax keyword sqlKeyword public resource row rowlabel rownum rows
97 syntax keyword sqlKeyword session share size smallint sql\*forms_version
98 syntax keyword sqlKeyword terse define form name title procedure begin
99 syntax keyword sqlKeyword default_menu_application trigger block field
100 syntax keyword sqlKeyword enddefine declare exception raise when cursor
101 syntax keyword sqlKeyword definition base_table pragma
102 syntax keyword sqlKeyword column_name global trigger_type text description
103 syntax match sqlKeyword "<<<"
104 syntax match sqlKeyword ">>>"
105
106 syntax keyword sqlOperator not and or out to_number to_date message erase
107 syntax keyword sqlOperator in any some all between exists substr nvl
108 syntax keyword sqlOperator exception_init
109 syntax keyword sqlOperator like escape trunc lpad rpad sum
110 syntax keyword sqlOperator union intersect minus to_char greatest
111 syntax keyword sqlOperator prior distinct decode least avg
112 syntax keyword sqlOperator sysdate true false field_characteristic
113 syntax keyword sqlOperator display_field call host
114
115 syntax keyword sqlStatement alter analyze audit comment commit create
116 syntax keyword sqlStatement delete drop explain grant insert lock noaudit
117 syntax keyword sqlStatement rename revoke rollback savepoint select set
118 syntax keyword sqlStatement truncate update if elsif loop then
119 syntax keyword sqlStatement open fetch close else end
120
121 syntax keyword sqlType char character date long raw mlslabel number rowid
122 syntax keyword sqlType varchar varchar2 float integer boolean global
123
124 syntax keyword sqlCodes sqlcode no_data_found too_many_rows others
125 syntax keyword sqlCodes form_trigger_failure notfound found
126 syntax keyword sqlCodes validate no_commit
127
128 " Comments:
129 syntax region sqlComment start="/\*" end="\*/"
130 syntax match sqlComment "--.*"
131
132 " Strings and characters:
133 syntax region sqlString start=+"+ skip=+\\\\\|\\"+ end=+"+
134 syntax region sqlString start=+'+ skip=+\\\\\|\\"+ end=+'+
135
136 " Numbers:
137 syntax match sqlNumber "-\=\<[0-9]*\.\=[0-9_]\>"
138
139 syntax sync ccomment sqlComment
140
141 if version >= 508 || !exists("did_sqlforms_syn_inits")
142 if version < 508
143 let did_sqlforms_syn_inits = 1
144 command -nargs=+ HiLink hi link <args>
145 else
146 command -nargs=+ HiLink hi def link <args>
147 endif
148
149 HiLink sqlComment Comment
150 HiLink sqlKeyword Statement
151 HiLink sqlNumber Number
152 HiLink sqlOperator Statement
153 HiLink sqlProcedure Statement
154 HiLink sqlFunction Statement
155 HiLink sqlSystem Identifier
156 HiLink sqlSpecial Special
157 HiLink sqlStatement Statement
158 HiLink sqlString String
159 HiLink sqlType Type
160 HiLink sqlCodes Identifier
161 HiLink sqlTriggers PreProc
162
163 delcommand HiLink
164 endif
165
166 let b:current_syntax = "sqlforms"
167
168 " vim: ts=8 sw=4