For some reason my brain tells me that the following sentence is grammatically correct...
Thanks, John. Your gift was much appreciated.
Instead of...
Thanks John, your gift was much appreciated.
Which should I use?
For some reason my brain tells me that the following sentence is grammatically correct...
Thanks, John. Your gift was much appreciated.
Instead of...
Thanks John, your gift was much appreciated.
Which should I use?
John in your sentence is a noun in the vocative case (the case used for the noun identifying the person, animal, object, etc. being addressed) which should be separated with comma(s) regardless of its position in the sentence. Though modern English lacks a formal (morphological) vocative case, I use it only to accurately identify the nouns in this category.
Thanks, John, your gift was much appreciated.
John, come here!
Thank you, John!
When you address someone like this, it is usual in writing to set off the name with a comma, or a pair of commas if appropriate. This is a matter not of grammar, but of punctuation.
Both of the original poster's examples are grammatically correct. They are pronounced slightly differently: There is a distinct pause for breath after the period, and less of a pause after the comma. The original poster should use the punctuation that matches his pronunciation.
When writing a letter, it is traditional to use a comma (or maybe a colon) after the salutation. (There is a distinct pause for breath after the salutation.) For example:
Dear John,
Your gift was much appreciated.