[Tutor] sqlite3 select extra characters

Alan Gauld alan.gauld at btinternet.com
Fri Jun 18 09:20:41 CEST 2010


"Lang Hurst" <lang at tharin.com> wrote

> Is there a way to just return the values when using sqlite3?

I don't think so, select returns a tuple of values, even if there is 
only one value.

> I get the list I want, but they look like
>
> (u'Cleese, John')

> is there a way to just return
>
> Cleese, John
>
> It seems a shame to have to run the answers through a stip process.

It's hardly a major effort to index the item?

print name[0]

instead of

print name

HTH,

-- 
Alan Gauld
Author of the Learn to Program web site
http://www.alan-g.me.uk/




More information about the Tutor mailing list