mirror of
https://github.com/dimitri/pgloader.git
synced 2026-05-04 18:36:12 +02:00
parent
c6271506ab
commit
cb9e01f4d9
@ -84,6 +84,14 @@ The provided transformation functions are:
|
||||
In: 100.0d0
|
||||
Out: "100.0"
|
||||
|
||||
- *hex-to-dec*
|
||||
|
||||
Converts a string containing an hexadecimal representation of a number
|
||||
into its decimal representation::
|
||||
|
||||
In: "deadbeef"
|
||||
Out: "3735928559"
|
||||
|
||||
- *set-to-enum-array*
|
||||
|
||||
Converts a string representing a MySQL SET into a PostgreSQL Array of
|
||||
|
||||
@ -374,7 +374,8 @@
|
||||
(null nil)
|
||||
(string (base64:base64-string-to-string string))))
|
||||
|
||||
(defun hex-to-dec (string)
|
||||
(etypecase hex
|
||||
(defun hex-to-dec (hex-string)
|
||||
(etypecase hex-string
|
||||
(null nil)
|
||||
(string (write-to-string (parse-integer hex :radix 16)))))
|
||||
(integer hex-string)
|
||||
(string (write-to-string (parse-integer hex-string :radix 16)))))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user