mirror of
https://github.com/dimitri/pgloader.git
synced 2025-08-09 07:47:00 +02:00
Missing file from previous commit.
Somehow it still happens :/
This commit is contained in:
parent
973339abc8
commit
4e23de1b2b
17
src/parsers/command-including-like.lisp
Normal file
17
src/parsers/command-including-like.lisp
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
;;;
|
||||||
|
;;; MS SQL and SQLite style including/excluding rules, using LIKE
|
||||||
|
;;;
|
||||||
|
(in-package #:pgloader.parser)
|
||||||
|
|
||||||
|
(defrule like-expression (and "'" (+ (not "'")) "'")
|
||||||
|
(:lambda (le)
|
||||||
|
(bind (((_ like _) le)) (text like))))
|
||||||
|
|
||||||
|
(defrule another-like-expression (and comma like-expression)
|
||||||
|
(:lambda (source)
|
||||||
|
(bind (((_ like) source)) like)))
|
||||||
|
|
||||||
|
(defrule filter-list-like (and like-expression (* another-like-expression))
|
||||||
|
(:lambda (source)
|
||||||
|
(destructuring-bind (filter1 filters) source
|
||||||
|
(list* filter1 filters))))
|
Loading…
Reference in New Issue
Block a user