more logging, bug fixes: int conversion, table order