2021年4月24日
摘要:
1. 删除数据库中以往的图,确保一个空白的环境进行操作: MATCH (n) DETACH DELETE n # 要想删除数据库的话直接删除文件即可 2. 创建一个人物节点: CREATE (n:Person {name:'John'}) RETURN n; CREATE (n:Person {na
阅读全文
posted @ 2021-04-24 15:34
打篮球的Curry
阅读(377)
推荐(0)
2021年4月10日
摘要:
首先我的数剧是这样的: 我想根据name1、relation和name2判断如果重复的话删除重复的数据且保留id最小的一条数据,于是写了下面的sql语句 DELETE FROM star_relation WHERE (name1,relation,name2)IN (SELECT name1, r
阅读全文
posted @ 2021-04-10 07:34
打篮球的Curry
阅读(328)
推荐(0)
2021年4月7日
摘要:
今天用Python爬取了明星关系,数据不多,一共1386条数据,代码如下: import requests from bs4 import BeautifulSoup import bs4 import csv def getHTMLText(url): try: kv = {'user-agent
阅读全文
posted @ 2021-04-07 10:00
打篮球的Curry
阅读(427)
推荐(0)
2021年3月12日
摘要:
MySql管理工具 Navicat for MySql的时候,弹出了一个1862 - MySql Your password has expired.To log in you must change it using a client that supports expired password解
阅读全文
posted @ 2021-03-12 19:12
打篮球的Curry
阅读(632)
推荐(0)
2021年1月6日
摘要:
步骤: 步骤1:建立工程和Spider模板 scrapy startproject BaiduStocks cd BaiduStocks scrapy genspider stocks baidu.com 进一步修改spiders/stocks.py 这一步自行完成~ 步骤2:编写Spider 配置
阅读全文
posted @ 2021-01-06 18:09
打篮球的Curry
阅读(594)
推荐(0)
2021年1月5日
摘要:
import requests from bs4 import BeautifulSoup import traceback import re def getHTMLText(url,code='utf-8'): try: r = requests.get(url,timeout=30) r.en
阅读全文
posted @ 2021-01-05 18:16
打篮球的Curry
阅读(238)
推荐(0)
摘要:
import requests import re def getHTMLText(url): try: kv = { 'cookie': '', #要换成自己网页的cookie 'user-agent':'Mozilla/5.0' # 请求头;指定访问浏览器为Mozilla5.0版本的浏览器 }
阅读全文
posted @ 2021-01-05 10:40
打篮球的Curry
阅读(321)
推荐(0)
2020年12月31日
摘要:
import requests from bs4 import BeautifulSoup import bs4 def getHTMLText(url): try: r = requests.get(url,timeout=30) r.raise_for_status() r.encoding =
阅读全文
posted @ 2020-12-31 10:43
打篮球的Curry
阅读(146)
推荐(0)
2020年12月30日
摘要:
import requests url = "http://m.ip138.com/sj.asp?mobile=" kv = {'user-agent':'Mozilla/5.0'} # 请求头 try: r = requests.get(url + '电话号码',headers=kv) print
阅读全文
posted @ 2020-12-30 21:12
打篮球的Curry
阅读(570)
推荐(0)
摘要:
import requests import os url = "https://ss0.baidu.com/7Po3dSag_xI4khGko9WTAnF6hhy/zhidao/pic/item/9c16fdfaaf51f3de9ba8ee1194eef01f3a2979a8.jpg" # 图片的
阅读全文
posted @ 2020-12-30 20:57
打篮球的Curry
阅读(264)
推荐(0)