Monday, May 22, 2006

Strange Crystal Report Problem

I've seem crazy strange problem in all sort of development tools, but to me this one is a bit too strange.

It started a week ago when the user of our system started to report problem of generating .csv file from our Crystal Report Queue engine (a .Net based application, but I have a very strong feeling that the Crystal Report component that the Queue engine called is actually a COM component). It returns the following error:


-------------------------------------------------------------------
Program starts at time: 22/05/2006 下午 02:59:44
Starting: Report Queue ID= 1310, Report ID= RF3502
CrystalDecisions.CrystalReports.Engine.FormulaException: A number field or currency amount field is required here.
Details: errorKind
Error in File C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\3\{1C97FE58-5BC0-4635-8208-08399CF0C2F7}.rpt:
Error in formula .
'Sum({@UNIT_PRICE_SA})'
A number field or currency amount field is required here.
Details: errorKind ---> System.Runtime.InteropServices.COMException (0x80041019): A number field or currency amount field is required here.
Details: errorKind
Error in File C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\3\{1C97FE58-5BC0-4635-8208-08399CF0C2F7}.rpt:
Error in formula .
'Sum({@UNIT_PRICE_SA})'
A number field or currency amount field is required here.
Details: errorKind
at CrystalDecisions.ReportAppServer.Controllers.ReportSourceClass.Export(ExportOptions pExportOptions, RequestContext pRequestContext)
at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
--- 內部例外堆疊追蹤的結尾 ---
at CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e)
at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
at CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext)
at CrystalDecisions.CrystalReports.Engine.FormatEngine.Export(ExportRequestContext reqContext)
at CrystalDecisions.CrystalReports.Engine.FormatEngine.Export()
at CrystalDecisions.CrystalReports.Engine.ReportDocument.Export()
at ReportQueueHandler.ReportClass.genRpt() in ReportQueueHandler.vb:line 1275
Oracle.DataAccess.Client.OracleException ORA-00942: 表格或視觀表不存在 at Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object src, String procedure)
at Oracle.DataAccess.Client.OracleCommand.ExecuteNonQuery()
at Oracle.DataAccess.Client.OracleCommand.ExecuteNonQuery()
at ReportQueueHandler.ReportClass.BackToPending() in ReportQueueHandler.vb:line 1342
Program ends at 22/05/2006 下午 02:59:47
-------------------------------------------------------------------

In fact, sometimes the .csv export can actually crash the Report Queue, and suck up at most 900Mb of memory. And I was like, "what the hell is that".

After looking up and down, I finally found out the reason, which I think is more of a Crystal Report bug since the problem only occurs when user generate .csv file. PDF report was generated properly.

The problem is this: if a report contains any Number field that has script entered in the "Disply String" script box (brought up by right click on the field and select "Format Field ..."), the .csv generation will fail.

My solution is to stop using the "Disply String" script box to format a field. Instead I create another Formula field with String type, and then reference the original Number field in the formula script.

That works very well.

24 Comments:

At 7:20 PM, Anonymous Anonymous said...

Hey,

