Block search
EXAMPLE USAGES
SELECT * FROM hafbe_endpoints.get_block_by_op(ARRAY[0,2,8,32,84,27,83,23,43,65,29,68], NULL, 'desc', 'op_type_id', 0, 2147483647, 100)
SELECT * FROM hafbe_endpoints.get_block_by_op(ARRAY[0,2,8,32,84,27,83,23,43,65,29,68], 'gtg', 'desc', 'op_type_id', 0, 2147483647, 100)
SELECT * FROM hafbe_endpoints.get_block_by_op(ARRAY[0,2,8,32,84,27,83,23,43,65,29,68], NULL, 'desc', 'block_num', 0, 2147483647, 100)
SELECT * FROM hafbe_endpoints.get_block_by_op(ARRAY[0,2,8,32,84,27,83,23,43,65,29,68], 'gtg', 'desc', 'block_num', 0, 2147483647, 100)
SELECT * FROM hafbe_endpoints.get_block_by_op(ARRAY[1], 'gtg', 'desc', 'op_type_id', 0, 2147483647, 100, ARRAY['blocktrades'], '[["value", "author"]]')
SELECT * FROM hafbe_endpoints.get_block_by_op(ARRAY[51], NULL, 'desc', 'op_type_id', 0, 2147483647, 100, ARRAY['gtg'], '[["value", "author"]]')
SELECT * FROM hafbe_endpoints.get_block_by_op(ARRAY[68], NULL, 'desc', 'op_type_id', 0, 2147483647, 100)
SELECT * FROM hafbe_endpoints.get_block_by_op(ARRAY[1], 'gtg', 'desc', 'block_num',0, 2147483647, 100, ARRAY['blocktrades'], '[["value", "author"]]')
SELECT * FROM hafbe_endpoints.get_block_by_op(ARRAY[51], NULL, 'desc', 'block_num', 0, 2147483647, 100, ARRAY['gtg'], '[["value", "author"]]')
SELECT * FROM hafbe_endpoints.get_block_by_op(ARRAY[68], NULL, 'desc', 'block_num', 0, 2147483647, 100)
endpoint returns:
column of block_num for single operation request (same as previous iteration),
op_type_id, array of block_nums for multiple operations (grouped by op_type_id, new feature),
block_num, array of op_type_id for multiple operations (grouped by block_num, same as previous iteration)
Edited by Michal Zander