datav關聯關係展示

2021-06-20 15:19:49 字數 2323 閱讀 2315

1.資料中顯示擔保方與被擔保方之間的關係

表資料抽取

insert into t_correlation_item (name)  

(select distinct(a.name)

from

(select * from (select distinct(full_name_secured_party) as name

from major_event_external_guarantees_detail_******) b where b.name not in ( select name from t_correlation_item) ) a);

delete from t_correlation_item where name not like '%公司%'

and name not like '%醫院%'

and name not like '%廠%'

and name not like '%集團%'

and name not like '%銀行%'

and name not like '%局%'

and name not like '%所%'

and name not like '%土地%'

and name not like '%電%'

and name not like '%營體%'

and name not like '%中鐵%'

and name not like '%地產%'

and name not like '%中心%'

and name not like '%學校%'

and name not like '%研究%'

and name not like '%社%'

and name not like '%學院%'

and name not like '%酒店%'

and name not like '%處%'

select b.id,c.id, a.value from (select full_name_secured_party as target,full_name as source, count(*) as value from major_event_external_guarantees_detail_****** group by full_name_secured_party,full_name) a join t_correlation_item b on a.source = b.name join t_correlation_item c on a.target = c.name;

insert into t_correlation_rule (select b.id as source,c.id as target, a.value as value from (select full_name_secured_party as target,full_name as source, count(*) as value from major_event_external_guarantees_detail_****** group by full_name_secured_party,full_name) a join t_correlation_item b on a.source = b.name join t_correlation_item c on a.target = c.name);

select * from t_correlation_item where id in (select id from ((select source as id from t_correlation_rule order by value desc limit 100) union (select target as id from t_correlation_rule order by value desc limit 100) )b);

2. 資料格式

id,name,value

0,電腦硬體/台式整機/網路裝置,32

1,筆記本電腫11,

2,***/mp4/ipod/錄音窿25,

3,數位相機/攝像暿圖形沖印,20

source,target,value

0,9,14

0,29,13

1,34,11

其中第乙個value 可以控制球顏色大小,預設為1

第二個value表示邊的長度

0,9 表示第幾個item而不是id,從0開始計數

依賴關係 關聯關係

一 依賴關係 a物件作為b物件的區域性變數或是方法形參的,b依賴於a,這時候我們稱a與b之間存在一種依賴關係 給土豪打 物件作為形式引數 void calltuhaowithphone czphone phone void sendmessagetodiaosi 1 什麼是引數依賴 當a物件作為另外...

Elasticsearch關聯關係

elasticsearch父子關係 5.x參考 官網join介紹 es6.x一對多方案參考 注意 elasticsearch的關聯關係,必須要在同乙個索引裡面,而且父子關係必須在同乙個分片中。es6.x版本規定乙個索引中只能有乙個type,這就導致了,父子關係就必須放在同乙個type中。例子 本部落...

關聯關係和依賴關係

關聯 一種結構關係,表現為乙個物件能夠獲得另乙個物件的是類引用並呼叫他的服務。關聯 association 表示兩個類之間存在某種語義上的聯絡。例如,乙個人為一家公司工作,一家公司有許多辦公室。我們就認為人和公司 公司和辦公室之間存在某種語義上的聯絡。在分析設計的類圖模型中,則在對應人類和公司類 公...