Modify ↓
#11708 closed defect (fixed)
[Patch] Unicode field names in SQLTable macro
Reported by: | Owned by: | Ryan J Ollos | |
---|---|---|---|
Priority: | normal | Component: | WikiTableMacro |
Severity: | normal | Keywords: | unicode |
Cc: | Trac Release: | 1.0 |
Description
Error occured when using non-ASCII text as field name (as table header). Values are ok.
Sample:
SELECT 'test' as '한글'
Patch file attached. (tested with r13683)
Attachments (1)
Change History (8)
Changed 11 years ago by
Attachment: | table.py.patch added |
---|
comment:1 Changed 11 years ago by
comment:2 Changed 11 years ago by
Thanks for the feedback. I'll apply a patch that uses get_column_names
.
comment:3 Changed 10 years ago by
Status: | new → accepted |
---|
comment:5 follow-up: 6 Changed 10 years ago by
comment:6 Changed 10 years ago by
Replying to theYT <dev@…>:
- Now Wiki text field displayed as one-line (
format_to_html
→format_to_oneliner
); I don't know which one would be better...
Thank you for reviewing and testing. It seems either format_to_html
or format_to_oneliner
might be preferred depending on the data being returned.
I made the change to oneliner to avoid the margins on the paragraph, however format_to_html
could be used with some CSS to remove the margins (similar to [14529]). Another option would be to support an argument for the WikiProcessor to specify paragraph or oneliner.
Note: See
TracTickets for help on using
tickets.
No.
to_unicode()
is not needed. We should use get_column_names() instead ofcursor.description
directly.