pub package

A collection of sql views for Sqlite and Flutter using Sqlcool. Available views:

  • Admin view: full admin interface for add/edit/delete rows in a table
  • Infinite list view from a table

Crud admin view

List of rowsEdit row
Crud admin 1Crud admin 1

To get the above use an Sqlcool database with a defined schema:

   import 'package:sqlcool/sqlcool.dart';

   var table = DbTable("item")
      ..boolean("boolean", defaultValue: false)
      ..integer('integer_number', defaultValue: 1)
      ..real("double_number", defaultValue: 0)
      ..text("text", defaultValue: "");

   var db = Db();
   db.init("db.sqlite", schema = [table]);

Then use it in a widget:

   import 'package:flutter/material.dart';
   import 'package:sqlcool/sqlcool.dart';
   import 'package:sqlview/sqlview.dart';

   class _CrudPageState extends State<CrudPage> {
      SelectBloc bloc;

   void initState() {
      bloc = SelectBloc(database: db, table: "item");

   Widget build(BuildContext context) {
      return Scaffold(
         body: CrudView(bloc: bloc, nameField: "varchar"),
            CrudAddActionButton(db: db, schema: db.schema.table("item")),

   class CrudPage extends StatefulWidget {
      _CrudPageState createState() => _CrudPageState();

Infinite list view

      db: db,
      table: "product",
      orderBy: "name",
      itemsBuilder: (context, item) {
         return ListTile(
            title: Text(item['name']), trailing: Text(item["price"]));


  • Check table constraints and add validators for forms in CrudView