change txin script_sig from varchar to bytea for postgres

some script_sigs are too long for postgres' default 255 varchar
sqlite doesn't seem to care
skip consistency check if count of blocks to check is <= 0
Implemented method to retrieve idx based on tx hash