【发布时间】:2025-11-25 18:15:02
【问题描述】:
我一辈子都搞不懂这个 Sqlite 语法。
我们的数据库包含以下记录:
TX, Austin OH, Columbus OH, Columbus TX, Austin OH, Cleveland OH, Dayton OH, Columbus TX, Dallas TX, Houston TX, Austin (State-field and a city-field.)
我需要这样的输出:
OH: Columbus, Cleveland, Dayton TX: Dallas, Houston, Austin (Each state listed once... and all the cities in that state... [edited: each listed once])
SELECT 语句是什么样的?
【问题讨论】: