SQL 從客戶那邊選擇聯絡人的溝通記錄

2021-06-23 00:40:15 字數 373 閱讀 7182

表:溝通表有聯絡人的id做外來鍵,聯絡人有客戶id做外來鍵             1,不用左連線了?? 2,什麼情況下需要給兩張表建關聯表:當兩張表的主鍵是多對多的關係時必須建一張中間關聯表

--querycommunicatebycustomerid

select * from crm_communicate

where deleteflag <> 'y'

and  crm_communicate.contact_id in(select contact_id from crm_contact where customer_id =:customerid)

order by communicate_time desc

limit 0,5;

ContactsUI 選擇聯絡人 md

1 cncontactpickerviewcontroller 1.1 displaying contacts properties 1.2 notifying delegate 1.3 predicates for selecting contacts 2 實戰演練 2.1 源 2.2 效果圖 c...

SQL建立常用的客戶表及聯絡人表

參考 建立客戶表 create table cst customer cust id bigint 32 not null auto increment comment 客戶編號 主鍵 cust name varchar 32 not null comment 客戶名稱 公司名稱 cust sour...

Lync客戶端更新聯絡人通訊簿

lync客戶端更新聯絡人通訊簿 我的lync server 2013 環境介紹 內部網域名稱contoso.com,外部域為tiancang.net,兩個前端伺服器,fe01.contoso.com,fe02.contoso.com 兩個邊緣伺服器,edge01.contoso.com,edge02...