Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a Field 'PartNumber'. I have separated 'PartNumber'' into 2 types. by Use code.
TEST:
load PartNumber,
if(WildMatch(if(IsNum(left(PartNumber',1)),mid(PartNumber',7,1)) ,'M','D'),PartNumber') as ONETYPE,
if(WildMatch(if(IsNum(left(PartNumber',1)),mid(PartNumber',7,1)) ,'A','B'),PartNumber') as TWOTYPE
where XXX;
But
I want to make a Listbox 'Type' where in the Listbox there are two values: ONETYPE and TWOTYPE
to select a category type.
Listboxes show values from one (1) field at a time, but here you are creating two fields. Try something like this:
TEST:
load *, if(len(ONETYPE)>0, 'ONETYPE', if(len(TWOTYPE)>0, 'TWOTYPE', 'unknown')) as Category
;
load PartNumber,
if(WildMatch(if(IsNum(left(PartNumber',1)),mid(PartNumber',7,1)) ,'M','D'),PartNumber) as ONETYPE,
if(WildMatch(if(IsNum(left(PartNumber',1)),mid(PartNumber',7,1)) ,'A','B'),PartNumber) as TWOTYPE,
...
;