sql from tc

merge