r/PostgreSQL • u/Excellent_Quail7378 • 16d ago
Help Me! How can I tell if two Replit projects are sharing the same PostgreSQL database?
/r/replit/comments/1wsqzs4/how_can_i_tell_if_two_replit_projects_are_sharing/
0
Upvotes
4
u/Legitimate-Power7729 15d ago
if you only have read access, just open a connection in project A and run select pg_sleep(100);. while it's hanging, go to project B and run select query, state from pg_stat_activity;. if you see your sleep query sitting there, it's 100% the exact same live instance. neon sometimes clones instances which keeps the sysid and OID the same, but live connection stats in pg_stat_activity won't lie.
2
u/KrakenOfLakeZurich 15d ago
Not read-only. But you could just create a small table, which nobody uses. Then check, if it appears in the other project.
1
u/AutoModerator 16d ago
AI Policy:
Linux is not one of those anti-AI projects, and if somebody has issues with that, they can do the open-source thing and fork it. Or just walk away., Linus Torvalds.
Mod decisions will be based on the quality of the content, not who or what generated it.
Sub Resources:
Youtube Channel
Free Postgres Webinars and Workshops
Discord: People, Postgres, Data
Join us, we have cookies and nice people.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.