Changed some names so that they are consistent id, streamid -> stream_id