What is meta? ×
Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 122 Stack Exchange communities.

I read that fullstops are encoded as aspûnet on SQLServerPEdia:

StackOverflow limits you to five tags per question (answers aren't tagged), and all five are stored in this field. For example, for question 305223, the Tags field is "<offtopic><fun><not-programming-related><jon-skeet>" [...] StackOverflow allows periods in the tag, like the .NET tag and ASP.NET tag. However, in the database, these are stored as "aspûnet". Just something to be aware of.

So:

  • What functional benefits does encoding fullstops as aspûnet yield?
  • Also, what functional benefits does surrounding a tag with <> yield?
share|improve this question
    
Hmmm, wondering if the û is not some encoding problem with that very website? It also has an issue with space in "Stack Overflow". ;-) –  Arjan Dec 23 '10 at 14:36
    
Perhaps this question should be migrated to SO? It's really a programming question that the subject matter of which is related to SO; but it can be for any other app. –  Mohamad Dec 23 '10 at 14:48
    
(@Mel, there's no migration path from MSO to other sites.) –  Arjan Dec 23 '10 at 14:56
    
@Arjan: a '.' is encoded the same way in virtually all encodings in the world, so no. –  Andreas Bonini Dec 23 '10 at 20:52
    
@Kop, I was thinking about the dot being replaced by some other character or sequence, that somehow erroneously displayed as û on the site. Like a Unicode û is 0xC3BB in UTF-8. Hence, if the dot would have been encoded as 8-bit ASCII û then erroneously assuming UTF-8 would get one to see the û. Of course, encoding the dot as 8-bit ASCII û makes no sense at all, but there's many other options, especially when there's multiple erroneous encodings/decodings. Anyway, the dot does not seem to be encoded at all. Or: not anymore? –  Arjan Dec 23 '10 at 21:40
    
(In 8-bit ASCII, û is 0xFB, or 11111011.) –  Arjan Dec 23 '10 at 21:42
add comment

1 Answer

up vote 2 down vote accepted

I don't think the encoding of the dot is used (anymore):

select Tags
from Posts
where Id = 3397235;​

tags                
------------------- 
<c#><.net><asp.net> 

And using <...> seems just some random way to ensure one can keep the tags apart using some characters that will not appear in any tag itself? Just guessing though. Also, using a separator rather than both some prefix and suffix, makes queries such as where Tags like '%<.net>%' a bit harder. But then I don't know if such ill-performing queries would be used.

share|improve this answer
    
Would it not make sense to use a coma delimited list to separate the tags? –  Mohamad Dec 23 '10 at 14:58
    
I guess one might not have expected a dot or hash in the tags either, when designing the database. Hence: can one be sure the comma is never used in a future tag? (Just guessing.) –  Arjan Dec 23 '10 at 14:59
    
Also, a delimiter is harder in like queries. See my edit, @Mel. –  Arjan Dec 23 '10 at 15:22
    
I believe the tags field is full-text indexed. –  Jon Seigel Dec 23 '10 at 18:25
add comment

You must log in to answer this question.

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