PowerBI-tips / TabularEditor-Scripts

Scripts for Tabular Editor 2 & 3. Community driven to make your Tabular Editor experience as fast as possible.
MIT License
164 stars 72 forks source link

Create MPartition #5

Closed elsdestickere closed 2 years ago

elsdestickere commented 3 years ago

Hi, i'm trying to create an M partition in Tabular editor. I'm stuck at changing the mode property. The help suggests to use a set, but I can't figure out how...

var newMpartition= "f_ha_birth_incrementalM"; var tableMpartition="births (facts)"; var partition= Model.Tables[tabelMpartition].AddMPartition(newMpartition); // I can select the import value var modePart= partition.Mode.Import; // but how do you update the mode? partition.Mode{set modePart;}

ArturNawrocki commented 3 years ago

Have you tried // " partition.Mode = "Import" "?

JamesDBartlett3 commented 2 years ago

@elsdestickere, did @ArturNawrocki's suggestion above solve your problem?

MikeCarlo commented 2 years ago

Closing issue because no final response.