You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@madlib.apache.org by ri...@apache.org on 2016/03/29 19:25:24 UTC
incubator-madlib git commit: Path: Add quoted input test in
install-check
Repository: incubator-madlib
Updated Branches:
refs/heads/master 53713a74d -> 0b26dc531
Path: Add quoted input test in install-check
Project: http://git-wip-us.apache.org/repos/asf/incubator-madlib/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-madlib/commit/0b26dc53
Tree: http://git-wip-us.apache.org/repos/asf/incubator-madlib/tree/0b26dc53
Diff: http://git-wip-us.apache.org/repos/asf/incubator-madlib/diff/0b26dc53
Branch: refs/heads/master
Commit: 0b26dc531a7f598e60cc8d10ee77e4e75001059a
Parents: 53713a7
Author: Rahul Iyer <ri...@pivotal.io>
Authored: Tue Mar 29 10:25:14 2016 -0700
Committer: Rahul Iyer <ri...@pivotal.io>
Committed: Tue Mar 29 10:25:14 2016 -0700
----------------------------------------------------------------------
.../postgres/modules/utilities/test/path.sql_in | 23 ++++++++++----------
1 file changed, 11 insertions(+), 12 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-madlib/blob/0b26dc53/src/ports/postgres/modules/utilities/test/path.sql_in
----------------------------------------------------------------------
diff --git a/src/ports/postgres/modules/utilities/test/path.sql_in b/src/ports/postgres/modules/utilities/test/path.sql_in
index e4d06e6..f29421e 100644
--- a/src/ports/postgres/modules/utilities/test/path.sql_in
+++ b/src/ports/postgres/modules/utilities/test/path.sql_in
@@ -25,21 +25,20 @@
*/
/* ----------------------------------------------------------------------- */
-DROP TABLE IF EXISTS weblog, path_output, path_output_rows CASCADE;
-
-CREATE TABLE weblog (event_timestamp TIMESTAMP,
+DROP TABLE IF EXISTS "Weblog", "Path_output", "Path_output_tuples" CASCADE;
+CREATE TABLE "Weblog" (event_timestamp TIMESTAMP,
user_id INT,
age_group INT,
income_group INT,
gender TEXT,
region TEXT,
household_size INT,
- click_event INT,
+ "Click_event" INT,
purchase_event INT,
revenue FLOAT,
- margin FLOAT);
+ "Margin" FLOAT);
-INSERT INTO weblog VALUES
+INSERT INTO "Weblog" VALUES
('04/14/2012 23:43:00', 102201, 3, 3, 'Female', 'East', 3, 1, 1, 112, 36),
('04/14/2012 23:56:00', 101881, 2, 4, 'Male', 'West', 5, 0, 0, 0, 0),
('04/15/2012 01:04:00', 100821, 1, 4, 'Unknown', 'West', 3, 0, 0, 0, 0),
@@ -80,11 +79,11 @@ INSERT INTO weblog VALUES
SELECT * FROM weblog ORDER BY event_timestamp ASC;
*/
SELECT path(
- 'weblog', -- Name of the table
+ '"Weblog"', -- Name of the table
'"Path_output"', -- Table name to store the path results
'user_id', -- Partition expression to group the data table
'event_timestamp ASC', -- Order expression to sort the tuples of the data table
- 'I:=click_event=0 AND purchase_event=0, Click:=click_event=1 AND purchase_event=0, Conv:=purchase_event=1', -- Definition of various symbols used in the pattern definition
+ 'I:="Click_event"=0 AND purchase_event=0, Click:="Click_event"=1 AND purchase_event=0, Conv:=purchase_event=1', -- Definition of various symbols used in the pattern definition
'I(click){1}(CONV){1}', -- Definition of the path pattern to search for
'COUNT(*)' -- Aggregate/window functions to be applied on the matched paths
,TRUE
@@ -99,20 +98,20 @@ SELECT * FROM "Path_output_tuples";
SELECT * FROM "Path_output";
-INSERT INTO weblog VALUES
+INSERT INTO "Weblog" VALUES
('04/15/2012 02:15:00', 101331, 2, 4, 'Female', 'East', 5, 0, 0, 0, 0),
('04/15/2012 02:59:00', 101331, 2, 4, 'Female', 'East', 5, 1, 0, 0, 0),
('04/15/2012 04:32:00', 101331, 2, 4, 'Female', 'East', 5, 1, 1, 112, 36);
DROP TABLE "Path_output", "Path_output_tuples";
SELECT path(
- 'weblog', -- Name of the table
+ '"Weblog"', -- Name of the table
'"Path_output"', -- Table name to store the path results
'user_id', -- Partition expression to group the data table
'event_timestamp ASC', -- Order expression to sort the tuples of the data table
- 'I:=click_event=0 AND purchase_event=0, Click:=click_event=1 AND purchase_event=0, Conv:=purchase_event=1', -- Definition of various symbols used in the pattern definition
+ 'I:="Click_event"=0 AND purchase_event=0, Click:="Click_event"=1 AND purchase_event=0, Conv:=purchase_event=1', -- Definition of various symbols used in the pattern definition
'I(click){1}(CONV){1}', -- Definition of the path pattern to search for
- 'SUM(margin) as sum_of_margin, SUM(revenue) as sum_of_revenue', -- Aggregate/window functions to be applied on the matched paths
+ 'SUM("Margin") as sum_of_margin, SUM(revenue) as sum_of_revenue', -- Aggregate/window functions to be applied on the matched paths
TRUE
);
------------------------------------------------------------