"Object reference not set to an instance of an object" after exporting 2048 rows

Toad for SQL Server 64-bit

All export attempts fail with error "Object reference not set to an instance of an object. Export is cancelled." and the exported files always contain 2048 rows + the header, i.e. 2049.

I have tried both Excel and CSV... same results.

I have tried exporting different queries or even a simple SELECT * from a table... same results.

This seems to be a bug in this version and I haven't seen it reported yet. Anybody else experience this or know how to correct it? Below is the event log:

1:03:18 PM Thread (15) Export Started [2/8/2023 1:03:18 PM]
1:03:18 PM Thread (15) Export using connection: ........ (masked)
1:03:18 PM Thread (15) Export using connection: ........ (masked)
1:03:18 PM Thread (15) Export Wizard: Building object list
1:03:18 PM Thread (15) Exporting Data (1 of 1)
1:03:18 PM Thread (15) Object Table Result Set started.
1:03:19 PM Thread (15) Writing rows 0 - 6000
1:03:20 PM Thread (15) Exception in WriteRows
1:03:20 PM Thread (15) Object reference not set to an instance of an object.
1:03:20 PM Thread (15) Writing rows Finalize
1:03:20 PM Thread (15) Object Table Result Set finished with error: Object reference not set to an instance of an object.
1:03:20 PM Thread (15)    at Quest.Toad.ImportExport.Writers.WriterBase.WriteRows[TRow](Object lockObj, ExportTable`1 table, Int32 highCount, IEnumerable`1 rows)
   at Quest.Toad.ImportExport.Writers.WriterBase.WriteRows(FastTable table)
   at Quest.Toad.ImportExport.ExportObjectData.StartTableWrite(Object context)
   at Quest.Toad.ImportExport.ExportObjectData.Begin(LogEventHandler logEventHandler, Dictionary`2 connections, Object context)
1:04:51 PM Thread (15) Export Finished [2/8/2023 1:04:51 PM]

1:04:51 PM Thread (15) Export time = 00:01:33.3890529

I am not able to reproduce this behavior with my set of data tables, at least from my user perspective. I would suggest opening a ticket with Quest. They can attempt to reproduce your isue, given your exact steps, and as close to your environment as possible.

What version are you using? I just found another user of the exact same version and she too is getting this same error and her partially exported file is also just 2,048 rows + header. Definitely sounds like a bug in at least version 64-bit. I will open a ticket with Quest. Not sure how that's done, but going to try and figure that out not. Thank you.

Found the place. Unfortunately, their ticketing system seems to be having issues intaking new tickets. I tried two different browsers with the same error. I guess I'll try later.


This issue sounds similar to what's described in the following post. We had a similar problem and the steps in this post fixed it for us:

In case you can't view that page, here's what it says:

Here are the steps to fix the problem:
1.Go to Tools | Options | Database | Script Results Change the "Serialization temporary folder" to: C:\Users\CustomerUserNameI\AppData\Local\Temp
2. Verify that you have access to this path via File Explorer.
3. Restart Toad product and verify results.