fixed regexp_matches and regexp_replace

when used in IS (NOT) NULL predicate
and provide error message when regex_matches arguments are of incorrect type
Merge pull request #1307 from crate/h/regex-hotfix

fixed regexp_matches and regexp_replace
correct alias handling.

we tried to resolve QualifiedNameReference by alias
everywhere but that is only valid in order by and group by.

this fixes:

    select name as n, substr(n, 1, 1)
    -> worked but shouldn't

    select name as n, n as foo
    -> both outputs where the value of "name"

    select tags, tags[1]
    -> tags[1] just used the value of tags ignoring the index access