The article is correct in the first, but not in the second.
Student or Learner
Which one is correct? And should I use indefinite article a after at?
"Got this neat book at a gift exchange last night."
"Got this neat book at a last night's gift exchange."
To make your sentence grammatical, you need to add "I/he/she/you/we/they" at the beginning. It's not a complete sentence at the moment.
Remember - if you don't use correct capitalisation, punctuation and spacing, anything you write will be incorrect.