Skip to content

Commit

Permalink
refactor(pub-period-migration) code refactoring.
Browse files Browse the repository at this point in the history
  • Loading branch information
SvitlanaKovalova1 committed Oct 23, 2024
1 parent 3300f12 commit ff8d368
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ramls/holdings-storage/holdingsRecordView.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
"holdingsInstance": {
"description": "Instance of holding record. This is a virtual field, accessible only when using mod-graphql.",
"type": "object",
"folio:$ref": "instance-without-pub-period.json",
"folio:$ref": "instance.json",
"readonly": true,
"folio:isVirtual": true,
"folio:linkBase": "inventory/instances",
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/org/folio/persist/AbstractRepository.java
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ public <S, R> void streamGet(String table, Class<S> clazz,
var response = routingContext.response();
try {
var facetList = FacetManager.convertFacetStrings2FacetFields(facets, JSON_COLUMN);
var wrapper = new CQLWrapper(new CQL2PgJSON(table + "." + JSON_COLUMN), cql, limit, offset);
var wrapper = new CQLWrapper(new CQL2PgJSON(String.format("%s.%s", table, JSON_COLUMN)), cql, limit, offset);
streamGetInstances(table, clazz, wrapper, facetList, element, queryTimeout, routingContext, targetClazz);
} catch (Exception e) {
logger.error(e.getMessage(), e);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ private String selectSql() {

if (!idsForMigration.isEmpty()) {
var ids = idsForMigration.stream()
.map(id -> "'" + id + "'")
.map(id -> String.format("'%s'", id))
.collect(Collectors.joining(", "));

whereCondition = String.format(WHERE_CONDITION, ids);
Expand Down

0 comments on commit ff8d368

Please sign in to comment.