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
{ | |
"metadata": { | |
"name": "Get Max Date from a big STORET textf file." | |
}, | |
"nbformat": 3, | |
"nbformat_minor": 0, | |
"worksheets": [ | |
{ | |
"cells": [ | |
{ |
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 ST_Transform(ST_MPolyFromText( | |
'MULTIPOLYGON(((-82.4048638930815 27.5218423579402, | |
-82.5226783079082 27.5218423579402, | |
-82.5226783079082 28.4201576420597, | |
-82.4048638930815 28.4201576420597, | |
-82.4048638930815 27.5218423579402)))', 4326), 3857); |
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
#ddye@ubuntu:~# cd /usr/local/otm/ | |
#ddye@ubuntu:/usr/local/otm# source env/bin/activate | |
#(env)ddye@ubuntu:/usr/local/otm# cd app/opentreemap/ | |
#(env)ddye@ubuntu:/usr/local/otm/app/opentreemap# python manage.py shell | |
#Python 2.7.3 (default, Feb 27 2014, 19:58:35) | |
#[GCC 4.6.3] on linux2 | |
#Type "help", "copyright", "credits" or "license" for more information. | |
#(InteractiveConsole) | |
#>>> | |
from django.db import models |
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
MERGE table_a AS trg | |
USING table_b AS src | |
ON (trg.ID = src.ID) | |
WHEN MATCHED | |
THEN UPDATE SET trg.f1 = src.f1 |
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
--Search all stored procedures and views within current database for specific text. | |
SELECT [name] | |
FROM [dbo].[sysobjects] obj | |
INNER JOIN [dbo].[syscomments] cmt | |
ON obj.[id] = cmt.[id] | |
WHERE cmt.[text] like '%searchText%' |
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
{ | |
"metadata": { | |
"name": "step3" | |
}, | |
"nbformat": 3, | |
"nbformat_minor": 0, | |
"worksheets": [ | |
{ | |
"cells": [ | |
{ |
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
{ | |
"metadata": { | |
"name": "step0" | |
}, | |
"nbformat": 3, | |
"nbformat_minor": 0, | |
"worksheets": [ | |
{ | |
"cells": [ | |
{ |
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
{ | |
"metadata": { | |
"name": "" | |
}, | |
"nbformat": 3, | |
"nbformat_minor": 0, | |
"worksheets": [ | |
{ | |
"cells": [ | |
{ |
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
EXTERIOR: DAGOBAH -- DAY | |
With Yoda strapped to his back, Luke climbs up one ofthe many thick vines that grow in the swamp until hereaches the Dagobah statistics lab. | |
Panting heavily, hecontinues his exercises -- grepping, installing newpackages, logging in as root, and writing replacements fortwo-year-old shell scripts in Python. | |
YODA: Code! Yes. A programmer's strength flows from code maintainability. | |
But beware of Perl. Terse syntax... more than one way to do it... default variables. | |
The dark side of code maintainability are they. |
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
{ | |
"metadata": { | |
"name": "" | |
}, | |
"nbformat": 3, | |
"nbformat_minor": 0, | |
"worksheets": [ | |
{ | |
"cells": [ | |
{ |