Skip to content

Feature request: implement queryRows to return array of rows #51

@ghuser

Description

@ghuser

Is your feature request related to a problem? Please describe.
It would be nice implementing queryRows, to do what queryRow does, but returning array of rows instead.
(I guess the implementation would be close to queryHash but instead of returning object to return array of objects)

Describe the solution you'd like

e.g.

connection.queryRows(
  'SELECT * FROM Language',
  (err, rows) => {
    console.dir({ queryRows: rows });
  }
);

Output:

queryRows: [
{
  LanguageId: 1,
  LanguageName: 'English',
  LanguageSign: 'en',
  LanguageISO: 'en',
  Caption: 'English'
},
...
{
  LanguageId: 3,
  LanguageName: 'Russian',
  LanguageSign: 'ru',
  LanguageISO: 'ru',
  Caption: 'Русский'
}
]

Describe alternatives you've considered

Additional context

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions