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
| %%[ | |
| VAR @ProductName | |
| SET @ProductName = "Mobile phone" | |
| ]%% | |
| <script runat=server> | |
| Platform.Load("Core","1"); | |
| //Get the Variable from AMPscript |
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
| %%[ | |
| SET @status = DeleteData("DataExtension Name", "SubscriberKey","XXXXXXXXXX") | |
| ]%% | |
| Status: %%=v(@status)=%% |
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"); | |
| </script> | |
| <script runat=server> | |
| try{ | |
| </script> | |
| %%[ | |
| SET @SKey = RequestParameter("skey") |
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
| SELECT * FROM [Payment] | |
| WHERE DueDate BETWEEN DATEADD(DAY, -30, DATEADD(HOUR,5, GETDATE())) AND DATEADD(HOUR,5, GETDATE()) |
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"); | |
| var url = 'https://auth.exacttargetapis.com/v1/requestToken'; | |
| var contentType = 'application/json'; | |
| var payload = Stringify({ | |
| "clientId": "XXXXXXXXXXXXXXXXXXXXXXXXXX", | |
| "clientSecret": "XXXXXXXXXXXXXXXXXXXXXXXXXX" | |
| }); | |
| var headerNames = ["Encoding"]; | |
| var headerValues = ["utf-8"]; |
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
| SET @email = "[email protected]" | |
| SET @SKey = "123456" | |
| SET @First_Name = "Katy" | |
| SET @Last_Name = "Dorjee" | |
| SET @Phone = "987654321" | |
| SET @ts = CreateObject("TriggeredSend") | |
| SET @tsDef = CreateObject("TriggeredSendDefinition") | |
| SetObjectProperty(@tsDef, "CustomerKey", "XXXX") | |
| SetObjectProperty(@ts, "TriggeredSendDefinition", @tsDef) |
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
| %%[ | |
| VAR @SubscriberKey, @firstName, @lastName, @returnValue | |
| SET @SubscriberKey = "123" | |
| SET @firstName = "Karma" | |
| SET @lastName = "Dorjee" | |
| SET @returnValue = UpsertData("My_Test_DataExtension",1,"SubscriberKey",@SubscriberKey,"FirstName",@firstName,"LastName",@lastName) | |
| ]%% | |
| No of affected rows : %%=v(@returnValue)=%% |
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
| %%[ | |
| var @debug | |
| var @jid | |
| var @listid | |
| var @batchid | |
| var @email | |
| var @skey | |
| var @reason | |
| var @unsubscribeAll |
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
| select | |
| x.emailaddress | |
| , x.subscriberkey | |
| from ( | |
| select | |
| w.emailaddress | |
| , w.subscriberkey | |
| , w.insertDate | |
| , row_number() over (partition by w.subscriberkey order by w.insertDate asc) ranking | |
| from Welcome_Trigger w |
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.1"); | |
| var prox = new Script.Util.WSProxy(); | |
| /* | |
| //Child BU's MID | |
| var MID = 10000000000; | |
| //Switch context to different BU. Change the MID to suit. |