xsl Question

A

Analizer1

Hello again...
Im using XMl/xsl to generate text report from a service
getting data to xml from sqlserver 2005

xml generates ok
but when xslCompiledTransform runs
i get a StackoverflowException

i have 11,000 rows of data going through....is this just too much for Xsl

tks
 
M

Marc Gravell

C#?
i have 11,000 rows of data going through....is this just too much for Xsl

I shouldnt' have thought so. This probably points more to a bug in the
code. First test - does it work for smaller volumes? Next: are you
doing anything deeply recursive in the xsl? A typical thing to look
for would be templates that call each-other (possibly itself) -
typically passing arguments (xsl:param, xsl:with-param) to enumerate a
sequence.

Likewise, the same things are possibly if you using script inside the
xslt (although this is less common).

I've used xsl on some pretty large fragments without issue. The other
thing to watch is that the overall structure needs to be better... you
can't get away with much laziness (//Something, just to save typing
the path, etc) - and proper consideration of indexing (xsl:key,
Muenchean grouping, etc), variable usage, etc gets more important.

Marc
 
A

Analizer1

the xsl works just fine with smaller volumns...
i'll double check the xsl...
Im Pretty new to xsl

its a fairly simple report for users
Header,
1xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
2
3
4
---------------------------------------------------
ITem Totals Max Types about 20 lines totals each item
item type 1 total
item type 2 total
item type 3 total

Detail lines
//all the line items here 11000 of them
line 1
line 2
etc

tks
 
S

sloan

I would also take a working smaller set, and then COPY PASTE it alot of
times, to get back to up your large size.

That way, since you know the smaller set works, that copies of it should
work....and you can determine if its the size

OR

its a certain section of records that breaks it.

StackoverflowException could be bad math as well.
Do you have any math functions? (division?)
Multiplying to very large ints?

Something like that.


I would try to figure out whether its size or bad numbers first off.
 
A

Analizer1

sloan said:
I would also take a working smaller set, and then COPY PASTE it alot of
times, to get back to up your large size.

That way, since you know the smaller set works, that copies of it should
work....and you can determine if its the size

OR

its a certain section of records that breaks it.

StackoverflowException could be bad math as well.
Do you have any math functions? (division?)
Multiplying to very large ints?

Something like that.


I would try to figure out whether its size or bad numbers first off.
 
A

Analizer1

matter of fact...there is math going on
adding up totals and break down totals

your help is appriciated
 
M

Marc Gravell

Depending on how big it is, if you can post the file I can perhaps
look for anything obvious?

In particular the "totals" stuff - if you are doing this via recursion
there may be better approaches for xsl...

Marc
 
A

Analizer1

let me exaust all my testing....got a couple more tests left...
double checking all the data is correct, stored procs checking for nulls

take me about another hour....im hopful i can find data problems

tks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top