def get_names(view, sel):
    """ Return schema, name for object under cursor"""
    word = view.word(sel)
    schema = None
    if view.substr(word.begin() - 1) == '.':
        schema = view.substr(view.word(word.begin() - 2)).lower()
    return schema, view.substr(word).lower()