How are comments linked to a specific post?

I use Ulysses to post to Ghost, and it has a handy feature that lets you update existing posts, which I need to do regularly.

I’ve just moved my site over from self-hosted to Ghost Pro, and doing so seems to have broken the updating process. Ulysses knows it’s updating, but when I try to, it says it can’t and will need to create a new post. This means deleting the old post first.

My main concern is that if the existing post has comments attached to it, will those commends be transferred over to a ‘new’ post with the same URL, or do they use a post ID, so will be lost forever?

I’m aware I could get around this by pasting text from Ulysses into the Ghost editor, but Ulysses is usually great at doing it in half the time.

What kind of comments? I’m guessing if you just moved to Ghost Pro and had your comments as native Ghost comments, then you lost them?

The native Ghost comments. I don’t currently have any, but going froward it would be good to know how they are attached to a post, so I know when to ‘manually’ update a post in teh Ghost editor vs updating from Ulysses.

Ahh, gotcha. Yeah, if you delete a post and recreate it, you’ll lose the comments, as they’re attached to the existing post. Posts actually have a field called comment_id, which is generally the same as the post_id, and which is used to attach comments to posts. If you import posts from elsewhere, the old post ID ends up in the comment_id field. [I think this was to support non-native comments, since there’s no route to get comments imported except a database dump & restore.]

You’re on Ghost Pro, so I’m not sure if that helps you (no way to directly manipulate the database), but it might be worth looking to see if you can get Ulysses to match posts based on that comment_id, which has not changed since you moved, rather than the post_id, which has. I’m guessing Ulysses is trying to use the old post_id, but that’s changed for your posts.

Ulysses is pretty popular, so hopefully someone here on the forum can help you with a solution.

Aside: Since you’re on Ghost Pro, you should also reach out to their support address. If imports are breaking Ulysses for their customers, they’ll want to know that!

Will do, thanks so much for the detailed reply.

I’ve already emailed Ulysses, so hopefully they’ll come back with something positive.

1 Like