Skip to content
This repository was archived by the owner on Aug 18, 2025. It is now read-only.
This repository was archived by the owner on Aug 18, 2025. It is now read-only.

The method 'offset' and 'limit' isn't defined for the type 'QueryBuilder' #116

@BodenTide

Description

@BodenTide

Steps to Reproduce

  • Remove the previous isar and isar_flutter_libs versions.
  • Run the following command
  • flutter pub add isar:^4.0.3 isar_flutter_libs:^4.0.3 --hosted-url=https://pub.isar-community.dev
  • added named schemas property to isar open object
  • Run flutter pub run build_runner build

Build runner ran successfully, but I get the following error on queries:

The method 'offset' isn't defined for the type 'QueryBuilder'. (Documentation) Try correcting the name to the name of an existing method, or defining a method named 'offset'.

`@collection
class ReadBookContent {
int? id;
/// md5
String? md5;

/// 大章节
int? chapter;

/// 小章节
int? smallChapter;

ReadBookContent();
}`

List<ReadBookContent> countReadBook = readBookContent.example.where().md5EqualTo(readBookBox.md5).offset(readBookBox.readIndex! - 1).limit(10).findAllSync();

Details

  • Dart version: [3.6.0]
  • Flutter version: [3.27.1]
  • Isar version: [4.0.3]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions