creating data access layer