python scrapy框架通过pipelines批量存储数据到mysql数据库或者json文件
import sys
import MySQLdb
class CncompanyidSpiderFastPipeline(object):
companylist = []
def open_spider(self, spider):
self.conn = MySQLdb.connect(host="***", user="***", passwd=...
转载
2020-04-16 11:22:27 ·
598 阅读 ·
0 评论