Example #1
0
        protected override void ReadCore(DateTime t1, DateTime t2)
        {
            SQLiteServer svr = new SQLiteServer(fileName);

            Clear();

            string sql = "SELECT * from " + svr.PortableTableName(this.Table.TableName);

            if (t1 != MinDateTime || t2 != MaxDateTime)
            {
                sql += " WHERE datetime >= " + svr.PortableDateString(t1, TimeSeriesDatabase.dateTimeFormat)
                       + " AND "
                       + " datetime <= " + svr.PortableDateString(t2, TimeSeriesDatabase.dateTimeFormat);
            }
            sql += " order by datetime ";


            svr.FillTable(this.Table, sql);
        }