Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

SQL execution error when trying to open table with many cols

Posted on 2007-11-27
6
Medium Priority
?
387 Views
Last Modified: 2008-02-01
When trying to open a table (that someone else created) with a large number of cols SQLServer 2005 I get the following error:
Error Source: Microsoft.VisualStudio.DataTools
Exception has been thrown by the target of an invocation
I read somewhere the row length is 8060 - I guess this is the cause... Is there a workaround?


0
Comment
Question by:acdagirl
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 18

Expert Comment

by:Yveau
ID: 20358480
Try running the code in Code Snippet.
I doubt there is some SQL error here. You might need to look for help in the zones for Visual Studio or the programming language you are using ...

If you can give us the table def, we can calculate the column length (as you can do yourself of course) but when you try to create a table with a record def that is too long, you will get an error and you won't be able to create the table. So I have strong indication that the programming language or tool you are using is having some problems with the number of column. Not SQL Server ...

Hope this helps ...

select  count(*)
from    <Table>
-- should return only the number of records in the table.
 
select  *
from    <Table>
where   1 = 2
-- should return only the column names.
 
select  <column>
from    <Table>
-- select only one single column, not the whole (unknown) number of columns.
 
--

Open in new window

0
 

Author Comment

by:acdagirl
ID: 20358817
i'm opening the table in enterprise manager - there is not other tool here.
0
 
LVL 18

Expert Comment

by:Yveau
ID: 20361755
what about the select statements ?
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 

Author Comment

by:acdagirl
ID: 20365036
if I do a range it's ok, if I try to select all it fails with the same error.
0
 
LVL 18

Accepted Solution

by:
Yveau earned 2000 total points
ID: 20366425
Yep ... the SSMS is also just an application. The datagrid controls which are used for the SSMS also have there boundaries ... just have to live with it. You might want to make a case with MS for this ...
I've noticed these issues as well with several sort of operations on larger tables ...

But in the end ... scripting is always better ... and has never failed me :-)

Hope this helps ...
0
 

Author Comment

by:acdagirl
ID: 20366526
ok thanks
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I am showing a way to read/import the excel data in table using SQL server 2005... Suppose there is an Excel file "Book1" at location "C:\temp" with column "First Name" and "Last Name". Now to import this Excel data into the table, we will use…
In this article I will describe the Backup & Restore method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
We’ve all felt that sense of false security before—locking down external access to a database or component and feeling like we’ve done all we need to do to secure company data. But that feeling is fleeting. Attacks these days can happen in many w…

597 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question