开发者

is it possible to get Oracle SQL Developer to escape output when exporting as inserts?

开发者 https://www.devze.com 2023-03-10 06:38 出处:网络
Is it possible, and if so, how, to tell Oracle SQL Developer to escape single quotes whenn exporting a table to inserts? It seems like an obvious thing to want to do, esc开发者_运维问答ape the charact

Is it possible, and if so, how, to tell Oracle SQL Developer to escape single quotes whenn exporting a table to inserts? It seems like an obvious thing to want to do, esc开发者_运维问答ape the character being used to quote fields when it occurs within the field, but I cannot find the option to do it.

Update: version 2.1.1.64, export method is. Context menu>export data>insert...


I just tried it using SQL Developer 3.0.04, and it appears that the single quotes in data are escaped by default:

--------------------------------------------------------
--  File created - Wednesday-June-01-2011   
--------------------------------------------------------
--------------------------------------------------------
--  DDL for Table T3
--------------------------------------------------------

  CREATE TABLE "THEUSER"."T3" 
   ("C1" VARCHAR2(20 BYTE), 
    "C2" VARCHAR2(20 BYTE)
   ) SEGMENT CREATION IMMEDIATE 
     PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING
     STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
     PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 
     BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
  TABLESPACE "USERS" ;
REM INSERTING into THEUSER.T3
Insert into THEUSER.T3 (C1,C2) values ('C1','C''2');

I just had one row in the table, consisting of the values C1 and C'2.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号