Skip to content

Instantly share code, notes, and snippets.

@anbudhanush
anbudhanush / php_unserialize_to_json.sql
Created January 30, 2019 11:00 — forked from storeman/php_unserialize_to_json.sql
PHP unserialize in Postgresql to json
/**
Decode a php serialized value to json. This function only supports basic
data types:
- arrays (will always become a json object)
- booleans
- integers
- floats
- strings
- NULL