Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please make sqlite3.Row iterable #44966

Closed
philipdumont mannequin opened this issue May 17, 2007 · 3 comments
Closed

Please make sqlite3.Row iterable #44966

philipdumont mannequin opened this issue May 17, 2007 · 3 comments
Labels
extension-modules C modules in the Modules dir

Comments

@philipdumont
Copy link
Mannequin

philipdumont mannequin commented May 17, 2007

BPO 1720959
Files
  • sqlite.py: Failure when trying to iterate over a row
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = <Date 2007-05-20.16:26:13.000>
    created_at = <Date 2007-05-17.20:23:56.000>
    labels = ['extension-modules']
    title = 'Please make sqlite3.Row iterable'
    updated_at = <Date 2007-05-20.16:26:13.000>
    user = 'https://bugs.python.org/philipdumont'

    bugs.python.org fields:

    activity = <Date 2007-05-20.16:26:13.000>
    actor = 'ghaering'
    assignee = 'ghaering'
    closed = True
    closed_date = None
    closer = None
    components = ['Extension Modules']
    creation = <Date 2007-05-17.20:23:56.000>
    creator = 'philipdumont'
    dependencies = []
    files = ['2372']
    hgrepos = []
    issue_num = 1720959
    keywords = []
    message_count = 3.0
    messages = ['32034', '32035', '32036']
    nosy_count = 3.0
    nosy_names = ['nnorwitz', 'ghaering', 'philipdumont']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = None
    status = 'closed'
    superseder = None
    type = None
    url = 'https://bugs.python.org/issue1720959'
    versions = ['Python 2.5']

    @philipdumont
    Copy link
    Mannequin Author

    philipdumont mannequin commented May 17, 2007

    Sometimes I'd like to get row values with columnname
    indexes, sometimes by iterating over the row.

    The default (not setting the connection's row_factory)
    is to return a tuple, which gives the latter, but not
    the former.

    Setting row_factory to sqlite3.Row gives the former,
    but (surprisingly) not the latter.

    It's a surprise because back when pysqlite was not part
    of the Python distrib (I don't recall what version), its
    Row type was iterable. Any chance that bit of
    functionality could be put back?

    @philipdumont philipdumont mannequin closed this as completed May 17, 2007
    @philipdumont philipdumont mannequin assigned ghaering May 17, 2007
    @philipdumont philipdumont mannequin added the extension-modules C modules in the Modules dir label May 17, 2007
    @philipdumont philipdumont mannequin closed this as completed May 17, 2007
    @philipdumont philipdumont mannequin assigned ghaering May 17, 2007
    @philipdumont philipdumont mannequin added the extension-modules C modules in the Modules dir label May 17, 2007
    @nnorwitz
    Copy link
    Mannequin

    nnorwitz mannequin commented May 17, 2007

    Gerhard, could you take a look?

    @ghaering
    Copy link
    Mannequin

    ghaering mannequin commented May 20, 2007

    This functionality is already in the Python 2.6 branch. I was told not to backport it to 2.5.x. So, I'll close this issue.

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    extension-modules C modules in the Modules dir
    Projects
    None yet
    Development

    No branches or pull requests

    0 participants