Are the posted questions getting worse?

  • Lowell (2/15/2013)


    If i have to hit shift_alt+0831 or something every time i need a quote-type indicator, instead of a single key stroke, that'd get old real fast.

    This made me smile. Hey Stefan, you should suggest an alternative on Connect. If nothing else, you might set a new record for time from submission to "Won't Fix" :laugh:

  • L' Eomot Inversé (2/15/2013)


    Stefan Krzywicki (2/15/2013)


    I should think we could either have keyboards with that symbol on it or use one of the other keys instead of shift. Alt+1 or Ctrl+1 should do fine.

    Well, Ctrl+1 is already assigned a specific meaning by default in SSMS, so that wouldn't do. Maybe Alt+1 would be OK.

    They added a windows or apple key to most keyboards these days, so they can certainly add something like that. Heck, there's even space! They could use half the space of Backspace or the | \ key. Make the right Shift key a little smaller and put it in there and there's room for 2 new characters.

    No, don't use the |\ key - I (and many others who type in computer languages other than SQL) use those symbols quite a lot. Half the space of backspace or cutting the size of rhe right Shift key is going to screw up people's touch typing. Maybe part of the Enter key could go - probably alright for me as I think I always hit the bit of it on the asdfg row but might be bad news for other people. Do most keyboards have two unused slots either side of the up key - if so, maybe those spaces could be used?

    But keyboard space is a tiny part of the problem; presumably you want to be able to put it in a string and it needs to be an 8-bit character. Where are you going to put it in which code pages? Presumably you require a change to the unicode standard so that it is assigned an 8-bit value in the unicode variants where there are single byte characters? This sort of stuff can take a very long time to get through standards bodies.

    I didn't mean replacing the | \ key, I meant take half the space allotted. Mine is rather larger than the other character keys.

    It does take a very long time for that kind of thing to happen, but we've already wasted what, 30+ years on not doing it? Lets get started!

    --------------------------------------
    When you encounter a problem, if the solution isn't readily evident go back to the start and check your assumptions.
    --------------------------------------
    It’s unpleasantly like being drunk.
    What’s so unpleasant about being drunk?
    You ask a glass of water. -- Douglas Adams

  • Paul White (2/15/2013)


    Lowell (2/15/2013)


    If i have to hit shift_alt+0831 or something every time i need a quote-type indicator, instead of a single key stroke, that'd get old real fast.

    This made me smile. Hey Stefan, you should suggest an alternative on Connect. If nothing else, you might set a new record for time from submission to "Won't Fix" :laugh:

    I wouldn't be surprised if it is already listed as "won't fix" just because of this conversation. 🙂

    --------------------------------------
    When you encounter a problem, if the solution isn't readily evident go back to the start and check your assumptions.
    --------------------------------------
    It’s unpleasantly like being drunk.
    What’s so unpleasant about being drunk?
    You ask a glass of water. -- Douglas Adams

  • Stefan Krzywicki (2/15/2013)


    I didn't mean replacing the | \ key, I meant take half the space allotted. Mine is rather larger than the other character keys.

    On my keyboard it's the same size as everything else.

    Actually, I think that for me Ctrl+Shft+2 would maybe be a good choice for keying it - after all, I type Ctrl+Shft+6, Ctrl+Shft+;, Ctrl+Shft+' and Ctrl+Shft+# pretty often (for assorted non-spacing diacritics) so another Ctrl+Shft+something wouldn't be a problem. However, others may not like Ctrl+Shft combinations (other things I use regularly like Ctrl+' and Ctrl+` are less effort because there's no Shft, but I'm not sure what's free amongst those two key combinations - or even amongst the three key combinations for that matter).

    Tom

  • Stefan Krzywicki (2/15/2013)


    So here's an idle question that no-one will see because it is right before the weekend.

    Apostrophes are fairly common in names. Why do we still use ' as a text indicator in databases? Why haven't we (meaning people who design systems) created a unique symbol that we can place at either end of a text string?

    SET QUOTED_IDENTIFIER OFF and use double quotation marks 😉

    Far away is close at hand in the images of elsewhere.
    Anon.

  • David Burrows (2/18/2013)


    Stefan Krzywicki (2/15/2013)


    So here's an idle question that no-one will see because it is right before the weekend.

    Apostrophes are fairly common in names. Why do we still use ' as a text indicator in databases? Why haven't we (meaning people who design systems) created a unique symbol that we can place at either end of a text string?

    SET QUOTED_IDENTIFIER OFF and use double quotation marks 😉

    And then we have the same problem with double quotation marks inside the text; OK, they aren't used in Irish surnames or English possessives, but they are used for quoted speech so on the whole they end up just as common in text as the apostrophe. Substituting some other symbol, if it is to reduce the pain of having to escape, requires a synmbol to be chosen that is significantly less frequently occurring than the symbol we started with.

    Perhaps the best thing would be arranging for ad-hoc delimeter substitution, which requires a small change in syntax for string, something like \g'''''''''''''''''''''''''''g to denote a string of 27 single quotes where \ introduces the delimiter character for cases where ' (and " with quoted_identifier off) is not to be the delimiter. That's something that could be added to the language as an extra feature without lots of expensive keyboard redesign, breaks no existing code, and only needs standard body involvement (and all the delays that entails) if it is decided that it's needed as a standard feature of the SQL language - which I imagine would be better argued after its introduction as a non-standard feature than before, so perhaps there wouldn't be a long wait for implementation even if standardisation was wanted.

    Tom

  • L' Eomot Inversé (2/18/2013)


    And then we have the same problem with double quotation marks inside the text;

    Thanks Tom, I thought of that as well and I intended my post to be tongue in cheek, oh well :(.

    As already stated before any character used could be a problem as it could also be part of the data.

    I like the idea of an ad-hoc delimeter.

    Or maybe having a SET option to specify it.

    There is always the option of using QUOTENAME :w00t:

    Far away is close at hand in the images of elsewhere.
    Anon.

  • David Burrows (2/18/2013)


    L' Eomot Inversé (2/18/2013)


    And then we have the same problem with double quotation marks inside the text;

    Thanks Tom, I thought of that as well and I intended my post to be tongue in cheek, oh well :(.

    I wasn't sure whether it was TiC or serious.

    As already stated before any character used could be a problem as it could also be part of the data.

    I like the idea of an ad-hoc delimeter.

    Or maybe having a SET option to specify it.

    SET would be a pain in the butt for this: suppose your varchar string needs to contain all 256 distinct 8-bit characters, with a delimeter specified as part of the constant you can split it into chunks and use + to join them together, with SET you would have to declare variables and concatenate them; so the variable delimiter as part of the expression, albeit something of a mess in the nastiest case, is less pain than using SET which in turn is less pain than using teh current system.

    There is always the option of using QUOTENAME :w00t:

    I agree with your " :w00t: ". 😀

    QUOTENAME doesn't work for 129 character strings (or anything longer), and anyway needs the argument to be a sting already so you can't use it to solve the problem unless you've already solved the problem without it. Or could we (a) define a topology on the universe of string expressions in such a way that an infinite sequence of incomplete string expressions each using QUOTENAME to try to refine its predecessor would have a single limit point which would be the right string and (b) define some finite notation to designate such a sequence - if we could achieve that (which I doubt) we would only have to fix the 128 character limit. Oh, and of course make it work for char and varchar as well as for nchar and nvarchar, so it wouldn't actually be QUOTENAME as char is forbidden there. :hehe:

    Tom

  • Dibs on the patent for the "DBA Keyboard". The new key will be placed perfectly for whipping forward and whacking your head against the keyboard. 2nd edition will be configured for those who prefer to invert the motion and whack the keyboard against their head because of back problems from using the 1st edition. Each purchase includes a free ibuprofen dispenser that attaches to fuzzy cube walls and auto-dispenses a pill at a "whack" sound (upgraded IV version also available, just pay additional shipping and handling at twice the cost of the product. Call now!). 😀

    Chad

  • Chad Crawford (2/18/2013)


    Dibs on the patent for the "DBA Keyboard". The new key will be placed perfectly for whipping forward and whacking your head against the keyboard. 2nd edition will be configured for those who prefer to invert the motion and whack the keyboard against their head because of back problems from using the 1st edition. Each purchase includes a free ibuprofen dispenser that attaches to fuzzy cube walls and auto-dispenses a pill at a "whack" sound (upgraded IV version also available, just pay additional shipping and handling at twice the cost of the product. Call now!). 😀

    Chad

    Don't forget to have a version of the dispenser that attaches to sensible walls or to desktops instead of to fuzzy cubicle walls if you want to get any market volume in civilised countries as well as in N America.

    Tom

  • Really? Answer to what?

  • Lynn Pettis (2/18/2013)


    Really? Answer to what?

    It is a koan, "What is the look of an empty string, centered?"

  • Lynn Pettis (2/18/2013)


    Really? Answer to what?

    Thanks ... I needed a laugh today

    If everything seems to be going well, you have obviously overlooked something.

    Ron

    Please help us, help you -before posting a question please read[/url]
    Before posting a performance problem please read[/url]

  • Lynn Pettis (2/18/2013)


    Really? Answer to what?

    I voted!

    Jason Wolfkill

  • L' Eomot Inversé (2/18/2013)


    David Burrows (2/18/2013)


    L' Eomot Inversé (2/18/2013)


    And then we have the same problem with double quotation marks inside the text;

    Thanks Tom, I thought of that as well and I intended my post to be tongue in cheek, oh well :(.

    I wasn't sure whether it was TiC or serious.

    As already stated before any character used could be a problem as it could also be part of the data.

    I like the idea of an ad-hoc delimeter.

    Or maybe having a SET option to specify it.

    SET would be a pain in the butt for this: suppose your varchar string needs to contain all 256 distinct 8-bit characters, with a delimeter specified as part of the constant you can split it into chunks and use + to join them together, with SET you would have to declare variables and concatenate them; so the variable delimiter as part of the expression, albeit something of a mess in the nastiest case, is less pain than using SET which in turn is less pain than using teh current system.

    There is always the option of using QUOTENAME :w00t:

    I agree with your " :w00t: ". 😀

    QUOTENAME doesn't work for 129 character strings (or anything longer), and anyway needs the argument to be a sting already so you can't use it to solve the problem unless you've already solved the problem without it. Or could we (a) define a topology on the universe of string expressions in such a way that an infinite sequence of incomplete string expressions each using QUOTENAME to try to refine its predecessor would have a single limit point which would be the right string and (b) define some finite notation to designate such a sequence - if we could achieve that (which I doubt) we would only have to fix the 128 character limit. Oh, and of course make it work for char and varchar as well as for nchar and nvarchar, so it wouldn't actually be QUOTENAME as char is forbidden there. :hehe:

    Nice reply Tom 🙂

    Regarding SET I was referring to it's use in setting an option such as SET QUOTED_IDENTIFIER OFF

    Like SET STRING_DELIMETER '\'

    rather than repeating it ad-hoc

    This still requires that the delimeter (or escape sequence) is not present in the data which is the crux of the problem.

    Far away is close at hand in the images of elsewhere.
    Anon.

Viewing 15 posts - 38,971 through 38,985 (of 66,712 total)

You must be logged in to reply to this topic. Login to reply