어느 가을날의 전환점

TOAD|토드에서 대량 데이터 Insert 시 &에 대한 변수 값 입력 해제 방법 본문

Database/Oracle

TOAD|토드에서 대량 데이터 Insert 시 &에 대한 변수 값 입력 해제 방법

어느가을빛 2014. 10. 21. 10:36
  • Title

     
    No prompt for substitution variable. How do you enable/disable prompt for variable substitution?
  • Description

     

    When running a script in the editor, substitution variables may be used. But when it is executed, the user is not prompted for the variable value. How do you enter in a value?

    In some situations a user may want to enable/disable variable substitution in the SQL Editor depending on whether the ampersand (&) is used as a literal or bound variable when running a script (F5.)  In addition, a user may want to use the colon (:) as a bound variable when running a statement (F9.)

     

  • Cause

     

    If substitution variables are used and Toad is not prompting to enter in a value, the option may be disabled.

  • Resolution

     

    For TOAD for Oracle 8.5.3.2 or below:
    1. Go to View | Options.
    2. From the left panel, select SQL Editor | General.
    3. From right panel, check/ uncheck Scan statements for bound variables before execution.

    For TOAD for Oracle 8.6.0.38 and 8.6.1:
    1. Go to View | Options.
    2. From the left panel, select SQL Editor.
    3. From right panel, check/ uncheck Prompt for substitution variables.

    For TOAD for Oracle 9.7.2.5 and 10.1.1.8:
    1. Go to View | Toad Options.
    2. From the left panel, select Editor | Execute/ Compile.
    3. From right panel in the Behavior section, check to enabled and uncheck to disable “Prompt for substitution variables”.

    For TOAD 11.x:
    1. Go to View | Toad Options
    2. From the left panel, select Execute/ Compile
    3. Check appropriate check box under “Substitution Variable Prompting” section

     

  • Additional Information

     
    - Use F9 (Execute as Statement) to run the script. Using F5 (Execute as Script) will only return no rows selected. - Toggling the Prompt for Substitution Variables can be set in the Editor by right clicking to bring up the context menu and enabling or disabling the feature. - If the ampersand (&) is a literal and the option is unchecked, use SET DEFINE OFF when executing as a script.

# 출처: https://support.software.dell.com/toad-for-oracle/kb/11560

Comments