diff --git a/docs/pages/docs/Using SQL/custom_queries.md b/docs/pages/docs/Using SQL/custom_queries.md index 5d6cbf55..8002bf51 100644 --- a/docs/pages/docs/Using SQL/custom_queries.md +++ b/docs/pages/docs/Using SQL/custom_queries.md @@ -83,7 +83,7 @@ Stream> categoriesWithCount() { // CategoryWithCount. As we defined the Category table earlier, drift knows how to parse // a category. The only thing left to do manually is extracting the amount return rows - .map((row) => CategoryWithCount(Category.fromData(row.data, this), row.readInt('amount'))) + .map((row) => CategoryWithCount(Category.fromData(row.data, this), row.read('amount'))) .toList(); }); } @@ -100,7 +100,7 @@ Stream amountOfTodosInCategory(int id) { 'SELECT COUNT(*) AS c FROM todos WHERE category = ?', variables: [Variable.withInt(id)], readsFrom: {todos}, - ).map((row) => row.readInt('c')).watch(); + ).map((row) => row.read('c')).watch(); } ```