June 17, 2009 at 6:17 am
Hugo Kornelis (6/17/2009)
If forced to make an assumption (which, outside of this QotD setting, should never be the case), I would prefer the option that might be slower and might waste space but that is definitely correct over the option that's faster and leaner but might cause bugs.
Yes, it would be a personal choice. Both are 'correct' from different points of view of course.
My choice would differ from yours, but neither of us deserve any free pig-based products solely on that basis.
Paul
Paul White
SQLPerformance.com
SQLkiwi blog
@SQL_Kiwi
June 17, 2009 at 6:23 am
I think this QoD has been discussed enough, dont you agree! We all have different views on this case and let us leave it this way. The poor author of this is tormented enough with 14 pages of angry posts, because you lost 1 point.
The lesson of this QoD is, be very clear about what you ask for, and in the real world, be very clear about what the requirements are.
Please leave it, my mailbox is flooded with notifications from this matter and now i will unsubsribe to this forum.
Regards
/Hรฅkan Winther
"signing of this discussion"
/Hรฅkan Winther
MCITP:Database Developer 2008
MCTS: SQL Server 2008, Implementation and Maintenance
MCSE: Data Platform
June 17, 2009 at 6:25 am
hakan.winther (6/17/2009)
Please leave it, my mailbox is flooded with notifications from this matter and now i will unsubsribe to this forum.
I wonder if you were quick enough to avoid the notification for this post? ๐ ๐
Paul White
SQLPerformance.com
SQLkiwi blog
@SQL_Kiwi
June 17, 2009 at 6:28 am
It's not just one point or two extra bytes anymore!
It goes way beyond, if only I knew where it would take us...
June 17, 2009 at 6:28 am
Surely char(1) because already said that no space or null value is there.
June 17, 2009 at 6:30 am
There is a difference of losing a point fairly and squarely and being denied a point through an incorrect answer to a question.
The author deserves more than 14 pages of complaints not because of the difficult choice between CHAR and NCHAR which have divided the community, but because the whole community believes that the author was wrong to think VARCHAR(1) was a correct answer
The author needs to get back to basics and drum up on their bog standard data types (and I'm not including the fancy new types like the spacial ones either)
An apology wouldn't go amiss either.
June 17, 2009 at 6:30 am
surely char(1) because already said that it doesn't contain space or null value.
June 17, 2009 at 6:36 am
hakan.winther (6/17/2009)
I think this QoD has been discussed enough, dont you agree! We all have different views on this case and let us leave it this way. The poor author of this is tormented enough with 14 pages of angry posts, because you lost 1 point.
It's not about pioints, it's about learning things.
I was kind of hoping the poor author would have been on to reply to some of the points raised by now (maybe they have, it's easy to miss in 15 opages of posts!)
If not the author, then maybe Steve...
June 17, 2009 at 6:39 am
There is a risk of taking this too seriously you know...
Most of the recent QODs seem to have been posted by the author of this, and from memory, they were fine. Apologies are hardly necessary.
It might pay those bemoaning the quality of the question to submit a better one...?
๐
Paul White
SQLPerformance.com
SQLkiwi blog
@SQL_Kiwi
June 17, 2009 at 6:48 am
Paul White (6/17/2009)
It might pay those bemoaning the quality of the question to submit a better one...?
Ooh theres a challenge... Where do we send them? ๐
June 17, 2009 at 6:48 am
Thank you for all this wonderful information!
I apologise for such a sloppy question. The thing I wanted to mainly emphasise with this question was that "correct datatypes be chosen so as to optimally utilize the space".
I request the editor to change the answer options and the explanation as mentioned by Hugo!
Thanks,
VM
June 17, 2009 at 6:48 am
Hugo Kornelis (6/17/2009)
David Burrows (6/17/2009)
But those advocating nchar are also making an assumption :blink:Anyone using nchar on an assumption deserves Pork Chops thrown at them in my view :w00t:
Hi David,
If forced to make an assumption (which, outside of this QotD setting, should never be the case), I would prefer the option that might be slower and might waste space but that is definitely correct over the option that's faster and leaner but might cause bugs.
If that nets me some tossed meat, then so be it. :kiss:
I would never try that to a person of your high standing Hugo :blush:
When I first read the replies I decided that either char or nchar could be the right answer and as already stated by many, without exact requirements to the content of the column the answer will always be ambiguous.
I have a table with 7,285,377 rows containing two char(1) columns. If it was created using nchar what a lot of wasted space but then we knew what the content would be in advance ๐
So I consider the char/nchar debate to be one of those 'It Depends' things. :w00t:
Far away is close at hand in the images of elsewhere.
Anon.
June 17, 2009 at 6:51 am
Toreador (6/17/2009)
hakan.winther (6/17/2009)
I think this QoD has been discussed enough, dont you agree! We all have different views on this case and let us leave it this way. The poor author of this is tormented enough with 14 pages of angry posts, because you lost 1 point.It's not about pioints, it's about learning things.
I was kind of hoping the poor author would have been on to reply to some of the points raised by now (maybe they have, it's easy to miss in 15 opages of posts!)
If not the author, then maybe Steve...
But why bother? I guess he will learn something, but the important thing is that you are doing the right decision when you need to.
I dont think anyone dares to add a QoD if we all are so judging and angry!
/Hรฅkan
/Hรฅkan Winther
MCITP:Database Developer 2008
MCTS: SQL Server 2008, Implementation and Maintenance
MCSE: Data Platform
June 17, 2009 at 6:52 am
Paul White (6/17/2009)
There is a risk of taking this too seriously you know...Most of the recent QODs seem to have been posted by the author of this, and from memory, they were fine. Apologies are hardly necessary.
It might pay those bemoaning the quality of the question to submit a better one...?
๐
Right with you on that Paul ๐
Far away is close at hand in the images of elsewhere.
Anon.
June 17, 2009 at 6:55 am
VM (6/17/2009)
Thank you for all this wonderful information!I apologise for such a sloppy question. The thing I wanted to mainly emphasise with this question was that "correct datatypes be chosen so as to optimally utilize the space".
I request the editor to change the answer options and the explanation as mentioned by Hugo!
Thanks,
VM
I don't think it was sloppy at all.
Don't be put off by the bemoaning of the few. ๐
Some QOTD have suffered with the answers but I think that if they are corrected/enhanced then all for the good, they stir up a good debate. We are all here the learn (well I am anyway).
Far away is close at hand in the images of elsewhere.
Anon.
Viewing 15 posts - 136 through 150 (of 182 total)
You must be logged in to reply to this topic. Login to reply