我有三個表:如何從映射表組中獲取計數是PostgreSQL中的另一個表?
store
=====
name
address
city
state
country
tag ...,
post
=======
title
summary
tags ...
store_post_map
================
(mapping on store and post based on tag).
現在我想通過city
,state
,country
或store.id
擺脫映射表組職位數,是什麼PostgreSQL中的SQL?
請用實際列名說明您的模式並聲明您的外鍵。 – 2013-02-14 09:19:50