Skip to content

Commit

Permalink
Rename index to transaction_index
Browse files Browse the repository at this point in the history
  • Loading branch information
medvedev1088 committed Aug 4, 2018
1 parent b37bedc commit 2219046
Show file tree
Hide file tree
Showing 11 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ hash | hex_string |
nonce | bigint |
block_hash | hex_string |
block_number | bigint |
index | bigint |
transaction_index| bigint |
from_address | address |
to_address | address |
value | numeric |
Expand Down
2 changes: 1 addition & 1 deletion ethereumetl/domain/transaction.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def __init__(self):
self.nonce = None
self.block_hash = None
self.block_number = None
self.index = None
self.transaction_index = None
self.from_address = None
self.to_address = None
self.value = None
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
'nonce',
'block_hash',
'block_number',
'index',
'transaction_index',
'from_address',
'to_address',
'value',
Expand Down
4 changes: 2 additions & 2 deletions ethereumetl/mappers/transaction_mapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def json_dict_to_transaction(self, json_dict):
transaction.nonce = hex_to_dec(json_dict.get('nonce', None))
transaction.block_hash = json_dict.get('blockHash', None)
transaction.block_number = hex_to_dec(json_dict.get('blockNumber', None))
transaction.index = hex_to_dec(json_dict.get('transactionIndex', None))
transaction.transaction_index = hex_to_dec(json_dict.get('transactionIndex', None))
transaction.from_address = to_normalized_address(json_dict.get('from', None))
transaction.to_address = to_normalized_address(json_dict.get('to', None))
transaction.value = hex_to_dec(json_dict.get('value', None))
Expand All @@ -48,7 +48,7 @@ def transaction_to_dict(self, transaction):
'nonce': transaction.nonce,
'block_hash': transaction.block_hash,
'block_number': transaction.block_number,
'index': transaction.index,
'transaction_index': transaction.transaction_index,
'from_address': transaction.from_address,
'to_address': transaction.to_address,
'value': transaction.value,
Expand Down
2 changes: 1 addition & 1 deletion schemas/aws/parquet/parquet_transactions.sql
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ CREATE EXTERNAL TABLE IF NOT EXISTS parquet_transactions (
nonce BIGINT,
block_hash STRING,
block_number BIGINT,
index BIGINT,
transaction_index BIGINT,
from_address STRING,
to_address STRING,
value DECIMAL(38,0),
Expand Down
2 changes: 1 addition & 1 deletion schemas/aws/transactions.sql
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ CREATE EXTERNAL TABLE IF NOT EXISTS transactions (
nonce BIGINT,
block_hash STRING,
block_number BIGINT,
index BIGINT,
transaction_index BIGINT,
from_address STRING,
to_address STRING,
value DECIMAL(38,0),
Expand Down
2 changes: 1 addition & 1 deletion schemas/gcp/transactions.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"description": "Block number where this transaction was in. null when its pending"
},
{
"name": "index",
"name": "transaction_index",
"type": "INT64",
"mode": "REQUIRED",
"description": "Integer of the transactions index position in the block. null when its pending"
Expand Down
2 changes: 1 addition & 1 deletion schemas/gcp/transactions_join_receipts.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"description": "The number of transactions made by the sender prior to this one"
},
{
"name": "index",
"name": "transaction_index",
"type": "INT64",
"mode": "REQUIRED",
"description": "Integer of the transactions index position in the block. null when its pending"
Expand Down
2 changes: 1 addition & 1 deletion schemas/gcp/transactions_join_receipts.sql
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ SELECT
blocks.number,
transactions.hash,
transactions.nonce,
transactions.index,
transactions.transaction_index,
transactions.from_address,
transactions.to_address,
transactions.value,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
hash,nonce,block_hash,block_number,index,from_address,to_address,value,gas,gas_price,input
hash,nonce,block_hash,block_number,transaction_index,from_address,to_address,value,gas,gas_price,input
0x04cbcb236043d8fb7839e07bbc7f5eed692fb2ca55d897f1101eac3e3ad4fab8,12,0x246edb4b351d93c27926f4649bcf6c24366e2a7c7c718dc9158eea20c03bc6ae,483920,0,0x1b63142628311395ceafeea5667e7c9026c862ca,0xf4eced2f682ce333f96f2d8966c613ded8fc95dd,0,150853,50000000000,0xa9059cbb000000000000000000000000ac4df82fe37ea2187bc8c011a23d743b4f39019a00000000000000000000000000000000000000000000000000000000000186a0
0xcea6f89720cc1d2f46cc7a935463ae0b99dd5fad9c91bb7357de5421511cee49,84,0x246edb4b351d93c27926f4649bcf6c24366e2a7c7c718dc9158eea20c03bc6ae,483920,1,0x9b22a80d5c7b3374a05b446081f97d0a34079e7f,0xf4eced2f682ce333f96f2d8966c613ded8fc95dd,0,150853,50000000000,0xa9059cbb00000000000000000000000066f183060253cfbe45beff1e6e7ebbe318c81e560000000000000000000000000000000000000000000000000000000000030d40
0x463d53f0ad57677a3b430a007c1c31d15d62c37fab5eee598551697c297c235c,88,0x246edb4b351d93c27926f4649bcf6c24366e2a7c7c718dc9158eea20c03bc6ae,483920,2,0x9df428a91ff0f3635c8f0ce752933b9788926804,0x9e669f970ec0f49bb735f20799a7e7c4a1c274e2,11000440000000000,90000,50000000000,0x
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
hash,nonce,block_hash,block_number,index,from_address,to_address,value,gas,gas_price,input
hash,nonce,block_hash,block_number,transaction_index,from_address,to_address,value,gas,gas_price,input
0xbd5ab8937e52a6244209d804471be4878df6c364bca0111dd6d05e0d3edf63cf,79,0x944f09177142833c644c979a83900d8cae1ee67369774b88b3b330bb72825082,47219,0,0xe6a7a1d47ff21b6321162aea7c6cb457d5476bca,0xe25e3a1947405a1f82dd8e3048a9ca471dc782e1,8306052477120672000,21000,61580653163,0x
0x4bcc1dd0c56c0b767b1ee3cb8bce7df44518f1696205299e34eb53a5e00a863e,1,0x944f09177142833c644c979a83900d8cae1ee67369774b88b3b330bb72825082,47219,1,0xf9a19aea1193d9b9e4ef2f5b8c9ec8df93a22356,0x32be343b94f860124dc4fee278fdcbd38c102d88,1998716170000000000,21000,61134768794,0x
0x99f1097abd8f33a68f0ed63d60de5f3e7e2a3e0579b90d5f46a4f201c658b46d,9,0x889c421abc62a48641eee140519e6da8c9dc01d85d8f5c4fbc3c13e3c6e4cb3e,47218,0,0x1406854d149e081ac09cb4ca560da463f3123059,0xa0e74ae010d51894734c308d612131056bb721ad,110000000000000000000,40000,62227241854,0x
Expand Down

0 comments on commit 2219046

Please sign in to comment.