in reply to Re^2: Find string match
in thread Find string match

Or maybe:
my $tablename = ($str=~/\binto\s+([^\s]+)/)[0];

Replies are listed 'Best First'.
Re^4: Find string match
by BrowserUk (Patriarch) on Feb 23, 2010 at 14:43 UTC

    Less obscure:

    $s = 'insert into table1 ( v1, v2 , v3) values ( v1, v2, v3)';; ( $tname ) = $s =~ m[into\s+(\S+)\s?\(]; print $tname;; table1

    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.