Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> comp.databases.theory -> More pain and sufferring with Tropashko's materialized path...

More pain and sufferring with Tropashko's materialized path...

From: Robin Tucker <r.tucker_at_thermoteknix.com>
Date: Mon, 15 Sep 2003 19:06:00 +0100
Message-ID: <bk4v08$mek$1$8302bc10@news.demon.co.uk>

When I execute this function with a number such as 113755/65536, I get arithmetic overflow. When I convert them to "real", same problem. Everything is fine with smaller numbers, such as you get for the test cases given.

This problem has occurred on a test tree containing only 500 nodes that goes to a depth of 12. I thought I had this materialized path thing cracked, but it seems I haven't! (using MS T-SQL by the way, perhaps there is some other data-type I should be using?).

Any ideas?

ALTER FUNCTION dbo.func_Get_Child_Numerator  (

@numer INTEGER,
@child INTEGER

 )
RETURNS INTEGER
AS

    BEGIN
         RETURN @numer * POWER ( 2, @child ) + 3 - POWER ( 2, @child )     END Received on Mon Sep 15 2003 - 13:06:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US