When ever I surf on web I never forget to visit this website[url=http://www.weightrapidloss.com/lose-10-pounds-in-2-weeks-quick-weight-loss-tips].[/url]Lots of good information here sodev.blogspot.com. I am sure due to busy scedules we really do not get time to care about our health. Are you really serious about your weight?. Research points that almost 70% of all USA grownups are either chubby or weighty[url=http://www.weightrapidloss.com/lose-10-pounds-in-2-weeks-quick-weight-loss-tips].[/url] Therefore if you're one of these people, you're not alone. In fact, most of us need to lose a few pounds once in a while to get sexy and perfect six pack abs. Now next question is how you can achive quick weight loss? Quick weight loss can be achived with little effort. Some improvement in of daily activity can help us in losing weight quickly.

About me: I am writer of [url=http://www.weightrapidloss.com/lose-10-pounds-in-2-weeks-quick-weight-loss-tips]Quick weight loss tips[/url]. I am also mentor who can help you lose weight quickly. If you do not want to go under difficult training program than you may also try [url=http://www.weightrapidloss.com/acai-berry-for-quick-weight-loss]Acai Berry[/url] or [url=http://www.weightrapidloss.com/colon-cleanse-for-weight-loss]Colon Cleansing[/url] for fast weight loss.

 
At 6:12 AM, Anonymous Anonymous said...

this is anonymous again, ive gained 40 pounds on this new diet, i am so going to die of a stroke cause im so fat. Yeah this weightrapidloss website is a scam they just want your money the same way they took my money, im such a dumb@$$.

 
At 6:14 AM, Anonymous Anonymous said...

Hi everyone, it's my first pay a visit at this website, and piece of writing is truly fruitful in favor of me, keep up posting such articles or reviews.
Feel free to surf my web site :: weight loss

 
At 8:33 AM, Anonymous Anonymous said...

Very energetic article, I enjoyed that bit. Will there be a part 2?


Stop by my homepage exercises for vertical

 
At 5:47 PM, Anonymous Anonymous said...

Hi there, all the time i used to check blog posts here early
in the dawn, because i love to find out more and more.


Also visit my blog post ... exercises to improve vertical leap

 
At 10:03 AM, Anonymous Anonymous said...

Very energetic article, I enjoyed that a lot. Will there be a part 2?
ageless male - ageless male - does buy ageless male work

my site: ageless male testosterone

 
At 7:32 PM, Anonymous Anonymous said...

Heya i am for the first time here. I came across this board and I to find It truly helpful &
it helped me out much. I am hoping to present something
again and aid others such as you helped me.

My web-site; alcohol treatment facilities

 
At 11:21 PM, Anonymous Anonymous said...

Wonderful, what a webpage it is! This web site provides helpful facts to us, keep
it up.

my web blog; exercises to improve vertical

 
At 8:19 AM, Anonymous Anonymous said...

Hello everybody, here every one is sharing these kinds of knowledge,
therefore it's pleasant to read this weblog, and I used to pay a quick visit this webpage everyday.

Also visit my web-site; exercises to increase vertical leap

 
At 2:56 PM, Anonymous Anonymous said...

Appreciating the commitment you put into your website
and detailed information you offer. It's awesome to come across a blog every once in a while that isn't
the same unwanted rehashed material. Wonderful read! I've saved your site and I'm adding your RSS feeds to my Google account.



my web site - exercises sacroiliac joint pain

 
At 4:46 PM, Anonymous Anonymous said...

Remarkable! Its genuinely remarkable article, I have got much clear idea concerning from
this paragraph.

Feel free to visit my page :: http://postlaurea.altervista.org/

 
At 2:03 PM, Anonymous Anonymous said...

This is very fascinating, You're an excessively skilled blogger. I have joined your feed and look ahead to looking for more of your great post. Also, I've shared
your website in my social networks

Also visit my webpage :: workouts to improve vertical

 
At 7:06 PM, Anonymous Anonymous said...

This article will assist the internet visitors for building up new weblog or even
a weblog from start to end.

Feel free to surf to my web blog - exercises to improve vertical

 
At 4:45 AM, Anonymous Anonymous said...

I am regular visitor, how are you everybody?
This post posted at this website is truly fastidious.

Look into my blog - exercises to improve vertical

 
At 7:42 PM, Anonymous Anonymous said...

Thank you for every other magnificent post. The place else may just anyone get
that kind of information in such a perfect manner of writing?

I've a presentation next week, and I am on the search for such info.

Here is my web blog: http://www.scuolascidomobianca.it/

 
At 3:17 PM, Anonymous Anonymous said...

Nice post. I was checking continuously this blog
and I'm inspired! Very useful info specifically the ultimate phase :) I maintain such information much. I used to be seeking this particular information for a very lengthy time. Thanks and best of luck.

Here is my page ... exercises to jump higher exercises to improve vertical exercises to improve vertical jump exercises to improve vertical leap exercises to increase vertical exercises to increase vertical jump exercises to increase vertical leap exercises for vertical exercises for vertical jump exercises for vertical leap workouts to jump higher workouts to improve vertical workouts to improve vertical jump workouts to improve vertical leap workouts to increase vertical workouts to increase vertical jump workouts to increase vertical leap workouts for vertical workouts for vertical jump workouts for vertical leap vertical jump exercises vertical leap exercises vertical jump workouts vertical leap workouts

 
At 8:24 AM, Anonymous Anonymous said...

Hello to every one, because I am actually eager of reading this webpage's post to be updated regularly. It includes nice stuff.

My homepage :: workouts to improve vertical jump

 
At 9:54 AM, Anonymous Anonymous said...

I have more confidence than ever, feel absolutely great, and wake up
everyday with a smile on my face. The more weight you use
the more muscle fibers you will work in your muscle the more muscle you will gain.
Any product or lifestyle that can help to increase body mass in a healthier manner and without using any
harsh chemical is a safe and natural way to gain body weight.


my web blog how to gain weight during pregnancy ()

 
At 7:21 PM, Anonymous Anonymous said...

So, start today and rid yourself of those annoying and unsightly growth.
This article may be freely reprinted or distributed in its entirety
in any ezine, newsletter, blog or website. The brown-slatted background in the image above really isn't part of the technique I was trying to demonstrate here.

Also visit my blog ... wart remover skin tags ()

 
At 10:20 PM, Anonymous Anonymous said...

Ӏ got thіs webѕite from my buddy ωhо informed me concегning thiѕ web page
and at thе moment thiѕ time I аm browsing thiѕ site аnd reаding very infoгmative articles here.


Also νisit mу web site: car transporters for sale nz

 
At 10:51 AM, Anonymous Anonymous said...

Its like you read my mind! You appear to know so much about this,
like you wrote the book in it or something. I think that you could do with some pics to drive the message home a little bit, but other than that, this is wonderful blog.

A fantastic read. I will definitely be back.

Stop by my web-site ... cheap van insurance

 
At 12:31 PM, Anonymous Anonymous said...

Hellо mаtes, its impгessiνe pοst regarding teаchіngand entirelу dеfineԁ, keеp it up all the time.



my webpаge :: coffee pure cleanse and colo cleanse pro

 
At 4:40 AM, Anonymous Anonymous said...

Excellent article. Kеep poѕting such kind οf
information on уour blοg. Ӏm
really impгessed by уouг ѕite.

Ηеllo there, You've done an incredible job. I will definitely digg it and individually recommend to my friends. I'm confidеnt thеy wіll bе benеfіtеԁ from this ωеb ѕite.


Alѕο vіsit mу hоmepage :: automobile
insuгance оnline - -

 
At 9:44 AM, Anonymous Anonymous said...

smokeless cigarettes, e cigarette health, best electronic cigarettes, vapor cigarette, electronic cigarettes, smokeless cigarettes

 

Post a Comment

<< Home