"SELECT a, b, c FROM foo WHERE foo.a =1 and foo.b LIKE 'station'",
"SELECT * FROM (SELECT * FROM foobar) WHERE foo.a =1 and foo.b LIKE 'station'",
"SELECT * FROM lolz WHERE ( foo.a =1 ) and foo.b LIKE 'station'",
+ "SELECT * LIMIT 5 OFFSET 5 FROM lolz ",
+ "SELECT * LIMIT 5 5 FROM lolz ",
+ "SELECT SKIP 5 FIRST 5 * FROM lolz ",
+ "SELECT FIRST 5 SKIP 5 * FROM lolz ",
"UPDATE session SET expires = ? WHERE (id = ?)",
"INSERT INTO Request (creation_date, is_private, owner_id, request) VALUES (? , ? , ? , ?)",
"SELECT [screen].[id], [screen].[name], [screen].[section_id], [screen].[xtype] FROM [users_roles] [me] JOIN [roles] [role] ON [role].[id] = [me].[role_id] JOIN [roles_permissions] [role_permissions] ON [role_permissions].[role_id] = [role].[id] JOIN [permissions] [permission] ON [permission].[id] = [role_permissions].[permission_id] JOIN [permissionscreens] [permission_screens] ON [permission_screens].[permission_id] = [permission].[id] JOIN [screens] [screen] ON [screen].[id] = [permission_screens].[screen_id] WHERE ( [me].[user_id] = ? ) GROUP BY [screen].[id], [screen].[name], [screen].[section_id], [screen].[xtype]",
'GROUP \s+ BY',
'HAVING',
'ORDER \s+ BY',
+ 'SKIP',
+ 'FIRST',
'LIMIT',
'OFFSET',
'FOR',
set => 1,
into => 1,
values => 1,
+ limit => 1,
+ offset => 1,
+ skip => 1,
+ first => 1,
);
my %profiles = (
'group by' => [$c->('yellow'), $c->('reset')],
'order by' => [$c->('yellow'), $c->('reset')],
+
+ skip => [$c->('green'), $c->('reset')],
+ first => [$c->('green'), $c->('reset')],
+ limit => [$c->('green'), $c->('reset')],
+ offset => [$c->('green'), $c->('reset')],
}
);
} : (),
'insert into' => ['<span class="insert-into">' , '</span>'],
update => ['<span class="select">' , '</span>'],
'delete from' => ['<span class="delete-from">' , '</span>'],
- where => ['<span class="where">' , '</span>'],
+
+ set => ['<span class="set">', '</span>'],
from => ['<span class="from">' , '</span>'],
+
+ where => ['<span class="where">' , '</span>'],
+ values => ['<span class="values">', '</span>'],
+
join => ['<span class="join">' , '</span>'],
+ 'left join' => ['<span class="left-join">','</span>'],
on => ['<span class="on">' , '</span>'],
+
'group by' => ['<span class="group-by">', '</span>'],
'order by' => ['<span class="order-by">', '</span>'],
- set => ['<span class="set">', '</span>'],
- into => ['<span class="into">', '</span>'],
- values => ['<span class="values">', '</span>'],
+
+ skip => ['<span class="skip">', '</span>'],
+ first => ['<span class="first">', '</span>'],
+ limit => ['<span class="limit">', '</span>'],
+ offset => ['<span class="offset">', '</span>'],
},
indentmap => { %indents },
},