execute immediate v_sql ;这一行报错引号内字符串没有正确结束

[复制链接]
查看11 | 回复9 | 2015-3-25 16:16:10 | 显示全部楼层 |阅读模式
create or replace procedure createtable
is
v_tablename varchar2(50);
v_columns varchar2(2000);
v_timestamp date;
v_sql varchar2(30000);
p_postfix varchar2(30000);
begin
v_timestamp := to_date('20150701','yyyymmdd');
v_columns :='eparchy_codeCHAR(4),
net_type_code VARCHAR2(2),
serial_number VARCHAR2(40),
bill_id
NUMBER(16) not null,
acct_id
NUMBER(16) not null,
user_id
NUMBER(16) not null,
partition_idNUMBER(4) not null,
cycle_id
NUMBER(6) not null,
integrate_item_code NUMBER(6) not null,
fee
NUMBER(11) default 0 not null,
balance
NUMBER(11) default 0 not null,
print_fee NUMBER(11) default 0 not null,
b_discnt
NUMBER(11) default 0 not null,
a_discnt
NUMBER(11) default 0 not null,
adjust_before NUMBER(11) default 0 not null,
adjust_afterNUMBER(11) default 0 not null,
late_fee
NUMBER(11) default 0 not null,
late_balanceNUMBER(11) default 0 not null,
latecal_dateDATE,
canpay_tag
CHAR(1) default ''1'' not null,
pay_tag
CHAR(1) default ''0'' not null,
version_no
NUMBER(4) default 1,
update_time DATE,
update_depart_idCHAR(5),
update_staff_id CHAR(8),
charge_id NUMBER(16),
writeoff_fee1 NUMBER(11),
writeoff_fee2 NUMBER(11),
writeoff_fee3 NUMBER(11),
drecv_fee2
NUMBER(11),
rsrv_fee1 NUMBER(11),
rsrv_fee2 NUMBER(11),
rsrv_fee3 NUMBER(11),
rsrv_info1
VARCHAR2(40),
rsrv_info2
VARCHAR2(40),
user_begin_date NUMBER(8),
user_end_date NUMBER(8),
acct_begin_date NUMBER(8),
acct_day
NUMBER(8),
no_tax_fee
NUMBER(11),
tax_fee
NUMBER(11),
tax_rate
NUMBER(5),
mix_item_id NUMBER(6),
no_tax_balanceNUMBER(11),
tax_balance NUMBER(11)';
p_postfix :='partition by range (PARTITION_ID)
(
partition PAR_TS_BH_BILL_1 values less than (100)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_2 values less than (200)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_3 values less than (300)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_4 values less than (400)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_5 values less than (500)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_6 values less than (600)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_7 values less than (700)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_8 values less than (800)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_9 values less than (900)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_10 values less than (1000)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_11 values less than (1100)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_12 values less than (1200)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_13 values less than (1300)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_14 values less than (1400)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_15 values less than (1500)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_16 values less than (1600)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_17 values less than (1700)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_18 values less than (1800)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_19 values less than (1900)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_20 values less than (2000)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_21 values less than (2100)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_22 values less than (2200)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_23 values less than (2300)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_24 values less than (2400)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_25 values less than (2500)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_26 values less than (2600)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_27 values less than (2700)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_28 values less than (2800)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_29 values less than (2900)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_30 values less than (3000)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_31 values less than (3100)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_32 values less than (3200)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_33 values less than (3300)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_34 values less than (3400)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_35 values less than (3500)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_36 values less than (3600)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_37 values less than (3700)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_38 values less than (3800)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_39 values less than (3900)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_40 values less than (4000)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_41 values less than (4100)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_42 values less than (4200)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_43 values less than (4300)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_44 values less than (4400)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_45 values less than (4500)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_46 values less than (4600)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_47 values less than (4700)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_48 values less than (4800)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_49 values less than (4900)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_50 values less than (5000)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_51 values less than (5100)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_52 values less than (5200)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_53 values less than (5300)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_54 values less than (5400)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_55 values less than (5500)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_56 values less than (5600)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_57 values less than (5700)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_58 values less than (5800)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_59 values less than (5900)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_60 values less than (6000)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_61 values less than (6100)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_62 values less than (6200)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_63 values less than (6300)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_64 values less than (6400)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_65 values less than (6500)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_66 values less than (6600)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_67 values less than (6700)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_68 values less than (6800)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_69 values less than (6900)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_70 values less than (7000)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_71 values less than (7100)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_72 values less than (7200)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_73 values less than (7300)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_74 values less than (7400)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_75 values less than (7500)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_76 values less than (7600)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_77 values less than (7700)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_78 values less than (7800)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_79 values less than (7900)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_80 values less than (8000)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_81 values less than (8100)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_82 values less than (8200)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_83 values less than (8300)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_84 values less than (8400)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_85 values less than (8500)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_86 values less than (8600)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_87 values less than (8700)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_88 values less than (8800)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_89 values less than (8900)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_90 values less than (9000)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_91 values less than (9100)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_92 values less than (9200)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_93 values less than (9300)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_94 values less than (9400)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_95 values less than (9500)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_96 values less than (9600)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_97 values less than (9700)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_98 values less than (9800)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_99 values less than (9900)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
),
partition PAR_TS_BH_BILL_100 values less than (MAXVALUE)
tablespace TBS_ACT_HDACT01
pctfree 10
initrans 10
maxtrans 255
storage
(
initial 8M
next 1M
minextents 1
maxextents unlimited
)
);'
;

