【发布时间】:2020-08-13 20:28:23
【问题描述】:
我正在使用 concat 函数将几个数据库字段转换为 Tkinter Combobox。
Data:
first_name last_name city state ID
John Smith Dallas TX 1
Richard Cunningham Ft. Worth TX 2
'''
SELECT concat (first_name,' ',last_name,' ', city,', ',state,' '),ID
'''
Results:
{'John Smith Dallas, TX':1, 'Richard Cunningham Ft. Worth, TX' :2 }
我想做的是格式化字符串,例如,Smith 将采用与 Cunningham 相同数量的字符。然后,当我将数据放入 cb 时,它会显示为列。
感谢您的帮助。
【问题讨论】:
标签: python