Search code examples
orientdb

Returning the size of a record (in bytes) from OrientDB


OrientDB supports various methods to get the length of a collection or the length of a string, but I'm trying to determine the total size of a record in bytes. I can't find anything in the documentation or elsewhere that addresses this. Is it possible?


Solution

  • Answer from OrientDB's Luigi...

    Create a function called "recordSize" (or something) with one input param (in this case record): return record.getSize();

    Use it like this: select recordSize(@this) from...