Decimal Separator

  • Chris after reading many of your post I would not have guessed that english was not your first language.

    Mike

  • DECLARE @1 float, @2 float, @DecTest float

    SET @1 = 1

    SET @2 = 2

    SET @DecTest = @1/@2

    SELECT Substring(CAST(@DecTest AS varchar),2,1) AS Separator

  • rich - the question was how to save values...

    chris - many moons ago i was in Sweden and i know they all speak excellent english - so pl. don't try and hide behind "English is not my first language" - you speak (type ?!) it much better than even the people who only speak English/American...

    btw:the only think i learnt from my Sweden trip was "jag talla inte svenska" (splng ??)







    **ASCII stupid question, get a stupid ANSI !!!**

  • Maybe but it's still a good idea .

  • what is a good idea remi ?!







    **ASCII stupid question, get a stupid ANSI !!!**

  • His solution to find out what the decimal separator was.

  • Oh, I was answering this question:

    "How can I get the decimal separtor from SQL Server?"

    I should have read on a bit further


    I would have thought that the safest thing to do would be to homogenise the number before talking to SQL Server.  Perhaps format numbers to a standard locale on the client before they reach the web server ?

    Or have I missed the point ?

  • Thanks all for your input. 

    The SQL Server respected the Regional Settings Decimal separator when I did my testing.  When I changed to period, I could enter the float values like 56.67 and it displayed the same, when I changed the separator to comma, I could enter the float values like 56,67 and it displayed the same.

  • btw:the only think i learnt from my Sweden trip was "jag talla inte svenska" (splng ??)

    Almost. "talla" should be "talar".

  • thx. chris - guess it wasn't typed correctly..







    **ASCII stupid question, get a stupid ANSI !!!**

  • Wohhh!!, nice setup .

  • thanks (I think) remi - not fair to use "setup" though...implies scheming and premeditation etc.. - none of which i'm guilty of...







    **ASCII stupid question, get a stupid ANSI !!!**

  • How do you call it when actors start using lines to be able to throw in a joke a few lines later???

  • hmm - maybe a "setup" would be ok in that context!!!

    when I asked Chris for the spelling I genuinely wasn't sure if I had it right or not - I didn't deliberately "misspell" so I could throw in a punchline..







    **ASCII stupid question, get a stupid ANSI !!!**

  • I'll withdraw my wohh!!! then. Still was a funny 15 minutes .

Viewing 15 posts - 16 through 30 (of 37 total)

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