10

The Stack Exchange Data Explorer lets you write SQL queries to find questions, answers, comments, users etc across the StackExchange network, but the query interface throws an error if I try to select Psychology & Neuroscience as the target site.

dropdown lets me select ...

The problem seems to be the ampersand in the site's name; all the other sites with ampersands (Unix & Linux, Science Fiction & Fantasy, English Language & Usage, etc) have it replaced with "and" in the site dropdown.

... but I get a screenful of error messages

URL: https://data.stackexchange.com/psychology%20&%20neuroscience/query/1677462/common-typos-lite-newest

Thanks to the friendly people on the site meta, I was given a workaround (you can replace the site name with cogsci in the erroneous URL) but they suggested I report the fundamental problem here instead. Ref: How do I run a SEDE query for this site?

6
  • 2
    That's a bug in SEDE, causing a site name to generate 500 server error, tagged according to this now. :) Commented Feb 15, 2023 at 14:30
  • Same bug that was "fixed" by replacing "&" with the word "and". Sadly enough, Nick is long gone, and there's nobody to push SEDE changes, so this one is unlikely to get fixed. Commented Feb 15, 2023 at 14:35
  • 1
    @ShadowWizardChasingStars I got a change merged 6-8 months ago, so there's still hope ...
    – Glorfindel Mod
    Commented Feb 15, 2023 at 14:41
  • Brrrrr, pending PRs from 2020 github.com/StackExchange/StackExchange.DataExplorer/pulls ... but actually one was merged only a month ago.
    – tripleee
    Commented Feb 15, 2023 at 14:45
  • 1
    The required change is somewhat more involved because it's not enough to replace the ampersand with "and"; data.stackexchange.com/psychology%20and%20neuroscience/query/… does not work either. The site was renamed so the new name needs to be mapped to the original name somehow. I looked at the old PR but it didn't seem to directly touch these mappings.
    – tripleee
    Commented Feb 15, 2023 at 14:56
  • heh that's weird. But essentially it's SEDE "fault", its base design is just bad if ampersand crash it like that. Ideally someone will go and fix it so that it can handle it without crashing, thus saving future bugs whenever SE will have another site with ampersand in its name. Commented Feb 15, 2023 at 15:06

1 Answer 1

3

This should now be fixed. We've updated the data directly to replace & with and in the site's Name and LongName values.

4
  • Won't it be overriden in the next update, or cause other bugs as the actual site name has "&"? Commented May 24, 2023 at 7:02
  • 1
    The name exposed to SEDE is independent of the name of the site itself (that’s where it originally comes from, but it is not kept in sync). This is how other sites such as Unix & Linux, etc. already appear in SEDE, as noted in the question.
    – V2Blast Staff
    Commented May 24, 2023 at 15:24
  • why not keep them in sync?
    – Ooker
    Commented Jun 12, 2023 at 4:30
  • 2
    @Ooker Because they really don't change very often, if ever; Data Explorer is not even "connected" to the main sites in any active/permanent way; and, because keeping & would require changes to established parts of the codebase that we're not currently working on and that weren't written with the forethought that we'd later add sites with & in the name.
    – Aaron Bertrand Staff
    Commented Feb 25 at 15:31

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .