mirror of
https://github.com/dimitri/pgloader.git
synced 2025-08-10 00:07:00 +02:00
Add support for MySQL geometry points.
The new version of the sakila database uses geometry typed columns that contain POINT data. Add support for that kind of data by copying what we did already for POINT datatype.
This commit is contained in:
parent
9e2b95d9b7
commit
8ec2ea04db
@ -135,6 +135,10 @@
|
|||||||
:using pgloader.transforms::set-to-enum-array)
|
:using pgloader.transforms::set-to-enum-array)
|
||||||
|
|
||||||
;; geometric data types, just POINT for now
|
;; geometric data types, just POINT for now
|
||||||
|
(:source (:type "geometry")
|
||||||
|
:target (:type "point")
|
||||||
|
:using pgloader.transforms::convert-mysql-point)
|
||||||
|
|
||||||
(:source (:type "point")
|
(:source (:type "point")
|
||||||
:target (:type "point")
|
:target (:type "point")
|
||||||
:using pgloader.transforms::convert-mysql-point))
|
:using pgloader.transforms::convert-mysql-point))
|
||||||
|
@ -398,8 +398,9 @@ order by table_name, ordinal_position"
|
|||||||
Mostly we just use the name, but in case of POINT we need to use
|
Mostly we just use the name, but in case of POINT we need to use
|
||||||
astext(name)."
|
astext(name)."
|
||||||
(case (intern (string-upcase type) "KEYWORD")
|
(case (intern (string-upcase type) "KEYWORD")
|
||||||
(:point (format nil "astext(`~a`) as `~a`" name name))
|
(:geometry (format nil "astext(`~a`) as `~a`" name name))
|
||||||
(t (format nil "`~a`" name))))
|
(:point (format nil "astext(`~a`) as `~a`" name name))
|
||||||
|
(t (format nil "`~a`" name))))
|
||||||
|
|
||||||
(defun get-column-list (dbname table-name)
|
(defun get-column-list (dbname table-name)
|
||||||
"Some MySQL datatypes have a meaningless default output representation, we
|
"Some MySQL datatypes have a meaningless default output representation, we
|
||||||
|
Loading…
Reference in New Issue
Block a user