Javier Goizueta
f785e71d3b
Fix: numeric is a valid numeric column type
...
Actually this is the type of aggregated _vovw_count columns
2016-04-14 15:46:03 +02:00
Carla
14b8cd7d99
Set default value to 1 and remove typo line
2016-04-14 12:12:17 +02:00
Carla
1a571c8a9c
Set tolerance to 1 pixel
2016-04-14 11:13:59 +02:00
Carla Iriberri
8f44f5347a
Fix indent for code clarity
2016-04-13 17:51:30 +02:00
Carla Iriberri
f96163265b
Fix bug for tables without geom or with no potential overviews
...
If the table doesn't have geometries but the createoverviews function is
called, the current geometry type checks won't work because "null" will
not give a boolean value in the type comparisons.
Also, if the createoverviews function is called over a simple table with
would not require overviews according to the strategies it is handled
correctly.
2016-04-13 17:49:38 +02:00
Javier Goizueta
1c67214b09
Use cell centers, not cluster centroids when grouping points
...
Fixes #225
2016-04-13 11:14:09 +02:00
Carla Iriberri
16d08ef52b
Include and aggregate _vovw_count column to count aggregated features
2016-04-12 11:10:55 +02:00
Javier Goizueta
15ac9a2cd9
Remove unneeded code
2016-04-07 10:30:10 +02:00
Javier Goizueta
ee61d46100
💄 rename variable for clarity
2016-04-07 10:24:02 +02:00
Javier Goizueta
49e7094c8a
Make CDB_CreateOverview usable by superuser
...
CDB_CreateOverview had to be executed with the user role
corresponding to the owner of the table; now it can be executed
by the postgres user.
2016-04-07 07:52:58 +02:00
Javier Goizueta
fb910be12f
Fix conversion of regclass to indentifier
2016-04-07 07:07:20 +02:00
Javier Goizueta
34c39662ec
Replace use of CDB_UserTables in CDB_Overviews
...
Use a function that returns reclasses and schema names properly instead.
2016-04-07 00:07:45 +02:00
Javier Goizueta
84cac16d1c
Temporary fix
2016-04-06 22:05:00 +02:00
Javier Goizueta
c1fc07d2ac
Fix typo
...
This function isn't beint actively used; should consider removing it
or testing it properly
2016-04-06 18:58:37 +02:00
Javier Goizueta
5c3c0f5fc9
Fix bug in CDB_DropOverviews
...
Fixes #223
2016-04-06 18:57:52 +02:00
Javier Goizueta
06bb669d4c
Add comment
...
Clarify the reason why some functions are dropped at the
end of the file and not where their new definitions are.
2016-04-05 13:22:07 +02:00
Javier Goizueta
00a3d6e650
Fix upgrades from prior versions
2016-04-05 13:10:00 +02:00
Javier Goizueta
f0ff197c56
Merge branch 'master' into 219-overviews-tolerance
...
# Conflicts:
# scripts-available/CDB_Overviews.sql
# test/CDB_OverviewsTest_expect
2016-04-05 13:08:22 +02:00
Javier Goizueta
57c32332e2
New function CDB_CreateOverviewsWithToleranceInPixels
...
This function allows defining the previously fixed parameter grid_px.
The lim parameter used to define the reference Z level is also
correlated to this value.
Fixes #219
2016-04-04 19:21:10 +02:00
Javier Goizueta
3c71eecbae
Fix cases that require explicit schema name
...
This allows using overview functions in situations where
the base tables require being qualified with the schema name.
2016-04-04 17:45:20 +02:00
Javier Goizueta
c0262a05eb
Fix CDB_Overviews for cases that require explicit schema name
...
Fixes #218
2016-04-04 17:02:59 +02:00
Javier Goizueta
4074173c05
Add support for boolean columns in overview creation
2016-03-21 12:58:29 +01:00
Carla
90fa45b59d
Remove casting to bigint
2016-03-16 11:03:46 +01:00
Carla
16cf70bb4a
Merge pull request #202 from CartoDB/cartodbfication_cartodb_id_text
...
Add support to detect string cartodb_id columns
2016-03-15 10:49:22 +01:00
Carla
0b8bada553
Remove unused variable
2016-03-09 11:54:59 +01:00
Carla Iriberri
7b48c2765e
Fix error detection and fix tests
2016-03-08 14:06:58 +01:00
Carla Iriberri
d495bd45ba
Merge branch 'cartodbfication_cartodb_id_text' of https://github.com/CartoDB/cartodb-postgresql into cartodbfication_cartodb_id_text
2016-03-08 11:59:00 +01:00
Carla Iriberri
f4b51807a1
Make cartodb_id inconsistencies fail and update tests
2016-03-08 11:58:30 +01:00
Carla
5bc725c8ab
Add drop function if exists
2016-03-03 16:58:31 +01:00
Carla Iriberri
76a2cb9132
Improve exception error message
2016-03-02 17:36:45 +01:00
Alejandro Martínez
90c16fdb13
Fully qualify invalidations
2016-03-02 16:22:22 +01:00
Carla Iriberri
a18cbeb2cd
Third iteration, expect a viable cartodb_id
2016-03-02 14:58:53 +01:00
Carla Iriberri
0d5f83b3c4
Rewriting function
2016-03-01 19:17:45 +01:00
Carla Iriberri
1198454046
Better exception handling
2016-03-01 17:43:21 +01:00
Carla Iriberri
32307ceef0
Add support to detect string cartodb_id columns
2016-03-01 15:24:40 +01:00
Rafa de la Torre
a0fe55bd5d
Add a small bit of func doc about the quoting
2016-02-12 11:27:28 +01:00
Alejandro Martínez
56fed12392
Add CDB_TableMetadata_Text view as a proxy to access FDW tablemetadata
2016-02-11 19:16:00 +01:00
Rafa de la Torre
2f26b44142
tDo not quote dbname identifier
...
Turns out that for caching it is our standard not to have the dbname
quoted.
2016-02-11 16:10:27 +01:00
Rafa de la Torre
06036e2fe8
Quote identifiers returned by CDB_QueryTables_Updated_At
2016-02-10 18:58:01 +01:00
Rafa de la Torre
cd4ad29e39
Remove schema when selecting from CDB_TableMetadata
...
to ease testing. When creating CDB_TableMetadata it is always put in
cartodb when done from the extension, but for tests it is done in
public.
2016-02-09 18:49:20 +01:00
Rafa de la Torre
d59b826d37
Fix silly bug: ordering of functions
2016-02-09 17:11:16 +01:00
Rafa de la Torre
1c637f8689
Small fixes: qualify cartodb function calls
2016-02-09 16:38:11 +01:00
Rafa de la Torre
ecbdb4a430
Move fdw-aware functions to CDB_ForeignTable.sql
2016-02-09 13:40:18 +01:00
Rafa de la Torre
eb84dd04c9
Add func CDB_Last_Updated_Time
2016-02-09 13:30:00 +01:00
Rafa de la Torre
276b5cf9ea
Rename func to CDB_QueryTables_Updated_At
...
s/CDB_QueryTablesUpdatedAt/CDB_QueryTables_Updated_At and also add a bit
more inline doc.
2016-02-09 13:29:10 +01:00
Rafa de la Torre
ec34b8ee28
Minor changes: use plain SQL func
2016-02-08 19:29:14 +01:00
Rafa de la Torre
0f21db51b6
Simplify the code and get the updated_at
2016-02-08 19:29:14 +01:00
Rafa de la Torre
a074f4df5d
Adapt CDB_QueryTablesUpdatedAt to _cdb_fqtn_from_text
2016-02-08 19:29:14 +01:00
Rafa de la Torre
1a12fd3b69
Make _cdb_fqtn_from_text return a table
...
with type instead of a record
2016-02-08 19:29:14 +01:00
Rafa de la Torre
78a75cf22d
Implementation of _cdb_fqtn_from_text (WIP)
2016-02-08 19:29:14 +01:00
Rafa de la Torre
1e3c7ace99
Implementation of _cdb_dbname_of_foreign_table (WIP)
2016-02-08 19:29:14 +01:00
Rafa de la Torre
c210008184
Skeleton of a possible solution (WIP)
2016-02-08 19:29:14 +01:00
Rafa de la Torre
0c43fe2731
Define API of CDB_QueryTablesUpdatedAt
2016-02-08 19:29:14 +01:00
Alejandro Martínez
edf79d9368
Add remote cdb_tablemetadata manually from public schema
2016-02-08 15:45:58 +01:00
Rafa de la Torre
8dedd2b3f4
Fix small typos: s/name/fdw_name/
2016-02-05 13:15:20 +01:00
Rafa de la Torre
11834dfdab
Fix typo: missing semicolon
2016-02-05 10:44:55 +01:00
Alejandro Martínez
b957635e78
Add CDB_Get_Foreign_Updated_At function
2016-02-04 18:26:43 +01:00
Alejandro Martínez
a9b9f1ff6c
Rename CDB_FDW_Create to CDB_FDW_Setup, formatting fixes
2016-02-04 12:06:22 +01:00
Alejandro Martínez
d7b560324a
Add _Create_FDW function to create a FDW defined on the config by name
2016-02-03 18:07:23 +01:00
Alejandro Martínez
7b52058265
Add CDB_ForeignTable functions
2016-02-03 17:50:13 +01:00
Javier Goizueta
5285943dbf
Fix function declaration for create_from_unpackaged.sh use
...
The script create_from_unpackaged.sh does not support
function declarations where the signature (name and parameter list
of the function, including parentheses) is not on a single line.
2016-02-01 18:56:55 +01:00
Javier Goizueta
06dd31f4ad
Fix: should be floating point divistion, not integer division
2016-01-29 16:51:52 +01:00
Javier Goizueta
6a11698a16
Merge branch 'overviews' into sql_lang
2016-01-29 16:29:23 +01:00
Javier Goizueta
00bd302f01
Avoid creating GridCluster overviews for non-point datasets
2016-01-29 16:19:35 +01:00
Javier Goizueta
93d4a6ead0
Restrict SECURITY DEFINER to overview registration
...
And check it is applied only overview tables with valid names
2016-01-28 17:04:06 +01:00
Javier Goizueta
66387c2d44
Make CDB_CreateOverviews a SECURITY DEFINER function
...
So that it can change the permissions of overview tables
(by updating pg_class) even when executed by non-priviledeged users.
2016-01-28 16:32:40 +01:00
Javier Goizueta
26c95347cd
Merge branch 'master' into overviews
2016-01-27 16:56:15 +01:00
Javier Goizueta
b8d50204dd
Avoid aggregation which causes out-of-memory crashes in PostgreSQL
...
The use of multiple string_agg functions, even if applied to groups
of one single record causes out of memory crashes in PG 9.3.4 for
some (large) tables.
2016-01-27 15:24:04 +01:00
Javier Goizueta
474de01757
Change the overview table naming scheme
...
The scheme is changed from table_ovN to _vovw_N_table for
lower collision probability.
Also future naming changes will be easier by using the functions
_CDB_OverviewTableDiscriminator, _CDB_OverviewTableName,
_CDB_IsOverviewTableOf, etc.
2016-01-26 13:20:28 +01:00
Javier Goizueta
1ebaeb76ac
Overload CDB_Overviews to accept either a single table or an array
...
The result of CDB_Overviews has been expandend with a base_table column
2016-01-26 10:39:26 +01:00
Javier Goizueta
7033a8d9ac
Fixes for table names that require quotes or which include a schema name
...
Some cases left unsolved, with FIXME comments
2016-01-13 18:49:27 +01:00
Javier Goizueta
46bc774d38
Fix CDB_Overviews for the case that the table name requires quoting
2016-01-13 18:24:06 +01:00
Javier Goizueta
a9e2d19918
Document CDB_DropOverviews
2016-01-12 16:20:11 +01:00
Javier Goizueta
5b47c51221
Add function to drop overviews
2016-01-12 15:35:50 +01:00
Javier Goizueta
ccdf8de59e
Enhance documentation, update comments
2016-01-12 12:08:41 +01:00
Javier Goizueta
02f386be33
Regard the GridCluster reduction strategy as private
...
The *strategy* parameteriation will be considered an
implementation detail for the time being.
2016-01-12 11:59:42 +01:00
Javier Goizueta
a7c70fe497
Fix: CDB_ZoomFromScale deviation for lowest zoom levels
2016-01-12 11:46:47 +01:00
Javier Goizueta
0a066e0126
Change the default overview reduction strategy to GridCluster
2016-01-11 15:35:04 +01:00
Javier Goizueta
913640e2dc
Preserve the column ordering of the base table in overviews
2016-01-11 15:34:10 +01:00
Javier Goizueta
ef7e613d41
Change CDB_ColumnNames to order columns names as in table
2016-01-11 15:28:27 +01:00
Javier Goizueta
fd7a8cff71
Change regular expression for consistency
2016-01-11 15:27:05 +01:00
Javier Goizueta
6ea63af974
Add function to obtain existing overviews of a table
2016-01-11 14:50:10 +01:00
Javier Goizueta
496f079b1c
Copy dataset privileges to overview tables
2016-01-04 18:06:56 +01:00
Javier Goizueta
4580c9cd5c
Change the cartodb_ids of aggregated overviews
...
Instead of arbitrary ids, the id of one of the aggregated records
is used, so that if it is used in the UI to query point
the information of one of the records grouped at the point will be
retrieved.
2016-01-04 10:33:39 +01:00
Javier Goizueta
08828b8b7d
Set owner of overlays to the owner of the base table
2015-12-29 15:22:12 +01:00
Javier Goizueta
cecba655eb
Preserve aggregated attributes of singleton groups
2015-12-29 14:56:47 +01:00
Javier Goizueta
b34a752172
Generate overviews for all Z levels
...
Skipping levels produces visually inferior results
2015-12-29 14:56:04 +01:00
Javier Goizueta
8ba9e74c4a
Order columns of aggregated overlays as in the base table
2015-12-29 13:38:07 +01:00
Javier Goizueta
6a6a5bc96a
Fix Sampling reduction to avoid RandomTids problems
...
The fixed cases will not be common but do occur in tests.
This is an interim fix which should be reverted if CDB_randomTids changes.
2015-12-28 19:41:14 +01:00
Javier Goizueta
2ff686de27
Clean up: remove spurious comment
2015-12-28 19:30:20 +01:00
Javier Goizueta
07326626b7
More efficient sampling strategy
...
It is also renamed properly.
2015-12-28 19:28:20 +01:00
Javier Goizueta
4afc427008
Rename Ref. Z strategy function
...
It's not that *dummy* anymore, so choose a more descriptive name
2015-12-28 17:47:57 +01:00
Alejandro Martínez
2a2a7d534a
Merge remote-tracking branch 'origin/master' into remove_schema_triggers
2015-12-23 17:09:41 +01:00
Javier Goizueta
a8a2c04d71
Remove invalid comment
2015-12-23 14:20:57 +01:00
Javier Goizueta
a5bca7d715
Add function for post-processing new overview tables
2015-12-23 14:17:50 +01:00
Javier Goizueta
552206464e
Make strategy function public
2015-12-23 12:50:04 +01:00
Javier Goizueta
2af0b9a57f
Add function comments
2015-12-23 12:42:40 +01:00
Javier Goizueta
1b5de84c9a
Add missing attribute-aggregationto the point reduction strategy
2015-12-23 12:17:37 +01:00
Javier Goizueta
5a78ee2896
Optimize the gridded clustering strategy
...
The internal grid_px parameter is adjusted for best results with default symbol size
2015-12-22 17:59:49 +01:00
Javier Goizueta
c8a1ef6f68
Slight optimization of gridded clustering
2015-12-22 15:25:21 +01:00
Paul Norman
ea7c16fbaf
Convert some simple functions from plpgsql to sql
...
SQL is a faster language to call, and these are very simple functions.
2015-12-21 23:59:26 -08:00
Rafa de la Torre
564ab75d2d
Use _cdb_estimated_extent instead of ST_Extent
...
With a 3.8M points table, this was a ~30% gain in my local env.
2015-12-21 18:41:50 +01:00
Rafa de la Torre
5010109c7d
Add _cdb_estimated_extent to get the extent from stats
2015-12-21 18:41:45 +01:00
Rafa de la Torre
e60f73a31b
A bit of internal documentation
2015-12-21 13:16:57 +01:00
Javier Goizueta
415a09392f
Gridded clustering aggregation strategy for overviews
2015-12-16 17:45:36 +01:00
Javier Goizueta
e5cc9ef0bd
Fix: typo
2015-12-16 17:26:17 +01:00
Javier Goizueta
f7857945c1
Change feature density computation algorithm
...
Now parameterize by the number of levels to traverse and
start with the level that covers the extent of the table
with at least N*N tiles (N=4).
2015-12-16 16:39:38 +01:00
Javier Goizueta
554464e43e
Use tile-recursive computation of feature density
...
This is a more adaptive way of estimating the feature density to
determine the base Z level.
Applying technique from http://javisantana.com/2014/10/22/traversing-quadtree.html
2015-12-16 12:14:37 +01:00
Javier Goizueta
d7c8f3d7e8
Fix: overlay generation was not using the proper scale
2015-12-15 19:13:39 +01:00
Javier Goizueta
4c85d7f3ad
Compute the reference Z level for a table
2015-12-15 19:12:48 +01:00
Javier Goizueta
d0e66910a0
Sketch for new Overview-creation functionality
2015-12-15 17:36:27 +01:00
Stuart Lynn
0ecbbd8e71
Make sure that empty arrays or arrays with all the same entry return 0 for Skewness and Kurtosis rather than throwing a division by zero error
2015-12-04 14:54:15 -05:00
Javier Goizueta
21d5ee5813
Merge pull request #178 from CartoDB/disable-log-invalidation-time
...
Disable log invalidation time
2015-11-27 15:03:46 +01:00
Javier Goizueta
68099e780c
Merge remote-tracking branch 'origin' into 174_cartodbfy
2015-11-24 16:29:32 +01:00
Rafa de la Torre
9dba6fa7c4
Merge pull request #175 from CartoDB/155-fix-wrong-delimiters
...
Removes extra d in delimiter 155
2015-11-24 15:58:54 +01:00
Javier Goizueta
f14fc057e2
Add optional parameter for max. great circle segment length
2015-11-23 17:13:17 +01:00
Javier Goizueta
aa81c6a1ab
Add comment to CDB_GreatCircle
2015-11-23 17:07:24 +01:00
Javier Goizueta
2d13903d50
Cleanup coding style
2015-11-23 16:51:34 +01:00
Javier Goizueta
3bc92d4046
Fix CDB_GreatCircle syntax
2015-11-23 16:40:42 +01:00
Javier Goizueta
83ac8f4502
Fix: Allow dots in column names to be cartodbfied
...
This fixes #6144 of cartodb
Note that prior commit ea9503bd32
only added the tests for this, but not the actual fix (oops)
2015-11-20 13:05:15 +01:00
Javier Goizueta
a0ca2288f4
Fix: Cartodbfication failed with existing PK
...
This fixes #174
When a unique index and a primary key contraint existed for a column
named cartodb_id cartodbfy tried to add another PK constraint
2015-11-20 12:56:52 +01:00
Stuart Lynn
d597f0fe6d
removing comments
2015-11-18 15:56:31 +00:00
Stuart Lynn
f43d1cc3c4
Merge branch 'master' into great_circle_generator
2015-11-18 15:36:51 +00:00
Stuart Lynn
f36f1ab536
formatting
2015-11-18 15:30:16 +00:00
Luis Bosque
d39a032024
Revert "Write invalidation duration in postgresql log"
...
This reverts commit 37160c7b35
.
2015-11-17 13:10:19 +01:00
Luis Bosque
4cceb2a21f
Revert "Optimize invalidation time logging"
...
This reverts commit d1d5ed6df3
.
2015-11-17 13:10:15 +01:00
Guido Fioravantti
cce63f0eae
Adds ::integer cast for USING 155
2015-11-06 16:26:03 +01:00
Alejandro Martínez
2a8d467949
Merge remote-tracking branch 'origin/master' into remove_schema_triggers
2015-11-05 14:49:46 +01:00
Alejandro Martínez
ef376fd243
Remove schema_triggers
2015-11-04 17:06:54 +01:00
Guido Fioravantti
081ed36aae
Fixes NULL max in rec 155
2015-11-02 11:47:14 +01:00
Guido Fioravantti
453b3af872
Removes extra d in delimiter 155
2015-10-30 17:49:27 +01:00
Guido Fioravantti
fdfbe8e62c
Typo fixing 173
2015-10-27 12:11:00 +01:00
Guido Fioravantti
32c729e464
Refactors code 173
2015-10-27 10:33:15 +01:00
Guido Fioravantti
58b2705383
Rename relname to colname in _CDB_Unique_Column_Identifier
2015-10-26 18:35:12 +01:00
Guido Fioravantti
8734608792
Removes unnecessary salt 173
2015-10-26 18:25:48 +01:00
Guido Fioravantti
bb54eb83c1
Drops CDB_Trim_Octets for CDB_Octet_Truncate
2015-10-26 18:01:03 +01:00
Guido Fioravantti
2e701f73ba
Reworks _CDB_Octet_Trim 173
2015-10-26 16:35:33 +01:00
Guido Fioravantti
710a3c9672
Removes ability to examine all relations for _CDB_Unique_Column_Identifier 173
2015-10-26 16:17:25 +01:00
Guido Fioravantti
bb18d71995
Adds comment for magic number and constant for maxlen 173
2015-10-26 16:15:55 +01:00
Guido Fioravantti
629214f32f
Adds explanation for SCHEMA DEFAULT NULL 173
2015-10-26 15:54:08 +01:00
Guido Fioravantti
270d5b3146
Remove code from deprecated methods 173
2015-10-26 15:50:19 +01:00
Guido Fioravantti
b4acfeca22
Fixes Typo in throwing exception 173
2015-10-23 10:38:24 +02:00
Guido Fioravantti
aed8671e77
Uses underscore prefix for private tables 173
2015-10-22 19:00:18 +02:00
Guido Fioravantti
58deeb088d
Raises error on deprecated methods.
2015-10-22 18:56:50 +02:00
Guido Fioravantti
8479c3375b
Adds CDB_Unique_Column_Identifier for columns 173
2015-10-22 17:01:47 +02:00
Guido Fioravantti
5dfe56a664
Moves new CDB_Unique_Identifier and _CDB_Octet_Trim to CDB_Helper.sql file
2015-10-22 12:38:00 +02:00
Guido Fioravantti
5f46ff10e9
Doc change 172
2015-10-21 17:35:13 +02:00
Guido Fioravantti
7c14dd8212
Adds new functions to generate length aware identifiers 172
2015-10-21 17:33:01 +02:00
Luis Bosque
d1d5ed6df3
Optimize invalidation time logging
2015-10-19 14:09:52 +02:00
Luis Bosque
37160c7b35
Write invalidation duration in postgresql log
2015-10-16 18:23:18 +02:00
Alejandro Martínez
811c7474de
Merge pull request #170 from CartoDB/fix-schema-group-sequence
...
Fix schema not being specified on pg_get_serial_sequence
2015-10-15 17:39:46 +02:00
Stuart Lynn
eb475fe55f
Adding function to produce a great circle between two points.
2015-10-14 11:36:48 -04:00
Alejandro Martínez
1f63811383
Fix schema not being specified on pg_get_serial_sequence
2015-10-06 18:09:37 +02:00
Rafa de la Torre
15dd4935d6
Merge pull request #168 from CartoDB/148-cartodbfy-checks-for-null-cartodb-id
...
148 cartodbfy checks for null cartodb id
2015-10-06 14:39:00 +02:00
Guido Fioravantti
186ed34ee5
Overloads CDB_DateToNumber() and adds test
2015-10-05 13:32:03 +02:00
Guido Fioravantti
e4ce12d1a3
Changes CDB_DateToNumber() to accept timestamps with time zones 2202
2015-10-05 11:51:13 +02:00
Guido Fioravantti
3429e93979
Makes cartodbfy check for null cartodb_id
2015-09-29 18:04:00 +02:00
Juan Ignacio Sánchez Lara
1f72be0390
Merge branch 'master' into 103-Extension_Group_API
2015-09-28 09:48:46 +02:00
Juan Ignacio Sánchez Lara
0081ec16a9
Sync-flag functions should be private
2015-09-27 18:42:24 +02:00
Juan Ignacio Sánchez Lara
e7008d04ee
https support back
2015-09-25 19:13:04 +02:00
Juan Ignacio Sánchez Lara
3330421887
sync parameter at group functions closes #162
2015-09-25 19:02:39 +02:00
Rafa de la Torre
567e815fd0
Add DROP FUNCTION back to allow migrations #160
2015-09-24 17:56:00 +02:00
Juan Ignacio Sánchez Lara
a0204d50db
X-Forwarded-Proto
2015-09-21 19:01:40 +02:00
Juan Ignacio Sánchez Lara
a2ddb76ef3
Shorter admin role name
2015-09-21 16:31:12 +02:00
Juan Ignacio Sánchez Lara
cc1e357caa
Removed unnecessary EXECUTEs
2015-09-21 15:47:52 +02:00
Juan Ignacio Sánchez Lara
0e4f3955f6
1108 separator for cleaner SQL
2015-09-21 15:37:10 +02:00
Juan Ignacio Sánchez Lara
8fdf5cb9c4
Merge branch 'master' into 103-Extension_Group_API
2015-09-21 14:52:37 +02:00
Juan Ignacio Sánchez Lara
bf4f30c99d
Removed IMMUTABLE for functions depending on current database
2015-09-21 14:35:28 +02:00
Rafa de la Torre
5ea1b7d4d7
Fix creation of type _cdb_has_usable_geom_record
...
Fix the ERROR: type "_cdb_has_usable_geom_record" already exists by
checking for existence before. Duly noted for upgrades.
2015-09-21 14:16:32 +02:00
Juan Ignacio Sánchez Lara
458cbf2a80
Merge branch 'master' into 103-Extension_Group_API
2015-09-21 12:21:58 +02:00
Rafa de la Torre
0c14df5f89
Fix upgrade from 0.10.0 to 0.10.1
2015-09-16 14:40:18 +02:00
Rafa de la Torre
6ba809e798
Remove usage of _CDB_Geometry_SRID #154
...
This is only used from _CDB_Has_Usable_Geom. It doesn't do what's
promised in the comment. The effect is that a column is taken as valid
when it actually needs setting its SRID restriction so better not use
it as it will need rewrite anyway.
2015-09-16 12:17:40 +02:00
Rafa de la Torre
0ebd12a0eb
Avoid double-escaping of reloid::text #141
2015-09-15 18:49:59 +02:00
Rafa de la Torre
e7c974e957
Fix silly typo #141
2015-09-15 18:49:59 +02:00
Rafa de la Torre
789e89a5d2
Create a return type for _cdb_has_usable_geom_record #141
2015-09-15 18:49:59 +02:00
Rafa de la Torre
3fdce65368
Move column renaming out of _CDB_Has_Usable_Geom #141
2015-09-15 18:49:59 +02:00
Rafa de la Torre
5caddc6cc7
Fix for MultiPoint geometry issue #141
2015-09-15 18:49:59 +02:00
Rafa de la Torre
1596bd56d8
Improve another EXECUTE+FOUND #141
2015-09-14 17:54:35 +02:00
Rafa de la Torre
dfd0454be3
Improve comment #141
2015-09-14 17:53:34 +02:00
Rafa de la Torre
731ee0a9ba
Fix the_geom_webmercator
already exists #141
2015-09-14 17:06:24 +02:00
Rafa de la Torre
e3bba2ee4b
Fix the_geom
already exists error #141
2015-09-14 17:05:14 +02:00
Rafa de la Torre
581835d4ff
Extract query into _cdb_geom_candidate_columns #141
2015-09-14 11:50:10 +02:00
Rafa de la Torre
9ec24c1aff
Fix FOUND in _CDB_Geometry_SRID #141
2015-09-14 11:18:12 +02:00
Rafa de la Torre
7a247c1ab2
Recover usage of cartodb id if has_usable_primary_key #138
2015-09-10 18:20:52 +02:00
Rafa de la Torre
ef21128099
Explicitly check if there's a sequence on PK #138
2015-09-09 18:33:06 +02:00
Alejandro Martínez
9ec5d9000a
Readd update_updated_at function (still used by old tables)
2015-09-09 14:56:34 +02:00
Juan Ignacio Sánchez Lara
206cee1647
Deletion operations return 204
2015-09-09 12:24:54 +02:00
Juan Ignacio Sánchez Lara
f70fd1a4c7
Merge branch 'master' into 103-Extension_Group_API
2015-09-07 13:37:21 +02:00
Raul Ochoa
5abe6e0b3d
Merge branch 'master' into cdb_querytables_quoted
...
Conflicts:
test/extension/test.sh
2015-09-07 12:17:36 +02:00
Raul Ochoa
1eabc5e880
Merge pull request #131 from CartoDB/column-regclass-functions
...
Column regclass
2015-09-07 12:11:59 +02:00
Raul Ochoa
c6cdaea626
Merge pull request #124 from CartoDB/add-kurtosis
...
Add kurtosis and skewness
2015-09-07 12:11:34 +02:00
Juan Ignacio Sánchez Lara
275e5154fd
Fixed comment
2015-09-07 11:48:18 +02:00
Juan Ignacio Sánchez Lara
154eff6d25
Array notation for batch group functions
2015-09-07 11:43:46 +02:00
Juan Ignacio Sánchez Lara
b73eb486a5
Old functions cleanup
2015-09-07 10:35:32 +02:00
Juan Ignacio Sánchez Lara
59d144d91d
Batch add/remove users support
2015-09-07 10:35:04 +02:00
Juan Ignacio Sánchez Lara
428a2391ad
Refactor Member -> User
2015-09-07 09:56:59 +02:00
Andy Eschbacher
83b7f47617
removing raise notices and lower test bounds
2015-09-03 22:43:25 -04:00
Juan Ignacio Sánchez Lara
0896b1451a
Spaces support fixes #135
2015-09-03 20:41:19 +02:00
Juan Ignacio Sánchez Lara
dfec191a9a
Support for spaces inside group names, fixed
2015-09-03 16:51:06 +02:00
Juan Ignacio Sánchez Lara
1b5b3f741f
Support for spaces inside group names
2015-09-03 16:38:12 +02:00
Raul Ochoa
4be7d4a497
Use quote_ident to quote schema and table names when necessary
...
Fixes #133
2015-09-03 13:12:29 +02:00
Raul Ochoa
afecef0e31
Removing redundant ::regclass casting
2015-09-02 12:25:44 +02:00
Raul Ochoa
7582f2cbc5
CDB_ColumnType uses schema and table from regclass
...
Fixes #130
2015-09-02 12:06:04 +02:00
Raul Ochoa
4b5c5dd275
CDB_ColumnNames uses schema and table name from regclass
...
Fixes #122
2015-09-02 12:04:52 +02:00
Juan Ignacio Sánchez Lara
a003ab7f6a
Merge branch 'master' into 103-Extension_Group_API
2015-08-31 13:27:21 +02:00
Rafa de la Torre
0ba57f436a
Do not remove old function #120
...
The `DROP FUNCTION IF EXISTS` was added as transient code and not needed
anymore. See the ticket #120 for more information on this.
2015-08-31 12:01:04 +02:00
Juan Ignacio Sánchez Lara
15aece1fbc
Use %s for sequence name, which is already quoted
2015-08-27 17:03:13 +02:00
Juan Ignacio Sánchez Lara
e1f8a65cce
Use %s for sequence name, which is already quoted
2015-08-27 17:02:05 +02:00
Rafa de la Torre
0057e2ddec
Fix for index generation when renaming table #123
2015-08-27 16:33:46 +02:00
Rafa de la Torre
79cacb8ef4
Modify sampling of table quota trigger #126
2015-08-27 12:52:30 +02:00
Juan Ignacio Sánchez Lara
fc32d457eb
String interpolation with %I, which includes quoting
2015-08-27 10:25:52 +02:00
Juan Ignacio Sánchez Lara
a4952f6a1e
Granting RW permission on a table should also grant permission on default values sequences
2015-08-26 13:33:01 +02:00
Juan Ignacio Sánchez Lara
1f67b52bf7
Documented the need for create extension and separated from cdb_conf creation
2015-08-26 13:23:32 +02:00
Andy Eschbacher
d723487f67
updated definition
2015-08-25 23:10:26 -04:00
Andy Eschbacher
db323f3e13
adding skewness
2015-08-25 22:58:31 -04:00
Andy Eschbacher
49c4cea4e7
adding kurtosis
2015-08-25 22:45:55 -04:00
Rafa de la Torre
7f63688a2f
New version 0.9.2
2015-08-24 15:20:50 +02:00
Paul Ramsey
8c2252a9cb
Handle text 'the_geom' columns as desired in #117
2015-08-21 13:10:05 -07:00
Juan Ignacio Sánchez Lara
c6fa292f01
Extension installation ready
2015-08-20 17:39:28 +02:00
Juan Ignacio Sánchez Lara
faa4f203d6
Changed sample config
2015-08-20 17:32:36 +02:00
Juan Ignacio Sánchez Lara
66e2082266
Missing cartodb schema
2015-08-20 13:02:02 +02:00
Juan Ignacio Sánchez Lara
43d41e5c26
Removed cached (won't work between sessions)
2015-08-20 12:55:22 +02:00
Juan Ignacio Sánchez Lara
bd31419e94
Fixed return auth
2015-08-20 12:54:46 +02:00
Juan Ignacio Sánchez Lara
600f9159fb
{} >> dict()
2015-08-20 10:25:31 +02:00
Juan Ignacio Sánchez Lara
eb912b48bf
Removed not needed json import
2015-08-20 10:22:44 +02:00
Juan Ignacio Sánchez Lara
9c70e5f91a
Merge branch 'master' into 103-Extension_Group_API
2015-08-20 10:17:00 +02:00
Juan Ignacio Sánchez Lara
551e09ff6f
Secured _CDB_Group_API_Request
2015-08-20 10:03:48 +02:00
Juan Ignacio Sánchez Lara
97dd8e5720
Conf value type to json
2015-08-20 08:44:59 +02:00
Rafa de la Torre
5dd497bf20
Fix transformation to webmercator in corner cases #116
2015-08-19 19:37:50 +02:00
Juan Ignacio Sánchez Lara
e1d195a21f
Merge branch 'master' into 103-Extension_Group_API
2015-08-19 18:51:37 +02:00
Juan Ignacio Sánchez Lara
75c4308ea9
Grant and revoking permissions API sync
2015-08-19 18:43:25 +02:00
Rafa de la Torre
74e6807c2f
Merge pull request #78 from CartoDB/new_cartodbfy
...
[wip] New cartodbfy function (overwrites CDB_CartodbfyTable)
2015-08-19 15:11:55 +02:00
Juan Ignacio Sánchez Lara
70fe432102
Secured configuration access
2015-08-19 11:20:06 +02:00
Juan Ignacio Sánchez Lara
e1dde3c36c
Removed old code
2015-08-19 11:08:05 +02:00
Juan Ignacio Sánchez Lara
6c1369f2a9
Documentation about roles and functions
2015-08-19 11:05:32 +02:00
Juan Ignacio Sánchez Lara
726f3c31f7
Documentation about roles and functions
2015-08-19 11:03:07 +02:00
Juan Ignacio Sánchez Lara
2245c05b1e
Don't allow users to pick database name, keeping group operations inside their org
2015-08-19 10:52:07 +02:00
Juan Ignacio Sánchez Lara
1fe9bb2e84
Don't allow users to pick database name, keeping group operations inside their org
2015-08-19 10:37:52 +02:00
Juan Ignacio Sánchez Lara
0cb55d043a
Revoke select on table and add security definer for conf getter
2015-08-19 10:35:23 +02:00
Rafa de la Torre
805af3babf
Review of format strings and escaping of id's
...
Just found cartodbfy failed for schema-names-with-dashes. This should
fix it.
2015-08-18 17:05:32 +02:00
Juan Ignacio Sánchez Lara
fd25a02b45
Merge branch 'master' into 103-Extension_Group_API
2015-08-18 16:07:22 +02:00
Rafa de la Torre
78bf202b17
Fix for schema-with-dashes
2015-08-18 15:41:11 +02:00
Juan Ignacio Sánchez Lara
67d7e28684
409 is a valid renaming response
2015-08-18 13:26:23 +02:00
Juan Ignacio Sánchez Lara
a8b9ec345a
valid_return_codes parameter
2015-08-18 11:53:38 +02:00
Juan Ignacio Sánchez Lara
a75a337296
_CDB_Conf_Cache SD-based
2015-08-18 10:44:10 +02:00
Juan Ignacio Sánchez Lara
1217b4e4a4
Cache http client with private SD
2015-08-18 08:27:14 +02:00
Juan Ignacio Sánchez Lara
d6410d91bd
Cache http client
2015-08-18 08:24:30 +02:00
Juan Ignacio Sánchez Lara
9d03e755b8
_CDB_Group_API_Request refactor
2015-08-18 08:10:02 +02:00
Rafa de la Torre
3f588df6f6
Drop function in order to change return value
2015-08-17 15:28:37 +02:00
Rafa de la Torre
2b48f90374
Merge remote-tracking branch 'origin/master' into new_cartodbfy
...
Conflicts:
test/CDB_QuotaTest.sql
2015-08-17 15:27:33 +02:00