Last active
August 29, 2015 14:06
-
-
Save cupen/701adfa44f58ae25c506 to your computer and use it in GitHub Desktop.
Revisions
-
咚咔 revised this gist
Sep 19, 2014 . 1 changed file with 2 additions and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -10,7 +10,8 @@ SELECT t2.i as idx2 FROM test as t1 LEFT JOIN test as t2 ON (t1.i - t2.i) = 1 WHERE ISNULL(t2.i); -
咚咔 revised this gist
Sep 19, 2014 . 1 changed file with 4 additions and 5 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -6,14 +6,13 @@ DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci SELECT t1.i as idx1, t2.i as idx2 FROM test as t1 LEFT JOIN test as t2 ON (t1.i - t2.i) = 1 WHERE ISNULL(t2.i); -
咚咔 created this gist
Sep 19, 2014 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,19 @@ CREATE TABLE `test` ( `i` int(255) NULL DEFAULT 0 ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8 COLLATE=utf8_general_ci SELECT t1.i as idx1, t2.i as idx2 FROM test as t1 LEFT JOIN test as t2 ON (t1.i - t2.i) = 1 WHERE ISNULL(t2.i);