Created
June 19, 2018 19:30
-
-
Save matrostik/3a3a28ee41aa6d012709a62cce9b3cca to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script runat=server> | |
Platform.Load("core","1.1.5"); | |
var prox = new Script.Util.WSProxy(); | |
var guid = Platform.Function.GUID(); | |
var name = "my test de - " + guid; | |
var de = { | |
Name: name, | |
CustomerKey: guid, | |
Description: "Another DE added via SSJS", | |
Fields: [{ | |
FieldType: "Text", | |
Name: "ID", | |
MaxLength: 36, | |
IsPrimaryKey: true, | |
IsNillable: false, | |
IsRequired: true | |
}, | |
{ | |
FieldType: "Text", | |
Name: "Name", | |
MaxLength: 200 | |
}], | |
CategoryID: 1909 | |
} | |
var res = prox.createItem("DataExtension", de); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment