Skip to content

Conversation

@aweyl
Copy link
Contributor

@aweyl aweyl commented Sep 28, 2017

  1. created new class QueryResult which will contain the data and the
    statistics from the query. Will also contain a pretty_print method to
    print the info.
  2. corresponding changes in query method


class QueryResult(object):
def __init__(self, data, statistics):
self.data = data
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rename to resultset
init(self, resultset, statistics):
self.resultset = resultset

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done


def pretty_print(self):
tbl = PrettyTable(self.data[0])
for row in self.data[1:]:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add comment, explain what's in the first row.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@aweyl aweyl force-pushed the change_query_result branch from 1e33693 to 51795d5 Compare October 1, 2017 05:25
1. created new class QueryResult which will contain the data and the
statistics from the query. Will also contain a pretty_print method to
print the info.
2. corresponding changes in query method
@aweyl aweyl force-pushed the change_query_result branch from 51795d5 to 9f19c7f Compare October 1, 2017 06:14
@swilly22 swilly22 merged commit 69fc391 into RedisGraph:master Oct 1, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants