A district court ruled last week that a Tokyo metropolitan government order compelling teachers to stand up for Japan's flag and sing the anthem to the emperor violated the constitutional guarantee of freedom of thought.

The appeal calls on the high court to annul the ruling, a Tokyo education board official said on condition of anonymity.

Supporters of the flag and anthem argue that Japanese children need to learn national pride, but some teachers and other opponents say the ''Hinomaru'' flag and ''Kimigayo'' anthem are relics of Japan’s second world war militarism and should be replaced.

When Tokyo's Governor Shintaro Ishihara expressed his intention to appeal last week, he said compulsory observation of the anthem and flag was needed "to restore discipline and order" at schools.

Patriotism

The court decision was a rare victory for Japan's pacifists, whose influence is dwindling as the country takes a more assertive diplomatic and military stance.

Shinzo Abe, the newly installed prime minister, is trying to push through reforms to place a greater emphasis on patriotism in schools.

Dozens of teachers and their lawyers have urged Tokyo not to appeal and repeal the 2003 directive ordering teachers to honour the flag and anthem at school ceremonies.

There have been 345 cases of teachers being punished for not observing the directive, according to the Tokyo school board.