Using these instructions (there are several other examples to find, all look the same and all of them seem to work) http://www.gaia-gis.it/gaia-sins/spatialite-cookbook/html/sp-view.html "Hand-writing your own Spatial VIEW"
I wanted to create a Spatialite View within Qgis. I tried it with DB-Manager and the QspatiaLite Plugin. I get the following error:
views_geometry_columns.read_only may not be NULL
Any suggestions, I don't really know where I could have made a mistake, as it used to be very simple to create a spatialite view.
I used the following code:
CREATE VIEW shape_2015 AS
SELECT komplex_nr_polyg as kompx_nr,
flaeche as flaeche,
polygone as polygone
FROM flaechen
INSERT INTO views_geometry_columns
(view_name, view_geometry, view_rowid, f_table_name, f_geometry_column)
VALUES ('shape_2015', 'polygone', 'kompx_nr', 'flaechen', 'polygone');