List:General Discussion« Previous MessageNext Message »
From:Jasper Bryant-Greene Date:August 31 2005 10:20am
Subject:Re: DIV-function?
View as plain text  
Joachim Klöfers wrote:
> Jasper Bryant-Greene schrieb:
> 
>> Gustav Wiberg wrote:
>>
>>> Hi there!
>>>
>>> I wonder how I'll get a div-function in SQL?
>>
>> I dunno, maybe by looking in the manual? From [1]:
>>
>> Division:
>>
>> mysql> SELECT 3/5;
>>         -> 0.60
>>
>> [1] http://dev.mysql.com/doc/mysql/en/arithmetic-functions.html
>>
> 
> Gustav is looking for the DIV-function.
> 
> But it is there
> 
> |DIV|
> 
> Integer division. Similar to |FLOOR()| but safe with |BIGINT| values.

He never said he wanted integer division... he just said "I want to 
divide t[w]o columns and make a new column based on the result."

-- 
Jasper Bryant-Greene
Freelance web developer
http://jasper.bryant-greene.name/

If you find my advice useful, please consider donating to a poor
student! You can choose whatever amount you think my advice was
worth to you. http://tinyurl.com/7oa5s
Thread
DIV-function?Gustav Wiberg30 Aug
  • Re: DIV-function?Jasper Bryant-Greene30 Aug
    • Re: DIV-function?Joachim Klöfers31 Aug
    • Re: DIV-function?Joachim Klöfers31 Aug
      • Re: DIV-function?Jasper Bryant-Greene31 Aug
  • Re: DIV-function?Martijn Tonies31 Aug
    • Re: DIV-function?Nuno Pereira1 Sep