Entering initial data into django database

2016-03-20 Thread Lawrence Muriuki
Hi All, I have built a web scraper to scrape a website and get all match fixtures for a particular day. Wanted to know how to insert that initial data into django database and where that code should live..I have currently put the code in init.py but it looks and sounds wrong according to a quic

Re: Entering initial data into django database

2016-03-20 Thread Lawrence Muriuki
Thanks ludovic, here is my code for the scraper.. from .models import Betting import re import requests import urllib from bs4 import BeautifulSoup urls= "https://sms.betyetu.co.ke/tomorrow.html"; htmlfile = urllib.urlopen(urls) htmltext = htmlfile.read() soup = BeautifulSoup(htmltext, "h

Re: Entering initial data into django database

2016-03-20 Thread Lawrence Muriuki
unction to > transform the list into a fixture file and import the fixture file. > > 2016-03-20 20:02 GMT+01:00 Lawrence Muriuki >: > > > > Thanks ludovic, here is my code for the scraper.. > > > > > > > > > > > > from .models i