import re
content = ("[\n"
" 1,\n"
" 2, \n"
" true\n"
" ]")
print(re.sub(r'(\[\n[ ]+\d+, ?\n[ ]+)\d+(, ?\n[ ]+(?:true|false)\n[ ]+\])', r'\1__table1.column__\2', content))
aW1wb3J0IHJlCgpjb250ZW50ID0gKCJbXG4iCgkiIDEsXG4iCgkiIDIsIFxuIgoJIiB0cnVlXG4iCgkiIF0iKQoKcHJpbnQocmUuc3ViKHInKFxbXG5bIF0rXGQrLCA/XG5bIF0rKVxkKygsID9cblsgXSsoPzp0cnVlfGZhbHNlKVxuWyBdK1xdKScsIHInXDFfX3RhYmxlMS5jb2x1bW5fX1wyJywgY29udGVudCkpCg==