On May 6, 2:23 pm, "A.T.Hofkamp" <[EMAIL PROTECTED]> wrote:
.... > Without a explicit Python value of what comes out of the sql query, I can only > guess. As example, assume the following data: > > f = { 1: ['Hostname', 'blabla', 'person', 'john'], > 2: ['MachineName', 'blabla', 'company', 'something']} > > ie a dictionary of column number to rows. > > Here you are only interested in the value part, and the code becomes. > > for v in f.itervalues(): > if v[0].startswith('Hostname'): > print v[3] Many thanks for all your replies - this last snippet of code helped me, extra thanks! kb. -- http://mail.python.org/mailman/listinfo/python-list