Usage of seeds for posts and categories

There is a method error found but could not trace it out. Can someone help out with this error??

@Swathi_Kasikala can you please post one of the relevant statements from your seeds file? and also the db structure for the relevant table/s its a little hard to work trace anything without a little context

Thank you so much for your response and time. Here are the relevant files. Sorry for not sharing them earlier.

This is the seeds.rb file

And this is another

relevant file please go through and help me out to solve this issue. Thank you:)

Looking at the database scheme, I think you’re a few fields missing … where is the field that holds the category?

Sorry I didn’t understand what should I do??..basically I am a beginner so I will be thankful if you help me out with this.