import re
query = "SELECT `asd`.`ssss` as `column1`, `ss`.`wwwwwww` from `table`"
table_and_columns = re.findall('`[^`\s]+`\.`[^`\s]+`',query)
print(table_and_columns)
aW1wb3J0IHJlCnF1ZXJ5ID0gIlNFTEVDVCBgYXNkYC5gc3Nzc2AgYXMgYGNvbHVtbjFgLCBgc3NgLmB3d3d3d3d3YCBmcm9tIGB0YWJsZWAiCnRhYmxlX2FuZF9jb2x1bW5zID0gcmUuZmluZGFsbCgnYFteYFxzXStgXC5gW15gXHNdK2AnLHF1ZXJ5KQpwcmludCh0YWJsZV9hbmRfY29sdW1ucyk=