http://johnbutler.livejournal.com/ (
johnbutler.livejournal.com
) wrote
in
funeralcrasher
2006-09-20 03:25 am (UTC)
something like?
I gurgled this somewhere
SELECT id, COUNT(DISTINCT VARCHAR(RTRIM(LTRIM(elem)), 20)) FROM strings
maybe trim the length of the string minus 1?
In Python a string is an array, and you just ask for element 0. I'm guessing SQL does not make as much sense as Python.
I'm sure I'm wrong, but maybe you'll find something serendiculous.
(
2 comments
)
Post a comment in response:
From:
Anonymous
This account has disabled anonymous posting.
OpenID
Identity URL:
Log in?
Dreamwidth account
Account name
Password
Log in?
If you don't have an account you can
create one now
.
Subject
HTML doesn't work in the subject.
Formatting type
Casual HTML
Markdown
Raw HTML
Rich Text Editor
Message
[
Home
|
Post Entry
|
Log in
|
Search
|
Browse Options
|
Site Map
]
something like?
SELECT id, COUNT(DISTINCT VARCHAR(RTRIM(LTRIM(elem)), 20)) FROM strings
maybe trim the length of the string minus 1?
In Python a string is an array, and you just ask for element 0. I'm guessing SQL does not make as much sense as Python.
I'm sure I'm wrong, but maybe you'll find something serendiculous.