Aha! It took me a bit of time to figure out what that was doing. That's tricky! :)

There are a few problems though: first, you don't use psycopg's securing features. It's bad practice to construct a string with user inputs and send it directly to postgres. Instead, you should build a string containing ``%s`` occurrences, and let psycopg replace them with secured data. Second, it's not easily readable and understandable. 

I would suggest that you write something like this: 
```python
query = 'SELECT backfill_%(backfill_type)s (%(params)s); '
func_params = BACKFILL_PARAMETERS[params.backfill_type]
func_params_str = ', '.join('%%(%s)s' % x for x in params)
sql_params = dict((x, params.get(x)) for x in params)
query = query % {'backfill_type': params.backfill_type, 'params': func_params_str}
return self.query(query, sql_params, error_message=error_message) 
```

That is quite ugly however so if you can come up with something better please do (and you will need to adapt it anyway). The main idea here is that your query end up looking like this: ``SELECT backfill_that_thing (%(param1)s, %(param2)s); ``

And then you let psycopg (in the ``self.query()`` function) do the securing and formatting of the SQL query.