I have a table that has a Character field that I am trying to insert a macro into:
The macros are
%let blending1 = INDIES15;
%let blending2 = SUPERCHAINS15;
%let blending3 = INDIES13;
%let blending4 = STORES14;
The table is
execute (create table ACCESS_DENSITY_ADV_NETWORK (ATTRIBUTE_ROW char(60), AVAILABLE_PHARMACIES integer,
NETWORK_PHARMACIES integer, BLENDING1 integer, BLENDING2 integer, BLENDING3 integer,BLENDING4 integer)) by odbc;
execute (insert into ACCESS_DENSITY_ADV_NETWORK
select "21: BLENDING1 &BLENDING1", 0, 0, 0 ,0 ,0 ,0) by odbc;
execute (insert into ACCESS_DENSITY_ADV_NETWORK
select "22: BLENDING2 &BLENDING2", 0, 0, 0 ,0 ,0 ,0) by odbc;
execute (insert into ACCESS_DENSITY_ADV_NETWORK
select "23: BLENDING3 &BLENDING3", 0, 0, 0 ,0 ,0 ,0) by odbc;
execute (insert into ACCESS_DENSITY_ADV_NETWORK
select "24: BLENDING4 &BLENDING4", 0, 0, 0 ,0 ,0 ,0) by odbc;
the macro will not resolve unless I put them in double quotes when I insert into the table, but if I do, it will not insert and gives me the following error
ERROR: CLI execute error: [NCR][Teradata RDBMS] Cannot resolve column '22: BLENDING2 SUPERCHAINS15'. Specify table or view.
Any suggestions will be appreciated
Michael
The macros are
%let blending1 = INDIES15;
%let blending2 = SUPERCHAINS15;
%let blending3 = INDIES13;
%let blending4 = STORES14;
The table is
execute (create table ACCESS_DENSITY_ADV_NETWORK (ATTRIBUTE_ROW char(60), AVAILABLE_PHARMACIES integer,
NETWORK_PHARMACIES integer, BLENDING1 integer, BLENDING2 integer, BLENDING3 integer,BLENDING4 integer)) by odbc;
execute (insert into ACCESS_DENSITY_ADV_NETWORK
select "21: BLENDING1 &BLENDING1", 0, 0, 0 ,0 ,0 ,0) by odbc;
execute (insert into ACCESS_DENSITY_ADV_NETWORK
select "22: BLENDING2 &BLENDING2", 0, 0, 0 ,0 ,0 ,0) by odbc;
execute (insert into ACCESS_DENSITY_ADV_NETWORK
select "23: BLENDING3 &BLENDING3", 0, 0, 0 ,0 ,0 ,0) by odbc;
execute (insert into ACCESS_DENSITY_ADV_NETWORK
select "24: BLENDING4 &BLENDING4", 0, 0, 0 ,0 ,0 ,0) by odbc;
the macro will not resolve unless I put them in double quotes when I insert into the table, but if I do, it will not insert and gives me the following error
ERROR: CLI execute error: [NCR][Teradata RDBMS] Cannot resolve column '22: BLENDING2 SUPERCHAINS15'. Specify table or view.
Any suggestions will be appreciated
Michael