Re: Custom Aggregator Functions

2015-12-03 Thread Jaime Solano
Thanks, Rajeshbabu. Is this somewhere in the roadmap? On Dec 3, 2015 3:31 AM, "rajeshb...@apache.org" wrote: > Hi Jaime, > > Currently User Defined Aggregate functions not supported. > > Thanks, > Rajeshbabu. > > On Wed, Dec 2, 2015 at 10:45 PM, Jaime Solano

Custom Aggregator Functions

2015-12-02 Thread Jaime Solano
Hi guys, We're planning to upgrade Phoenix 4.2.0 to Phoenix 4.4. As part of this process, we'll need to migrate our custom UDFs, with the new feature provided by 4.4. However, the documentation only describes how to create an Scalar function, not an aggregator one. Are User Defined Aggregator Fun

Re: Link indexes to another table

2015-11-20 Thread Jaime Solano
1:19 PM, "James Taylor" wrote: > Hi Jaime, > Not sure exactly what you mean. Would you mind explaining a bit more what > you're trying to do (and why)? > Thanks, > James > > On Fri, Nov 20, 2015 at 9:01 AM, Jaime Solano wrote: > >> Hi guys, >>

Link indexes to another table

2015-11-20 Thread Jaime Solano
Hi guys, As part of a swapping strategy we're testing, we want to know if it's possible to link the indexes from one table to another one (clone of the first). We've tried a few things on the SYSTEM.CATLOG with no luck. The real question would beis this even possible? If so, how? Thanks, -Jai

Re: yet another question...perhaps dumb...JOIN with two conditions

2015-09-10 Thread Jaime Solano
Hi Aaron, The JOIN you're trying to run is a non-equi join, meaning that the ON condition is not an equality ('>=' and '<=' in your case). This type of join is not supported in Phoenix versions prior to 4.3 In Phoenix 4.3+, you can do something like this: SELECT * FROM NG.AKAMAI_FORCEFIELD AS FO

Re: Updating a row

2015-09-05 Thread Jaime Solano
Hi Bipin, You can use the UPSERT SELECT statement. https://phoenix.apache.org/language/#upsert_select Best, -Jaime On Sep 4, 2015 11:10 PM, "Bipin Nag" wrote: > How can I update values in an existing row. I believe the upsert statement > does not take a where clause. How to do update ? > > Thanks

Re: Phoenix JDBC in web-app, what is the right pattern?

2015-09-03 Thread Jaime Solano
request to use it. > > On Thu, Sep 3, 2015 at 12:58 PM, Jaime Solano wrote: > >> Hi Samarth, >> In our project we were thinking about using Tomcat JDBC Connection Pool, >> to handle Phoenix connections. You're saying this type of approach should >> be

Re: Phoenix JDBC in web-app, what is the right pattern?

2015-09-03 Thread Jaime Solano
Hi Samarth, In our project we were thinking about using Tomcat JDBC Connection Pool, to handle Phoenix connections. You're saying this type of approach should be avoided? What other approach should be followed if, in the scenario Serega described, you experience a heavy load of users, all trying to

Re: Getting ArrayIndexOutOfBoundsException in UPSERT SELECT

2015-08-26 Thread Jaime Solano
higher > and try those same queries? > > Josh > > On Wed, Aug 26, 2015 at 3:30 PM, Jaime Solano wrote: > >> Hi Yiannis, >> >> Not quite, but it's similar. For instance, in my case the tables are not >> salted. >> >> I forgot to add, I

Re: Getting ArrayIndexOutOfBoundsException in UPSERT SELECT

2015-08-26 Thread Jaime Solano
jira/browse/PHOENIX-2169 the error you > are getting? > > Thanks > > On 26 August 2015 at 19:52, Jaime Solano wrote: > >> Hi guys, >> >> I'm getting *Error: java.lang.ArrayIndexOutOfBoundsException >> (state=08000, code=101)*, while doing a query like th

Getting ArrayIndexOutOfBoundsException in UPSERT SELECT

2015-08-26 Thread Jaime Solano
Hi guys, I'm getting *Error: java.lang.ArrayIndexOutOfBoundsException (state=08000, code=101)*, while doing a query like the following: UPSERT INTO A (PK, COL2) SELECT A.PK, A.COL1 * B.COL1 FROM A LEFT JOIN B ON A.COL3=B.COL2; Some additional info: - Table A has around 140k records, while table

Joins Benchmark

2015-06-02 Thread Jaime Solano
Hi guys, Are there benchmarks or numbers showing how Phoenix performs during the join of two or more huge tables? I'm not familiar with the join implementation, so I'm not sure if there's a limitation regarding number of regions, memory, disk, etc. Any thoughts? Thanks, -Jaime

Re: UDF - Access Tuple Column Values By Name

2015-05-06 Thread Jaime Solano
Hi Kathir, I don't know if that's posible, but seems like the better approach is to just define your function to take two arguments. What do you think? Best, -Jaime On May 6, 2015 7:50 AM, "Kathiresan S" wrote: > Hi, > > In UDF, in the implemented evaluate(tuple,ptr) method, i could access the

Re: Non-equi joins

2015-03-25 Thread Jaime Solano
= T2.COL3; > > > On Wed, Mar 25, 2015 at 9:29 AM, Jaime Solano wrote: > >> Hi guys, >> I'm trying to figure out a way to join two tables with non-equi >> conditions. Basically, something like: >> SELECT * FROM T1 LEFT JOIN T2 ON T1.COL1 >= T2.COL2 AND

Non-equi joins

2015-03-25 Thread Jaime Solano
Hi guys, I'm trying to figure out a way to join two tables with non-equi conditions. Basically, something like: SELECT * FROM T1 LEFT JOIN T2 ON T1.COL1 >= T2.COL2 AND T1.COL1 <= T2.COL3; I'm using Phoenix 4.2.0, which doesn't support non-equi joins. Is this feature supported in version 4.3? If not

Defining new function outside Phoenix jar

2015-03-03 Thread Jaime Solano
Hi guys, In the "How to add your own built-in function to Phoenix" blog post it is mentioned that there's room for improvement so that the function can be defined outside Phoenix jar, avoiding this way modifying the source code. Can you mention a few ideas of How can this be accomplished? (defining

Index Updation after upsert

2015-02-03 Thread Jaime Solano
Hi guys, We're using the Phoenix MR CSV loader to bulkload our data. Does the current Phoenix version (4.2) updates the indexes after upserting the data into the table using the previously mentioned MR? Thanks in advance!

Re: Phoenix UPSERTS SELECT for data transformation

2015-02-03 Thread Jaime Solano
write >> 50 built-in functions, each with specific business logic, I'd >> definitely gravitate toward using our Pig integration. >> >> Thanks, >> James >> >> On Wed, Jan 28, 2015 at 6:51 AM, Jaime Solano >> wrote: >> > Hi James, >>

Re: Phoenix UPSERTS SELECT for data transformation

2015-01-28 Thread Jaime Solano
tion such that the resulting table is queryable through > Phoenix as well. > > HTH. Thanks, > > James > > [1] http://phoenix.apache.org/phoenix_mr.html > [2] http://phoenix.apache.org/pig_integration.html > > On Tue, Jan 27, 2015 at 11:50 AM, Jaime Solano > wrote: > >

Phoenix UPSERTS SELECT for data transformation

2015-01-27 Thread Jaime Solano
Hi guys, The company I work for wants to use Phoenix for Data Transformation. Basically, the idea is to denormalize and include additional calculated data to a details table, by using UPSERT SELECT statements (joins with other tables and specific functions). This has proven to be challenging, sinc