12%let root=%sysfunc(pathname(work))/dbml;
17 length cust_id 8 cust_name $20;
18 cust_id=1; cust_name=
'one'; output;
22 alter table mcdb.customers
23 add constraint pk_customers primary key (cust_id);
26filename dbmlref
"&root/model.dbml";
28%mp_getdbml(liblist=mcdb,outref=dbmlref)
35 infile dbmlref truncover end=last;
37 if index(_infile_,
'Table ') > 0 then call symputx(
'has_table',1,
'g');
38 if find(upcase(_infile_),
'CUSTOMERS') then call symputx('has_name',1,
'g');
39 if index(_infile_,'Project ') > 0 then call symputx('has_project',1,
'g');
43 iftrue=(&has_project=1),
44 desc=Checking that the dbml project header is written,
45 outds=work.test_results
49 iftrue=(&has_table=1),
50 desc=Checking that a table block is written for the library member,
51 outds=work.test_results
56 desc=Checking that the table name appears in the dbml,
57 outds=work.test_results