This question already has an answer here:
I downloaded and installed Bitcoin-Qt 0.8.6, fully synced the block chain (according to the software itself) and now trying some basic commands through the console.
For some reason,
getreceivedbyaddress <address> always returns zero, even for addresses that I know contain some bitcoins.
getreceivedbyaddress 1Dorian4RoXcnBv9hnQ4Y2C1an6NJ4UrjX gives 0.00000000 (mini-screenshot), yet we can all verify that this address actually did receive bitcoins (see comment).
Restarted the software several times, restarted my PC, and also tried doing this from the command line using bitcoind instead of the Bitcoin-Qt user interface, still the same result.
Am I doing something wrong or misunderstanding Bitcoin-Qt?