Hi Gowri,
UUID in datatype in PostgreSQL goes through OGSA-DAI and DQP as an OBJECT.
The type conversion rules in DQP do now allow these objects to be
matched with any other types. This is easily changed in the
uk.org.ogsadai.tuple.TypeConverter class. I attach a new version of this
class that will work for you. I have not yet committed this to the SVN
repository because we are still debating if such a conversion should be
carried out by default.
Compiling and replacing the jar with this new version of TypeConverter
class should fix your problem.
Regards,
Ally
--
-------------------------------------
Ally Hume
Software Architect
EPCC, The University of Edinburgh
Tel: +44 131 651 3397 Skype: ally.hume
On 19/01/2012 05:40, Gowri Kumaraguruparan wrote:
> Hi,
>
> Is "uuid" datatype in PostgreSQL database supported in DQP?
> (http://www.postgresql.org/docs/8.3/static/datatype-uuid.html)
>
> I have an installation of Postgres resource and that works when I
> execute DQP queries that filters on varchar data type columns. However,
> when I apply filters to columns of uuid datatype, I get this exception:
>
> Caused by: uk.org.ogsadai.dqp.lqp.exceptions.LQPException:
> uk.org.ogsadai.tuple.TypeMismatchException: Type mismatch between OBJECT
> and STRING
> at
> uk.org.ogsadai.dqp.lqp.operators.SelectOperator.validate(SelectOperator.java:190)
> at
> uk.org.ogsadai.dqp.lqp.operators.UnaryOperator.validate(UnaryOperator.java:116)
> at
> uk.org.ogsadai.dqp.lqp.operators.ProjectOperator.validate(ProjectOperator.java:782)
> at
> uk.org.ogsadai.dqp.lqp.operators.UnaryOperator.validate(UnaryOperator.java:116)
> at
> uk.org.ogsadai.dqp.lqp.operators.ProjectOperator.validate(ProjectOperator.java:782)
> at
> uk.org.ogsadai.dqp.lqp.operators.UnaryOperator.validate(UnaryOperator.java:116)
> at uk.org.ogsadai.dqp.lqp.LQPBuilder.buildLQP(LQPBuilder.java:181) at
> uk.org.ogsadai.dqp.execute.SQLQueryPlanBuilder.buildValidatedLQP(SQLQueryPlanBuilder.java:129)
> ... 14 more
> Caused by: uk.org.ogsadai.tuple.TypeMismatchException: Type mismatch
> between OBJECT and STRING
> at
> uk.org.ogsadai.tuple.TypeConverter.getComparisonType(TypeConverter.java:454)
> at
> uk.org.ogsadai.expression.ComparisonExpressionBase.configure(ComparisonExpressionBase.java:175)
> at
> uk.org.ogsadai.expression.ComparisonExpressionBase.configure(ComparisonExpressionBase.java:147)
> at
> uk.org.ogsadai.dqp.lqp.operators.SelectOperator.validate(SelectOperator.java:184)
> ... 21 more
>
> My query looks like this. select * from PostgresResource_tablename t1
> where uuid_col_name="filter-data"
>
> Is this because uuid datatype is not supported inside DQP? How can I see
> the Postgres datatypes that are supported in DQP?
>
> - Gowri
>
>
>
>
> ------------------------------------------------------------------------------
> Keep Your Developer Skills Current with LearnDevNow!
> The most comprehensive online learning library for Microsoft developers
> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
> Metro Style Apps, more. Free future releases when you subscribe now!
> http://p.sf.net/sfu/learndevnow-d2d
>
>
>
> _______________________________________________
> ogsa-dai-users mailing list
> ogsa-dai-users@...
> https://lists.sourceforge.net/lists/listinfo/ogsa-dai-users
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.
|