Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: V$ views in CRON SQL*Plus script - shell thinks $xxx is a variable
Put a backslash '\' in front of the $ to escape it.
Alan Moorman wrote in message ...
>I'm trying to reference v$session in a cronned SQL*Plus script, but the
>shell (Korn) seems to think that the "$session" is a shell variable. I've
>tried enclosing the view name is quotes with same result.
>
>Suggestions? Thanks!!
>
>Here's the basic script:
>--------------
>sqlplus -s << END
>userid/password
>
>insert into stats
> (select username, status, logon_time, sysdate from "V$SESSION" where
>username
> like 'KPX%');
>
>END
>
>--------------
>
>
Received on Wed Nov 03 1999 - 10:42:56 CST