in reply to What am I doing wrong with 'split'

Another approach is to use the power of Q... er, quotemeta to unmajick those pesky regex metacharacters.

>perl -wMstrict -le "my $s = '85|mat@com'; print qq{'$s'}; ;; my $sep = '|'; my ($key, $email) = split qq{\Q$sep\E}, $s; ;; print qq{key '$key' email '$email'}; " '85|mat@com' key '85' email 'mat@com'