I think you must first create sql database then attach user on it with permissions allow it to install your script.