There is no requirement of democratic theory that mandates that all public offices be filled by election. This is particularly true in modern democratic states, which are simply too large to justify the administrative burden of electing everyone who has significant responsibilities in our society.
Examples of this are everywhere in modern democracies, such as the United States and Europe. In England, for example, the Prime Minister is not directly elected by the people. Does this mean Great Britain has ceased to be a democracy? In most large, sophisticated nation-states, national cabinet officers have great power but are the political appointees of the chief executive. In many nations, these important decision makers are not even approved for office by the legislature. Is this still democracy? Of course it is, provided that the directly elected government leaders are faithfully discharging their duties. For example, in the United States, federal cabinet officers must first be nominated by a President who was elected (in most years by a majority of the people); he is not “directly” elected because of the Electoral College, yet we still regard this as democracy. And, of course, the President's nominee for a cabinet-level post must be confirmed by the U.S. Senate, a group that is elected by its constituents.
Thus, there are two democratic checks on the appointment of federal cabinet officers in the United States. Even in European or other nations lacking any requirement of legislative confirmation, the process is still essentially democratic; officials are selected by a chief executive who represents the popular majority (or at least a working majority coalition) as expressed at the polls in the last election.
Even for controversial selections of high government policy-making officials, the democratic connection is present and sufficient to guard democratic values. Take, as an example, our current Attorney General. John Ashcroft has been a relatively controversial figure. I readily admit to being no fan of Ashcroft. But it would be unfair of me to characterize his selection as illegitimate or undemocratic simply because he gained his position by appointment. The U.S. Attorney General is very much a product (albeit an indirect product) of democratic selection. Most voters in the 2000 election were quite aware that George Bush would choose an Attorney General like Ashcroft while Al Gore was more likely to choose someone like Janet Reno. Ironically, Ashcroft was available for the post of Attorney General because he had lost his bid for re-election to a U.S. Senate seat in Missouri. But, even if one regards the Ashcroft appointment as a product of a back-to-work program for losing GOP politicians, Ashcroft had to be nominated by a sitting President who was elected (however controversial that election may have been) and whose views on legal issues were quite clear. Thereafter, because of questions as to whether Ashcroft's legal and political views were too extreme, the Attorney General-designate received greater-than-normal scrutiny from the Senate than most nominees. After considerable debate, Ashcroft was confirmed. Although the vote was not nearly as strong as those attending most cabinet appointments, Ashcroft ascended to the Attorney General position fair-and-square according to both the ground-rules of U.S. politics and democratic theory.
4 Nev. L.J. 35 (2003).
Stempel, Jeffrey W., "Malignant Democracy: Core Fallacies Underlying Election of the Judiciary" (2003). Scholarly Works. Paper 226.