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
#!/usr/bin/env python | |
# encoding: utf-8 | |
import tweepy #https://github.com/tweepy/tweepy | |
import csv | |
#Twitter API credentials | |
consumer_key = "" | |
consumer_secret = "" | |
access_key = "" |
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
DECLARE @TableName nvarchar(128); | |
DECLARE @Command nvarchar(500); | |
DECLARE TableCursor CURSOR FOR | |
SELECT table_name FROM information_schema.tables | |
WHERE table_schema = 'myschema'; | |
OPEN TableCursor; | |
FETCH NEXT FROM TableCursor INTO @TableName; |
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
import pyodbc | |
import json | |
# Connect to your database - don't hardcode the creds! | |
conn = pydobc.connect(database="your_database", user="your_username", password="your_password", host="your_host", port="your_port") | |
cur = conn.cursor() | |
# List of your tables | |
tables = ["table1", "table2", "table3", "table4", "table5", "table6", "table7", "table8", "table9"] |