-
-
Notifications
You must be signed in to change notification settings - Fork 91
Milestone
Description
Given a type defined in this way:
CREATE VERTEX TYPE article ;
CREATE PROPERTY article.id ILONG;
CREATE PROPERTY article.author IF NOT EXISTS STRING;and this query:
SELECT *, @rid, @type, author AS _author FROM articleUse the RemoteDatabase client to execute the query the alias _author is correctly populated
RemoteDatabase remoteDatabase = new RemoteDatabase("localhost", 2480,"testdb "root","password);
ResultSet resultSet = remoteDatabase.query("sql", "SELECT *, @rid, @type, author AS _author FROM article");
resultSet.stream().forEach(r-> System.out.println(" _author = " + r.getProperty("_author")));Using the RemoteGrpcDatabase the _author is not populated
RemoteGrpcDatabase database = new RemoteGrpcDatabase(server, "localhost", 50051, 2480, "testDatabase, "root", "password");
ResultSet resultSet = database.query("sql", ""SELECT *, @rid, @type, author AS _author FROM article);
resultSet.stream().forEach(r-> System.out.println(" _author = " + r.getProperty("_author")));Cause
In ArcadeDbGrpcService the method public void executeQuery(ExecuteQueryRequest request, StreamObserver<ExecuteQueryResponse> responseObserver) serialize the result set using private GrpcRecord convertToGrpcRecord(Record dbRecord, Database db) that works at the Record level.
Proposed solution
Let the private GrpcRecord convertToGrpcRecord(Record dbRecord, Database db) work with Result as the AbstractQueryHandler.serializeResultSet does
Reactions are currently unavailable