Search code examples
avroavro-tools

Can I limit the number of rows read by avro-tools?


I am using avro-tools tojson file.avro to inspect a large Avro file. I am only interested in seeing a few examples, just to get a feeling for the data.

Is there an option for avro-tools tojson that limits the number of rows read?


Solution

  • Yes, there is an option for avro-tools tojson that limits the number of rows read:

    avro-tools tojson --head=<n> <filename>