Skip to content

Instantly share code, notes, and snippets.

Created August 15, 2014 19:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/9759d2b07cde0e8984d9 to your computer and use it in GitHub Desktop.
Save anonymous/9759d2b07cde0e8984d9 to your computer and use it in GitHub Desktop.
__author__ = 'Fatih'
#-*- coding: utf-8 -*-
import peewee
from peewee import *
db = MySQLDatabase('crawler', user= 'sqlalchemy',passwd='mypassword')
class Newspaper(peewee.Model):
name = peewee.CharField()
title = peewee.CharField()
body = peewee.TextField()
link = peewee.CharField()
image = peewee.CharField()
class Meta:
database = db
Newspaper.create_table()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment