Completed transition to SQL