for v1 in 1..2
loop

v_timestamp := add_months(v_timestamp,1);
v_tablename := 'ucr_act1.TS_BH_BILL_'|| substr(to_char(v_timestamp, 'YYYYMMDD'),1,6);

v_sql :='create table ' || v_tablename ||'('|| v_columns || ')'''||p_postfix||';';
execute immediate v_sql ;

end loop;
end createtable;


回复

使用道具 举报

千问 | 2015-3-25 16:16:10 | 显示全部楼层
求大神帮我看一下啊~实在找不到那里缺引号
回复

使用道具 举报

千问 | 2015-3-25 16:16:10 | 显示全部楼层
真长..... p_postfix这个后面不是已经有了 ';'
回复

使用道具 举报

千问 | 2015-3-25 16:16:10 | 显示全部楼层
iyee_tu 发表于 2015-5-20 13:41
真长..... p_postfix这个后面不是已经有了 ';'

那我是要去掉?
回复

使用道具 举报

千问 | 2015-3-25 16:16:10 | 显示全部楼层
cccccyyyyy1989 发表于 2015-5-20 13:44
那我是要去掉?

那你不会试一试?
回复

使用道具 举报

千问 | 2015-3-25 16:16:10 | 显示全部楼层
cccccyyyyy1989 发表于 2015-5-20 13:44
那我是要去掉?

dbms_output.put_line(v_sql); 打印出来看看 ....
回复

使用道具 举报

千问 | 2015-3-25 16:16:10 | 显示全部楼层
iyee_tu 发表于 2015-5-20 13:51
dbms_output.put_line(v_sql); 打印出来看看 ....

引号也多了一个哇
回复

使用道具 举报

千问 | 2015-3-25 16:16:10 | 显示全部楼层
iyee_tu 发表于 2015-5-20 14:01
引号也多了一个哇

我已经看花了。。在哪里


回复

使用道具 举报

千问 | 2015-3-25 16:16:10 | 显示全部楼层
.......||'('|| v_columns || ')'''||....... 这个右括号 后面不是有个引号。 你还是自己试试...
回复

使用道具 举报

千问 | 2015-3-25 16:16:10 | 显示全部楼层
Naldonado 发表于 2015-5-20 13:50
那你不会试一试?


大神
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行