Developers Forum for XinFin XDC Network

Discussion on: issue:arpc responses with a blockhash that doesnt exist.

Collapse
wjrjerome profile image
Blockchain Minions • Edited on

@xu_zhaolin_fcf881856ae0b5
I'm not too sure what you using this API for, hence I can only provide a suggestion based on the assumption that you trying to perform a data migration into a new table and index it for graphQl purpose.
You can still do that by making two API calls.

  • One to the getLogs where wrong blockHash is returned. (Use the result except the blockHash)
  • Another one to the getTransaction by supplying the tx hash you get from step 1. This shall give you the correct blockHash corresponding to the tx.

You can then combine the two data source into a single one and continue processing.