Skip to content

GetRowsOptions Type Error for startIndex: Expects a string when it should expect a number #1350

@arjunmehta

Description

@arjunmehta

Environment details

  • OS: macOS 14.4.1
  • Node.js version: 20.11
  • npm version: 10.2.4
  • @google-cloud/bigquery version: 7.5.2

Steps to reproduce

  1. Try to pass startIndex as an integer option to getRows. eg.table.getRows({ startIndex: 31241 }).
  2. Observe typescript error. Expects a string when this should be a number.
  3. Passing a number in as "string" allows it to compile.

Expected behaviour

startIndex should work with an integer. As it is right now I need to convert the integer to a string eg. 31241.toString()

Relevant fixes in the code

startIndex?: string;

startIndex?: string;

Metadata

Metadata

Assignees

No one assigned

    Labels

    api: bigqueryIssues related to the googleapis/nodejs-bigquery API.priority: p3Desirable enhancement or fix. May not be included in next release.type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions