AutoCAD Map 3D General Discussion

AutoCAD Map 3D General Discussion

Reply
Active Contributor
rckohler
Posts: 27
Registered: ‎10-19-2012
Message 1 of 13 (1,080 Views)
Accepted Solution

MAP 3D 2013: DRAWING & SQL SERVER SPATIAL ISSUES

1080 Views, 12 Replies
11-05-2012 01:14 PM

My drawing contains data connections to our SQL server spatial. Something happened to this drawing over the weekend that I can't seem to fix...

 

While opening the drawing, a dialog box pops up recommending not to open the drawing with errors; instead, open the drawing through a recover. I conduct the recover but, a 'damaged file' pop up displays, indicating the file was recovered, had zero errors, but erased one object. The message also says invalid data might have been changed or deleted. I hit 'close'.

 

Another dialog box pops up with 'unhandled exception...access violation...' I hit 'OK'.

 

The drawing opens but a warning bubble shows up saying,

'WARNING: The problems below were found applying style(s) to element MI_City_WGS84:

RDBMS: [Microsoft][SQL Server Native Client 10.0][SQL Server]Parameters were not supplied for the function 'Wolverine_GIS.dbo.fn_RoutePositionList_WGS84'.'

 

The bing map and one other data connection display, but all others don't. Nothing is in the display manager. Nothing shows connections anywhere. As soon as I click in the model space, a 'Fatal Error: Unhandles Access' message pops up & closes the program.

 

Any help would be greatly appreciated!

-Robyn

I talked with our DBA about these issues. The 'Invalid object name' warning keeps popping up because this layer doesn't exist in the SQL server spatial anymore. So, any drawing created before this layer was deleted from the  server, will continue having these warnings pop up. All new drawings are warning free.

Thanks again everyone for helping me through this.

Active Contributor
rckohler
Posts: 27
Registered: ‎10-19-2012
Message 2 of 13 (1,075 Views)

Re: MAP 3D 2013: DRAWING & SQL SERVER SPATIAL ISSUES

11-05-2012 02:39 PM in reply to: rckohler

In addition to the above error messages, I tried to re-assign a coordinate system for the drawing, but no matter which one I choose, a message pops up saying 'Cannot save projection code to the drawing.' Ignoring that, I try to connect another feature from the SQL server spatial but, get the message 'There was a problem adding data to Map.'

 

Not sure where to go from here...

Contributor
philrue
Posts: 11
Registered: ‎08-17-2007
Message 3 of 13 (1,072 Views)

Re: MAP 3D 2013: DRAWING & SQL SERVER SPATIAL ISSUES

11-05-2012 03:18 PM in reply to: rckohler

When I ran into these problems.  I took the drawing .bak file and renamed it to drawing1.dwg file and opened that version, sometimes it worked, sometimes it didn't.  I also have cleared the C:\ProgramDataAutodesk\AutoCAD Map 3D 21013\R19.0\MapCache layers and .xml files (look for a .xml with your drawing name on it and delete).  I found out sometimes the .xml and layers will get corrupt if your drawing has crashed on you.  The drawing must be closed in order to delete these files. Good luck Phil

Active Contributor
rckohler
Posts: 27
Registered: ‎10-19-2012
Message 4 of 13 (1,054 Views)

Re: MAP 3D 2013: DRAWING & SQL SERVER SPATIAL ISSUES

11-06-2012 06:27 AM in reply to: philrue

I renamed the .bak file as you recommended & in my case, it didn't help anything when I opened that file up. Shows an identical situation as my original file. I searched my computer for the .xml file & didn't find it either.

 

Was curious about SQL server spatial data not working anymore for any file, but opening a new dwg & connecting to the same data as my bad file, data connects & displays fine.

Product Support
phil_borycens
Posts: 202
Registered: ‎10-25-2011
Message 5 of 13 (1,010 Views)

Re: MAP 3D 2013: DRAWING & SQL SERVER SPATIAL ISSUES

11-08-2012 02:28 PM in reply to: rckohler

Hi Robyn,

 

Unfortunately, I do not see that error message anywhere in our internal docs. I do see lots of results for "Parameters were not supplied for the function" and "sql server" in a web search though, so you might work with your DBA towards a solution...

 

Just curious, do you have any Joins active in this DWG?



Phil Borycens
Active Contributor
rckohler
Posts: 27
Registered: ‎10-19-2012
Message 6 of 13 (868 Views)

Re: MAP 3D 2013: DRAWING & SQL SERVER SPATIAL ISSUES

02-11-2013 07:50 AM in reply to: phil_borycens

I do not have any joins in my drawing. What is the benefit of using them? I'm new to Map 3D & haven't come across that option yet.

I have started fresh with multiple drawings & still receive these messages (see attachment pics). My current drawing consists of data connections through the 'Basemap Services' to Bing Maps & 'SQL Server Spatial'.

Please see attachments.

Thanks,

Robyn

Product Support
phil_borycens
Posts: 202
Registered: ‎10-25-2011
Message 7 of 13 (848 Views)

Re: MAP 3D 2013: DRAWING & SQL SERVER SPATIAL ISSUES

02-11-2013 02:53 PM in reply to: rckohler

Hi Robyn,

 

Joins are for when you want to fuse two data sources into one -- usually a database with attribute information is joined with a geospatial feature class. There needs to be a common field that has the same value in both sources to make the link happen.

 

As far as the screenshots you posted -- I'm not exactly sure what is going on, but some/all of those errors might be ignorable. You might want to 'audit' all of your layers in Display Manager and check them against your connections in Map Explorer. Do you have any duplicate data connections? Maybe you loaded some saved layers, and now the XML needs updating? (If you edited the XML of a layer, brought it back into Map3D, then tried to Edit its Style, it could certainly cause problems like the ones you showcase here. It's best to either use the Edit Style interface completely, or maintain the XML manually. You shouldn't mix the two.)

 

Some of the suggestions already posted to this thread might help too.

 

Other users, feel free to chime in if you know something more. Thanks!



Phil Borycens
*Expert Elite*
Murph
Posts: 2,062
Registered: ‎11-13-2006
Message 8 of 13 (844 Views)

Re: MAP 3D 2013: DRAWING & SQL SERVER SPATIAL ISSUES

02-11-2013 03:01 PM in reply to: phil_borycens

My first guess is that the style was based on an attribute in the SQL table that the field name was changed somehow.

I would disconect from the SQL and delete the connection then add it back and restyle. Save and close then reopen the dwg again. If it was a new table (data) added to the  SQL database server the DBA may of ran a app to rename or change the field names. There is a different between Widgets and WIDGETS and widgets_.

Murph
Supportting the troops daily.
Active Contributor
rckohler
Posts: 27
Registered: ‎10-19-2012
Message 9 of 13 (791 Views)

Re: MAP 3D 2013: DRAWING & SQL SERVER SPATIAL ISSUES

02-19-2013 08:58 AM in reply to: Murph

Murph,

As I follow your directions to fix this issue, I encounter a problem deleting a connection. I disconnected from the SQL server, then deleted the connections. All but one connection were deleted. I tried to delete it again & again, but every time I hit ok to delete the connection, it just ignores it. I saved the drawing & re-opened it, but still have the same issue. I closed AutoCAD Map 3D & re-opened it, but still have the same problem. Even restarting my computer didn't help. I'm going to continue anyway, but if you happen to know why that one connection is being stubborn, please let me know.

Thanks,

Robyn

Product Support
phil_borycens
Posts: 202
Registered: ‎10-25-2011
Message 10 of 13 (786 Views)

Re: MAP 3D 2013: DRAWING & SQL SERVER SPATIAL ISSUES

02-19-2013 09:51 AM in reply to: rckohler

Hi Robyn,

 

I know I'm not Murph, but I will share my ideas with you...

 

Try removing the connection in Task Pane > Map Explorer. Simply select the connection and click the Remove button. If for some reason this doesn't work, then...

 

Try going to the main application menu (upper left) and choose Export > DWG (this runs the MAPTOACAD command, which should strip out any Data Connections). Then open your exported drawing and try making the connection to SQL Server again.

 

Let us know how this goes.

 

Thanks!

Phil



Phil Borycens
Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Are You Going To Be @ AU 2014? Feel free to drop by our AU topic post and share your plans, plug a class that you're teaching, or simply check out who else from the community might be in attendance. Ohh and don't forgot to stop by the Autodesk Help | Learn | Collaborate booths in the Exhibit Hall and meet our community team if you get a chance!