Some guy came to #postgresql today. Described his problem, got additional question, and then … well .. I wouldn't believe if it didn't happen to me.

Here is log of on channel conversation:

17:52 < loincloth> heyo
17:53 < loincloth> i am getting a syntax error for a pretty simple insert statement
17:53 < loincloth> it used to be a one line statement and i added some newlines for readability
17:53 < loincloth> but i guess that fails? how can i do a multi line statement for readability?
17:53 < depesz> loincloth: sure you can.
17:53 < davidfetter> it wasn't the newlines that caused the problem
17:54 < depesz> loincloth: we can't really help debug you the problem without seeing the query.
17:54 < loincloth> hmm
17:54 < loincloth> yup
17:54 < davidfetter> paste the query and the error you got to a paste site
17:54 < davidfetter> then paste the resulting url here :)
17:55 < loincloth> davidfetter: something like this http://pgsql.privatepaste.com/7ef97547f0

Apparently he (she?) left (I have join/part notices disabled, so I didn't see it).

Well. I assumed that perhaps he misunderstood what David said, and decided to talk in priv – after all – the guy still has problem with query. Here is log of conversation:

18:12 <depesz> why do you have problem when others try to help you?
18:12 <loincloth> lol
18:12 <loincloth> was that you i was talking to or are you just a concerned bystander?
18:12 <loincloth> i don't remember
18:13 <depesz> neither.
18:13 <loincloth> uhm
18:13 <loincloth> ok
18:13 <depesz> i don't understand the problem you're having with david help you.
18:13 <depesz> the query you showed clearly works without any problem.
18:13 <depesz> so the problem you had with other query is still unresolved.
18:13 <loincloth> not really
18:13 <depesz> what "not really"/
18:13 <loincloth> look, i know what my actual table name and values are
18:13 <depesz> sure, btu we don't.
18:13 <loincloth> and those details are none of your business or davids
18:14 <loincloth> and i know that the query, with those values
18:14 <loincloth> works in one line
18:14 <loincloth> doesn't with a newline
18:14 <loincloth> if you want to help me, you can trust that
18:14 <loincloth> if you can't trust that, then just bug off?
18:14 <loincloth> i don't care much either way
18:14 <loincloth> until you lecture me about irrelevant bullshit
18:14 <loincloth> k thx
18:14 <depesz> it is not a matter of multiline
18:14 <depesz> check this:
18:14 <depesz> http://pgsql.privatepaste.com/5c2e9328a4
18:14 <depesz> i created a table, and ran the query you shoewed
18:14 <depesz> it clearly works.
18:15 <depesz> so - whatever is the problem with your original query - it is not in the query you showed us.
18:15 <loincloth> yes well perhaps it is line ending style, i don't know
18:15 <loincloth> you are obsessed with correctness here
18:15 <loincloth> what's it to you if i take your help or not
18:15 <depesz> is there any particualr reason why you don't want to ashow us the query that has the problem?
18:15 <loincloth> it's a stupid battle to be fighting
18:15 <depesz> ok. let me state my point:
18:15 <loincloth> no
18:15 <loincloth> thx
18:15 <depesz> 1. you have a problem with a query.
18:15 <depesz> 2. i want to help.
18:15 <depesz> 3. for some reason you are doing everything not to allow us help you.
18:15 <loincloth> i'm too lazy to figure out how to block this conversation
18:16 <loincloth> so please just stop bothering me
18:16 <loincloth> thx
18:16 <depesz> have a nice life.
18:16 <loincloth> i will, thanks

17 comments

Hi Hubert,
I confess, once, I was also one of the help begging guys out there in IRC channel. I had a little argument with you due to my not noticing the channel rules about ‘how to post/paste’ to get help as needed. The details aside, that day, ‘comprehension’ of both sides was the key to solve the problem in a humanist way, which, the person of subject above in your post, seems lacking obviously.
Cheers

“Mental attitude is more important than mental capacity”
–Walter Dill Scott

What the hell? Someone wants help with a broken query and shows a non-broken query and seems upset when you want the actual query? Now if the person was able to replicate their problem with a different query and refused to show you the original, that would make sense (many businesses are quite strict about their intellectual property). Unfortunately, this exchange didn’t make a like of sense.

I appreciate everything you do to help people. Sorry you had to get a bad apple.

I appreciate all your help, especially on IRC! I hear so many stories from people at conferences where they had a real, urgent problem and the folks in #postgresql saved their bacon.

And re: directing jerks to other communities — it’s unacceptable to be an ass in any community. Better to simply say that rudeness isn’t ok here, and hopefully communicate that it shouldn’t be ok anywhere.

The people on #postgresql are the most helpful and polite people I have ever met. Even when people are being complete assholes you guys still try to help politely. Postrgres is an exemplary community that all other communities should strive to be like.

That’s incredibly rude, especially when you were willing to overlook his hostility and still offer to help him. If he’s so reluctant to clarify his problem and accept advise, he’s only preventing himself from finding the answer.

Thankfully such people are very few and far between in our community.

But to let you know, I looked at the IRC logs and he did leave after that last message.

There is no guarantee that the entity starting the conversation was the same entity ending it. Perhaps it was a they doing some agile programming. Or a shared computer used by one sibling for homework and another to chat with friends.

I do wonder if the pasted code returned the same error to loincloth as the original code. What interface was being used to do the insert? Perhaps the SQL was embedded, or there was a homebuilt Web interface.

Nevertheless, I am astounded by the generosity of the postgresql folk and continually surprised by the rudeness of the multitudes.

To play devil’s advocate, “loincloth” did give a clue but it got lost in the argument:

17:56 is the letter ‘f’ illegal where ‘a’ is not?

That is out of context with his original question but it was not followed up.

A more subtle clue is that he used double quotes in the column names, although they are not necessary, as if converting from another SQL dialect that uses backticks around identifiers.

I presume he was unwilling to provide the actual query because it had some information that was confidential or otherwise non-sharable. Insisting on seeing the “real query” made him defensive.

Possibly focusing on seeing the error or explaining *why* it may be necessary to see more of what he was entering and seeing, could have allayed his fears. For example, I caused the following error with his query:

ERROR: syntax error at or near “baz”
LINE 3: (3, ‘baz’);

That’s because I purposely didn’t enter the closing quote for the second tuple, second column (and I had to close everything off interactively). The point is that explaining that perhaps he was missing a closing quote or parens would have been more helpful.

I can make the query fail in at least couple of different ways – by changing it.

It is also possible that he is using pg < 8.2, which doesn't work with multiple values in insert.
Anyway - I can not guess what might be wrong with "similar" query, based on *another* query that does work.
And as for his "clue" - yes. There are ways there letter f is illegal, but a is not. There are also cases where a is illegal, where f is legal.