core crud functions working (mostly)