Remove unit tests because most of our testing is in regression tests
anyway and regression tests are better integrated with the Postgres
extension workflow. sql/setup scripts were old and not used except
for unit testing.
Previously, an ALTER TABLE ADD COLUMN IF NOT EXISTS on a hypertable
caused an error if the column already did exist. The reversed problem
with DROP COLUMN is also fixed. Resolves issue #42.
Previously a query like `SELECT "1dim" FROM "1dim"` on a hypertable would
fail since the change_table_walker did not properly change the types on
whole row vars. That is now fixed.
Previously, an INSERT on a hypertable would always return
INSERT 0 0 as the command tag. This makes it return the proper
number of items inserted for the second number. Fixes#28.
This PR adds more regression tests for index creation and tests for more
user-errors. Significantly, it checks for the presence of both the time
and spaced-partition columns in unique indexes. This is needed because
Timescale cannot guarantee uniqueness if colliding rows don't land in the
same chunk. Fixes#29.
remove all murmur3-related source code. Alter regression tests
to reflect new hash values for inputs, and a slightly different
set of input data to ensure that sufficient chunks and partitions
are tested. Some changes to .sh scripts in sql/setup that seem
to be used only to power the "unit tests", which I cannot
yet run successfully.
This adds the .dir-locals.el Emacs style settings file from the
PostgreSQL source. This will make it easier for Emacs users to
conform to the official PostgreSQL coding style.
Remove sample data instructions and point to docs site
Approved-by: ci-timescale <erik@timescale.com>
Approved-by: Solar Olugebefola <solar@iobeam.com>
This commit adds an example how to run the Docker image so the
data is persisted between restarts based on our docker-run.sh
script. It also fixes a typo in the docker-run.sh script where
the default DATA_DIR was not correctly set.
The dblink extension is blacklisted by some cloud-hosting providers and
is an unnecessary dependency for single-node operation. Since we don't plan
to use dblink to implement clustering this PR removes the dependency.
Handle case where there is an additional constraint on time.
This makes the pathkeys for the IndexPath incompatible with
upper level ordering. Since we know the appropriate transform
for those pathkeys already, apply it to those paths too.
Common time-series rollups are of the form SELECT date_trunc(const,
time) as t, aggregates... GROUP BY t ORDER BY t DESC LIMIT const2.
Previously, Postgres would not optimize such queries because it
could not match date_trunc(const, time) to any indexes on time, since
it has no way to know that a sort on time is always a valid sort on
date_trunc(const, time).
This commit implements this optimization for date_trunc but it could
apply to a wider range of functions, to be implemented later.
Fix logic for when entire cache is invalidated
Approved-by: ci-vast
Approved-by: RobAtticus NA <rob.kiefer@gmail.com>
Approved-by: Olof Rensfelt <olof@iobeam.com>
Approved-by: Erik Nordström <erik.nordstrom@gmail.com>