SALT LAKE CITY — A federal judge is ordering Utah officials to let the U.S. Drug Enforcement Administration search a state prescription-drug database without a warrant despite arguments about medical patient privacy.

U.S. District Judge David Nuffer on Thursday gave the Utah Department of Commerce and the Utah Division of Occupational and Professional Licensing three weeks to comply with a DEA subpoena or be held in contempt of court.

The federal agency says the records can be an important tool in early stages of an investigation.

The American Civil Liberties Union and Utah agencies argue that investigators should have to get a warrant to review records of prescriptions written for medications like Xanax, Ambien and opioid painkillers.

Almost all states maintain similar databases.

Utah is among a minority where state law requires a warrant.