Created
September 22, 2016 11:06
-
-
Save markgajdosik/009ba6fabccf3cf4dc76f7f01958f441 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cursor.execute(textwrap.dedent(''' | |
DROP TABLE IF EXISTS repeating; | |
CREATE TEMPORARY TABLE repeating ON COMMIT DROP | |
AS SELECT | |
{bat}.row, {cucm}.used_for, {bat}.field_id, {bat}.index | |
FROM {bat} INNER JOIN {cucm} ON | |
{cucm}.system_type = %s AND | |
{bat}.field_id = {cucm}.id | |
WHERE {bat}.row IN %s AND {cucm}.used_for IN %s {index} | |
''')) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment