SQL Wildcard replacement in JSON
===

Having a bit of trouble using a `REPLACE` statement in a pretty flooded table. An example table looks like the following:

	 {
		"ce8bf08f-e9b7-4283-b70a-c331055e7e60":  {
			"0":  {
				"value": "9\/16 x 3-1\/2"
			}
		},
		"7edd3ae1-7ce6-41d2-a88e-f5389fe2a4e4":  {
			"option":  {
				"0": "pine",
				"1": "primed"
			}
		},
		"c0794696-a5d2-4df9-b20f-f23b0f94a41b":  {
			"file": "images\/stories\/moldings\/molding-profiles\/thumb\/m-b1371.gif",
			"width": "41",
			"height": "137"
		},
		"246e955a-5a57-4ad0-ad8c-c15fc7bfccb6":  {
			"file": "images\/stories\/moldings\/molding-profiles\/full\/m-b1371.gif",
			"link": "",
			"target": "",
			"rel": "",
			"width": "82",
			"height": "274"
		},
		"95bdb077-091b-47f3-99ad-da6b42f6195b":  {
			"file": "M-B1371.dwg",
			"download_limit": "",
			"hits": "35",
			"size": "2350728"
		},
		"1e40d254-b751-46bd-9872-65248bbd343b":  {
			"file": "M-B1371.dxf",
			"download_limit": "",
			"hits": "42",
			"size": "5189493"
		},
		"32f5fb4b-19f5-46c0-9680-02c9ba3fd8e9":  {
			"file": "M-B1371.pdf",
			"download_limit": "",
			"hits": "40",
			"size": "140091"
		},
		"64c188a6-cf2f-4895-8879-8b67a58b6780":  {

		}
	}

What I'm ultimately trying to target/change are the `.dwg, .dxf and .pdf` file paths. So, my goal is to turn (for example):

`M-B1371.dxf`

into

`images\/stories\/moldings\/molding-profiles\/cad\/all\/M-B1371.dxf`

I've tried the following:

`update jos_zoo_item set elements = replace(elements, 'file": "%.dxf', 'file": "images\/stories\/moldings\/molding-profiles\/cad\/all\/%.dxf’);`

but that doesn't seem to be finding text correctly - does anyone have any suggestions here - a bit confused? Thanks! 