This file contains 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 | |
emailAddress | |
from [dataExtension] | |
where createdDate > convert(date, getDate()-30) |
This file contains 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
const RtmClient = require('@slack/client').RtmClient; | |
const MemoryDataStore = require('@slack/client').MemoryDataStore; | |
const RTM_EVENTS = require('@slack/client').RTM_EVENTS; | |
const token = process.env.SLACK_TOKEN || ''; | |
const witAppId = process.env.WIT_APP_ID || ''; | |
const witToken = process.env.WIT_ACCESS_TOKEN || ''; | |
const {Wit, log} = require("node-wit"); | |
const wit = new Wit({accessToken: witToken}); |
This file contains 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
const RtmClient = require('@slack/client').RtmClient; | |
const MemoryDataStore = require('@slack/client').MemoryDataStore; | |
const RTM_EVENTS = require('@slack/client').RTM_EVENTS; | |
const token = process.env.SLACK_TOKEN || ''; | |
const rtm = new RtmClient(token, { | |
logLevel: 'error', | |
// logLevel: 'debug', | |
// Initialise a data store for our client, this will load additional helper functions for the storing and retrieval of data | |
dataStore: new MemoryDataStore(), |
This file contains 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
/* Client-specific Styles */ | |
#outlook a {padding:0;} /* Force Outlook to provide a "view in browser" message */ | |
.ReadMsgBody {width:100%;} .ExternalClass {width:100%;} /* Force Hotmail to display emails at full width */ | |
body{width:100% !important; max-width: 640px !important; -webkit-text-size-adjust:100%; -ms-text-size-adjust:100%; -webkit-font-smoothing: antialiased; margin: 0 auto; padding:0; background-color: #DFDDDB;} | |
/* Prevent Webkit and Windows Mobile platforms from changing default font sizes, while not breaking desktop design. */ | |
#backgroundTable {margin:0; padding:0; width:100% !important; line-height: 100% !important;} | |
img {outline:none; text-decoration:none;border:none; -ms-interpolation-mode: bicubic;} | |
a img {border:none;} | |
p {margin: 0px 0px !important;} |
This file contains 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
{'tree': {'ID': 1 , 'Label': 'A', 'childrenNodes': [ {'ID': 2, 'Label': 'B', 'childrenNodes': [ {'ID': 5, 'Label': 'E'}, {'ID': 6, 'Label': 'F'}, {'ID': 7, 'Label': 'G'} ]}, {'ID': 3, 'Label': 'C'}, {'ID': 4, 'Label': 'D', 'childrenNodes': [ {'ID': 8, 'Label': 'H'}, {'ID': 9, 'Label': 'I'} ]} ]} } |
This file contains 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 comments = document.querySelectorAll('#comment-list > li'); | |
var winners = {}; | |
getWinnerComment = function(id) { | |
return document.querySelectorAll('#' + id + ' .comment-content p')[0].textContent; | |
} | |
var iterations = 10000; | |
while(iterations--){ |
This file contains 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
return movieLists. | |
concatMap(function(category){ | |
debugger; | |
return category.videos.concatMap(function(video){ | |
debugger; | |
return video.boxarts.filter(function(box){ | |
//safe coercion | |
return box.width=='150' | |
}).map(function(box){ | |
debugger; |
This file contains 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<link rel="stylesheet" href="style.css"> | |
<script src="https://code.jquery.com/jquery-2.1.3.js"></script> | |
<script src="//cdnjs.cloudflare.com/ajax/libs/rxjs/2.3.25/rx.all.js"></script> | |
<script src="script.js"></script> | |
</head> |
This file contains 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
// Code goes here | |
window.onload = function() { | |
var Observable = Rx.Observable; | |
var textbox = document.getElementById('textbox'); | |
var keypresses = Observable.fromEvent(textbox, 'keypress'); | |
var results = document.getElementById('results'); | |
var searchButton = document.getElementById('searchButton'); | |
var searchButtonClicks = Observable.fromEvent(searchButton, 'click'); | |
function getWikipediaSearchResults(term) { |
This file contains 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
return movieLists.map( | |
// map receives 3 args | |
// cat - element to iterate | |
// cIndex - index in the array of the element | |
// cCollection - movieLists array | |
// same applies for the rest if the code | |
(cat, cIndex, cCollection) => { | |
//v for videos object | |
return cat.videos.map ( (v,vIndex,vCollection) => { |
NewerOlder