Question: I have database having hundreds of tables with relations. I want to look a db design for understanding tables relations in a single place. Any idea how I can do this?

Regards

Answer: 
If it is displaying a different hour you may need to set the default timezone after setting the dateFormat (this happens only after ios7)

```
[dateFormat setTimeZone:[NSTimeZone timeZoneWithAbbreviation:@"GMT"]];

```

it seems that the default timezone is the one the device has, so if you no specify the default timezone you might get strange results. Prior to ios7 it was always GMT.

**update:**

if the `NSDate` is nil after the formatting you should probably use:

```
[dateFormat setLocale:[[NSLocale alloc] initWithLocaleIdentifier:@"en_US_POSIX"]];

```

I had this issue with a Mexican iPhone, if you like your users to be happy with your app I strongly recommend always adding this code. I always use both code sniplets since IOS7
You need to check your "Date time format" set in iPhone Default Setting (Setting -> General -> Date and Time).

if in this setting time format is set as 24 hr then u will get time in 24 hr format. 

If it is set as 12 hr format then u will get 12 hr date time format.

I think in ur iPhone5 device date time setting is set as 12 Hr format