Implemented saving function, removed dep on $_, $0 il always used for db lookup