airavata-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (AIRAVATA-2728) Refactoring Experiment Catalog Implementation
Date Tue, 17 Apr 2018 09:20:00 GMT

    [ https://issues.apache.org/jira/browse/AIRAVATA-2728?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16440653#comment-16440653
] 

ASF GitHub Bot commented on AIRAVATA-2728:
------------------------------------------

tilaks26 commented on a change in pull request #191: [AIRAVATA-2728] Refactoring Experiment
Catalog Implementation
URL: https://github.com/apache/airavata/pull/191#discussion_r182006578
 
 

 ##########
 File path: modules/registry-refactoring/src/main/java/org/apache/airavata/registry/core/repositories/expcatalog/ProjectRepository.java
 ##########
 @@ -159,9 +157,13 @@ else if (field.equals(DBConstants.Project.DESCRIPTION)) {
 
         }
 
-        if (!accessibleProjectIds.isEmpty() && accessibleProjectIds != null) {
+        if (accessibleProjectIds != null && !accessibleProjectIds.isEmpty()) {
             logger.debug("Filter Projects by Accessible Project IDs");
-            query += " P.projectId IN :" + accessibleProjectIds;
+            query += "P.projectId IN (";
 
 Review comment:
   @machristie This generates a query like - 
   
   ``
   SELECT DISTINCT P FROM ProjectEntity P WHERE P.owner LIKE :user AND P.name LIKE :projectName
AND P.description LIKE :projectDescription AND P.gatewayId LIKE :testGateway AND P.projectId
IN (:projectName_a7220549-302a-40c5-886c-8515a0306b90)
   ``
   
   I'm getting the following error - 
   
   ``
   org.apache.openjpa.persistence.ArgumentException: "Encountered "P . projectId IN ( : projectName_7f802917
-" at character 175, but expected: ["(", ")", "*", "+", ",", "-", ".", "/", ":", "<", "<=",
"<>", "=", ">", ">=", "?", "ABS", "ALL", "AND", "ANY", "AS", "ASC", "AVG", "BETWEEN",
"BOTH", "BY", "CONCAT", "COUNT", "CURRENT_DATE", "CURRENT_TIME", "CURRENT_TIMESTAMP", "DELETE",
"DESC", "DISTINCT", "EMPTY", "ESCAPE", "EXISTS", "FETCH", "FROM", "GROUP", "HAVING", "IN",
"INNER", "IS", "JOIN", "LEADING", "LEFT", "LENGTH", "LIKE", "LOCATE", "LOWER", "MAX", "MEMBER",
"MIN", "MOD", "NEW", "NOT", "NULL", "OBJECT", "OF", "OR", "ORDER", "OUTER", "SELECT", "SET",
"SIZE", "SOME", "SQRT", "SUBSTRING", "SUM", "TRAILING", "TRIM", "TYPE", "UPDATE", "UPPER",
"WHERE", <BOOLEAN_LITERAL>, <DATE_LITERAL>, <DECIMAL_LITERAL>, <IDENTIFIER>,
<INTEGER_LITERAL>, <STRING_LITERAL2>, <STRING_LITERAL>, <TIMESTAMP_LITERAL>,
<TIME_LITERAL>]." while parsing JPQL "SELECT DISTINCT P FROM ProjectEntity P WHERE P.owner
LIKE :user AND P.name LIKE :projectName AND P.description LIKE :projectDescription AND P.gatewayId
LIKE :testGateway AND P.projectId IN (:projectName_7f802917-f050-4a86-bb1e-e0a25f6ba3a5)"
   ``

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


> Refactoring Experiment Catalog Implementation
> ---------------------------------------------
>
>                 Key: AIRAVATA-2728
>                 URL: https://issues.apache.org/jira/browse/AIRAVATA-2728
>             Project: Airavata
>          Issue Type: Improvement
>          Components: Registry API
>            Reporter: Sneha Tilak
>            Assignee: Sneha Tilak
>            Priority: Major
>




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message