This commit is contained in:
2023-04-21 16:07:17 +08:00
parent 22c11ea8cd
commit 832450a795
@@ -2,6 +2,7 @@ package com.fangjia.script.gj.crawl
import com.fangjia.core.RegionData
import com.fangjia.core.util.DataUtil
import com.fangjia.script.commData.CommonDatautils
import com.fangjia.script.looplineinfo.InsidePolygon
import com.fangjia.script.looplineinfo.Point
import com.fangjia.script.util.CosineSimilarAlgorithm
@@ -26,7 +27,11 @@ class OfficeProcess {
"goojia", "goojia123456", "ru.yandex.clickhouse.ClickHouseDriver")
static main(args) {
def filePath = "D:\\数据\\写字楼\\6城未匹配上的写字楼.xlsx"
def filePath = "/home/goojia/gj/6城未匹配上的写字楼.xlsx"
if(CommonDatautils.isWindow()){
filePath = "D:\\数据\\写字楼\\6城未匹配上的写字楼.xlsx"
}
def task = new OfficeProcess();
// task.run("D:\\数据\\写字楼\\6城合并写字楼.xlsx")
@@ -38,10 +43,10 @@ class OfficeProcess {
// task.nameFiter(filePath)
// task.typeFiter(filePath)
// task.nameFlag(filePath)
//// task.updateFlagToDB(filePath)
task.updateFlagToDB(filePath)
// task.updateFlagToDB2(filePath)
task.checkRegion()
// task.checkRegion()
}
@@ -452,12 +457,8 @@ class OfficeProcess {
pstmt.setString(5, d['D'])
println count+" "+d['L']+" "+d['K']+" "+d['B']+" "+d['C']+" "+d['D']
pstmt.addBatch()
if(count % 100 ==0) {
try {
pstmt.executeBatch()
} catch (Exception e) {
}
if(count % 10 ==0) {
pstmt.executeBatch()
}
}
}