Use different source table
This is a total rewrite to use a different source table, plus a bunch of updates to the UDF based on testing. I've tested it on my own personal hive db and it seems to work well, though it takes ~2hrs to run the update script (working on that now in a separate branch)