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
// Desired unique index: | |
// db.collection.ensureIndex({ firstField: 1, secondField: 1 }, { unique: true}) | |
db.collection.aggregate([ | |
{ $group: { | |
_id: { firstField: "$firstField", secondField: "$secondField" }, | |
uniqueIds: { $addToSet: "$_id" }, | |
count: { $sum: 1 } | |
}}, | |
{ $match: { |
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
// | |
// Color+DAButton.swift | |
// | |
// Created by Jack Davis on 2/21/16. | |
// Copyright © 2016 Nine-42 LLC. All rights reserved. | |
// | |
import UIKit | |
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
// | |
// CGFloatExt.swift | |
// devslopes-app | |
// | |
// Created by Jack Davis on 2/21/16. | |
// Copyright © 2016 Devslopes. All rights reserved. | |
// | |
import UIKit |
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
// | |
// DATextField.swift | |
// devslopes-app | |
// | |
// Created by Jack Davis on 2/26/16. | |
// Copyright © 2016 Devslopes. All rights reserved. | |
// | |
import UIKit |
NewerOlder