diff --git a/migration.sql b/migration.sql index 9baeb46..21ec6fd 100644 --- a/migration.sql +++ b/migration.sql @@ -119,4 +119,9 @@ CLUSTER banking_stage_results_2.blocks using blocks_pkey; VACUUM FULL banking_stage_results_2.blocks; -- optional CLUSTER banking_stage_results_2.transaction_slot using idx_transaction_slot_timestamp; -VACUUM FULL banking_stage_results_2.transaction_slot; \ No newline at end of file +VACUUM FULL banking_stage_results_2.transaction_slot; + +ALTER TABLE banking_stage_results_2.transactions ALTER COLUMN signature TYPE TEXT; + +CLUSTER banking_stage_results_2.accounts_map_transaction using accounts_map_transaction_pkey; + diff --git a/src/postgres.rs b/src/postgres.rs index 255c5b6..2fa8ef2 100644 --- a/src/postgres.rs +++ b/src/postgres.rs @@ -134,7 +134,7 @@ impl PostgresSession { format!( r#" CREATE TEMP TABLE {}( - signature char(88) + signature TEXT ); "#, temp_table @@ -184,7 +184,7 @@ impl PostgresSession { .execute( format!( "CREATE TEMP TABLE {}( - key char(44) + key TEXT );", temp_table ) @@ -231,7 +231,7 @@ impl PostgresSession { .execute( format!( "CREATE TEMP TABLE {}( - sig char(88), + sig TEXT, slot BIGINT, error_code INT, count INT, @@ -307,8 +307,8 @@ impl PostgresSession { .execute( format!( "CREATE TEMP TABLE {}( - account_key char(44), - signature char(88), + account_key TEXT, + signature TEXT, is_writable BOOL, is_signer BOOL, is_atl BOOL @@ -381,7 +381,7 @@ impl PostgresSession { .execute( format!( "CREATE TEMP TABLE {}( - signature char(88), + signature TEXT, processed_slot BIGINT, is_successful BOOL, cu_requested BIGINT, @@ -470,7 +470,7 @@ impl PostgresSession { .execute( format!( "CREATE TEMP TABLE {}( - account_key CHAR(44), + account_key TEXT, slot BIGINT, is_write_locked BOOL, total_cu_requested BIGINT,