Showing posts with label studio. Show all posts
Showing posts with label studio. Show all posts

Friday, March 30, 2012

Pre-execute error in simple import/export

I am trying to copy data from a SQL Server 2000 DB to SQL Server 2005 DB using the import/export wizard in SQL Server Management Studio. The two databases are not identical with different table names and different columns but I thought I had set up all the right mappings and had set the 'Enable identity insert' option. When I ran the wizard it errored at the Pre-execute phase. I simplified the wizard down to one table and only as couple of varchar columns and this also errored in the same way. The error report is detailed below.

For reference the SQL2000(ent. edn) DB is on a windows 2000 server and the SQL2005(dev. edn) DB and the management studio are both on my WinXPSP2 workstation.

Could somebody explain why these errors have occured and more importantly how to rectify the problem?

Many thanks,
Michael.

Operation stopped...

- Initializing Data Flow Task (Success)

- Initializing Connections (Success)

- Setting SQL Command (Success)

- Setting Source Connection (Success)

- Setting Destination Connection (Success)

- Validating (Warning)

Messages

Warning 0x80047076: Data Flow Task: The output column "DateAdd" (23) on output "OLE DB Source Output" (11) and component "Source - tccNewsArticles" (1) is not subsequently used in the Data Flow task. Removing this unused output column can increase Data Flow task performance.
(SQL Server Import and Export Wizard)

Warning 0x80047076: Data Flow Task: The output column "DateChg" (26) on output "OLE DB Source Output" (11) and component "Source - tccNewsArticles" (1) is not subsequently used in the Data Flow task. Removing this unused output column can increase Data Flow task performance.
(SQL Server Import and Export Wizard)

... NOTE: I have removed the rest of the warnings as they were the same as above (many of them).

- Pre-execute (Error)

Messages

Error 0xc0202009: Data Flow Task: An OLE DB error has occurred. Error code: 0x80040E21.
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80040E21 Description: "Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.".
(SQL Server Import and Export Wizard)

Error 0xc0202025: Data Flow Task: Cannot create an OLE DB accessor. Verify that the column metadata is valid.
(SQL Server Import and Export Wizard)

Error 0xc004701a: Data Flow Task: component "Destination - Nrs_NewsArticles" (112) failed the pre-execute phase and returned error code 0xC0202025.
(SQL Server Import and Export Wizard)

- Executing (Success)

- Copying to [NereusV2_1].[dbo].[Nrs_NewsArticles] (Stopped)

- Post-execute (Stopped)

- Cleanup (Success)

Messages

Information 0x4004300b: Data Flow Task: "component "Destination - Nrs_NewsArticles" (112)" wrote 0 rows.
(SQL Server Import and Export Wizard)

Michael,

this is most likely a truncation problem. Could you check the sizes of used source and destination columns?

Thanks.

Monday, March 26, 2012

PRC file extensions in MSSQL Management Studio 2005

Most of our files were scripted out to our VSS as PRC files. In MSSQL
Management Studio 2005 these file extensions are not recognized by the
compiler as SQL text. Now I could go into VSS and change all my
extensions to SQL, but I feel like that would be a very time consuming
task. Is there a way to have MSSQL Management Studio 2005 recognize
this as executable SQL text?
Thanks,
MikeMike,
I think you can change the File Type Association in Windows - sounds
like you have give Windows a gentle nudge in the right direction.
HTH
Barry|||I tried that and it didn't work : - (|||What do you mean by "recognized by the compiler as SQL text"? SQL Server (th
e database engine)
doesn't open any files (containing source code), so it couldn't care less wh
at extensions you have
for the files on the files systems on your machines. So your problem has to
be with the tools you
are using. Perhaps you can elaborate a bit?
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Mike" <mikepmyers@.hotmail.com> wrote in message
news:1136388956.187342.158280@.g14g2000cwa.googlegroups.com...
> Most of our files were scripted out to our VSS as PRC files. In MSSQL
> Management Studio 2005 these file extensions are not recognized by the
> compiler as SQL text. Now I could go into VSS and change all my
> extensions to SQL, but I feel like that would be a very time consuming
> task. Is there a way to have MSSQL Management Studio 2005 recognize
> this as executable SQL text?
> Thanks,
> Mike
>|||I found the answer to my own question. In MSSQL Management Studio 2005
you have to associate the extension to the program by:
* Tools - Options - Text Editor - File Extnesion - Extension:
"PRC" - Editor: "SQL Query Editor"
It's a pain that MSSQL Management Studio 2005 doesn't recognize the
"PRC" file extension automatically, but as long as there is a
work-around I guess I'll live.sql

PRC file extensions in MSSQL Management Studio 2005

Most of our files were scripted out to our VSS as PRC files. In MSSQL
Management Studio 2005 these file extensions are not recognized by the
compiler as SQL text. Now I could go into VSS and change all my
extensions to SQL, but I feel like that would be a very time consuming
task. Is there a way to have MSSQL Management Studio 2005 recognize
this as executable SQL text?
Thanks,
Mike
I found the answer to my own question. In MSSQL Management Studio 2005
you have to associate the extension to the program by:
* Tools - Options - Text Editor - File Extnesion - Extension:
"PRC" - Editor: "SQL Query Editor"
It's a pain that MSSQL Management Studio 2005 doesn't recognize the
"PRC" file extension automatically, but as long as there is a
work-around I guess I'll live.

PRC file extensions in MSSQL Management Studio 2005

Most of our files were scripted out to our VSS as PRC files. In MSSQL
Management Studio 2005 these file extensions are not recognized by the
compiler as SQL text. Now I could go into VSS and change all my
extensions to SQL, but I feel like that would be a very time consuming
task. Is there a way to have MSSQL Management Studio 2005 recognize
this as executable SQL text?
Thanks,
MikeI found the answer to my own question. In MSSQL Management Studio 2005
you have to associate the extension to the program by:
* Tools - Options - Text Editor - File Extnesion - Extension:
"PRC" - Editor: "SQL Query Editor"
It's a pain that MSSQL Management Studio 2005 doesn't recognize the
"PRC" file extension automatically, but as long as there is a
work-around I guess I'll live.

PRC file extensions in MSSQL Management Studio 2005

Most of our files were scripted out to our VSS as PRC files. In MSSQL
Management Studio 2005 these file extensions are not recognized by the
compiler as SQL text. Now I could go into VSS and change all my
extensions to SQL, but I feel like that would be a very time consuming
task. Is there a way to have MSSQL Management Studio 2005 recognize
this as executable SQL text?
Thanks,
MikeI found the answer to my own question. In MSSQL Management Studio 2005
you have to associate the extension to the program by:
* Tools - Options - Text Editor - File Extnesion - Extension:
"PRC" - Editor: "SQL Query Editor"
It's a pain that MSSQL Management Studio 2005 doesn't recognize the
"PRC" file extension automatically, but as long as there is a
work-around I guess I'll live.

Powerpoint-Reporting with SQL2005 Reporting Services

Hi All,
the SQL Server Business Intelligence Development Studio is not equipped with
an option to output powerpoint presentations.
we have to migrate an legacy application which has been coded in access-vba.
the vba code uses data within an MSSQL Database and a powerpoint template
(.pot) and the output is a powerpoint presentation with lots of graphs and
charts in it.
we are thinking about porting the vba code into a code module within the SQL
Server Business Intelligence Development Studio.
does anybody know if it would technically be possible to use plain vba code
(ported from the access application) within SQL Server Business Intelligence
Development Studio to fill a powerpoint template and thus to generate a
whole powerpoint presentation? (provided that this whole vba-magic is
working within the access-application)
if the above stated idea is complete rubbish then please let me know. if it
might be possible to use SQL Server Business Intelligence Development Studio
to achieve this aim, please let me also know which steps this should
involve.
thanks a lot in advance!
best regards, janYou'd need to convert from VBA to VB.net.. I would really reccomend
writing some of the core logic in DLLs or something; I dont think that
putting hundreds of pages in code inside of a report would make a lot
of sense.. more importantly; you don't want 100 different copies of
this code; that would make maintenance difficult.
Then you would just digest this code inside the report properties
section; there is a 'code' window.
Why do you use powerpoint; anyways?
by chance do you work for a large auction web company in the Bay Area?
LoL?
We use OfficeWriter by SoftArtisans.. If I were you; I would push them
HARD to see if they can come up with a solution and then stand on the
shoulders of giants.
I just think that exporting to PPT might be a major pain.
Now.. for example.. if you wanted to talk about something that might be
a LOT LOT LOT easier to deal with?
you probably could just export the reports to XML format; and then
maybe make an XSLT that would 'translate' the XML out of SSRS into the
XML for PPT 07 or even 03.
Hope that helps; SSRS rocks!
-Aaron
Jan wrote:
> Hi All,
> the SQL Server Business Intelligence Development Studio is not equipped with
> an option to output powerpoint presentations.
> we have to migrate an legacy application which has been coded in access-vba.
> the vba code uses data within an MSSQL Database and a powerpoint template
> (.pot) and the output is a powerpoint presentation with lots of graphs and
> charts in it.
> we are thinking about porting the vba code into a code module within the SQL
> Server Business Intelligence Development Studio.
> does anybody know if it would technically be possible to use plain vba code
> (ported from the access application) within SQL Server Business Intelligence
> Development Studio to fill a powerpoint template and thus to generate a
> whole powerpoint presentation? (provided that this whole vba-magic is
> working within the access-application)
> if the above stated idea is complete rubbish then please let me know. if it
> might be possible to use SQL Server Business Intelligence Development Studio
> to achieve this aim, please let me also know which steps this should
> involve.
> thanks a lot in advance!
> best regards, jansql

Tuesday, March 20, 2012

Post 2005 SP2 install, no script component can be edited.

Anyone starting to see "Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)" after installing SQL Server 2005 SP2 on x86 machines? Second, how can it be fixed?

After installing SP2, the script component editor will not edit script components created in pre SP2 releases. (I also have Visual Studio 2005 SP1 installed). The script TASK editor will start, but when attempting to open a script COMPONENT in the VSA editor, a script component created for pre-SP2 packages, the following error dialog occurs.

Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)

This same error dialog has occurred on multiple computers, none of them are running Vista (rather Windows XP SP2). All of the pre-existent pre-SP2 script components have Precompile set to true as well, since they are intended for 64 bit machines.

Now, certain posts say, register DLLs in the following directories via:
for %i in (*.dll) do RegSvr32 -s %i.

C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\common\
C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\vsa

One problem with these instruction is that the second directory doesn't even exist, however, a directory called "C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\VsaEnv" does exist, which is perhaps what was meant. Even after registering the DLLs there, the script component editor will not open (erroring out after clicking the "Design Script..." button).

Yes I have similar issue. I cant edit my script component. I am getting an following error message when I click on "Design Script".

Cannot Show Visual Studio for Applications Editor. Engine Returned Unknown Error

Anyone else?

Thanks

Sutha

|||

I haven’t seen anything like this. From the look of it the VSA is installed properly (you mentioned that you can start designer for the script task but not for the script component). Can you design new script components on that machine?

Thanks

|||New SP2 script components and tasks can be created and edited.

Script components created prior to SP2 (at least those created on 2153 and perhaps earlier) cannot be opened, at least on Windows XP. On Windows 2003 Server (32 or 64 bit) I have not observed any issue (the editor open's fine on the same .dtsx that fails to open on an XP machine).|||

I have the exact same issue and here is an interesting addition:

If I add a new script component (without attaching it to anything) and attempt to view the script it actually brings up the script editor with the code of the old script component that I was trying to open in the first place.

I guess I'll have to uninstall SP2 at this point.

Daryl

|||If you're on Vista, try the hotfix:
http://support.microsoft.com/default.aspx/kb/931846|||

This uneditable script component problem is specifically noticed on Windows XP and is unsolved and without reasonable workaround(e.g. total replacement of OS with Win2k3).

The Vista script component create/edit issue is indeed solved with that 931846 hotfix (the receipt of which requires a call to Microsoft PSS as it is not regression tested).

|||I can definitely confirm this exact problem after an install of SS2005 SP2a. Exactly
as described. A little confused, the problem says it is with WinXP Pro - which I have -
but patch is for Vista? Anybody install the patch on XP or found another workaround.|||OK, there are 2 different patches for this. One for WinXP, one for Vista - they have
different patching systems. So if you call MS, make sure they know which one you want.

The patch number and KB article are the same. Welcome to Microsoft....|||Are you saying this is resolved? I don't believe it for one second, and I'll happily admit to being wrong. What is the URL, if you would be so kind?|||I'm having the same problem. Where can I find the XP patch?|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

KB928208|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I am working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

http://support.microsoft.com/default.aspx/kb/928208

You have to call MS to get this.
|||After two disconnects without being able to talk to anybody, a 90 minute wait time on the third try, and two more hours trying get this error solved, we got it to work. At least, some sort of temp solution until a KB / hotfix is available.
Keep in mind this is for a Win Server 2k3 environment and not exactly the most recommended solution.
Anyways, this was my fix.
Go to your pacakge code ( right click the package in the solution explorer and select view code ). Search for every "ReferencePath" and pretty much replace
""C:\WINDOWS\assembly\GAC_MSIL\Microsoft.SqlServer.DTSRuntimeWrap\" with "C:\WINDOWS\assembly\GAC_32\Microsoft.SqlServer.DTSRuntimeWrap\". (the rightmost reference)
Viola! That's it!

For now, I'll only do this for the packages I need to edit.

I hope this helps.

Thanks,
Alonso|||That's what I sent to Microsoft last night ( swap GAC_MSIL to GAC_32 on the reference path) and the 2153 script component starts working. Didn't post that advice on the forum because I wanted to hear back from Microsoft as to whether that was a legitimate solution, indicative of an underlying issue (perhaps with ngen.exe's queue), or both or neither. I understand that its not the most recommended solution, but its the only solution right now.

Post 2005 SP2 install, no script component can be edited.

Anyone starting to see "Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)" after installing SQL Server 2005 SP2 on x86 machines? Second, how can it be fixed?

After installing SP2, the script component editor will not edit script components created in pre SP2 releases. (I also have Visual Studio 2005 SP1 installed). The script TASK editor will start, but when attempting to open a script COMPONENT in the VSA editor, a script component created for pre-SP2 packages, the following error dialog occurs.

Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)

This same error dialog has occurred on multiple computers, none of them are running Vista (rather Windows XP SP2). All of the pre-existent pre-SP2 script components have Precompile set to true as well, since they are intended for 64 bit machines.

Now, certain posts say, register DLLs in the following directories via:
for %i in (*.dll) do RegSvr32 -s %i.

C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\common\
C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\vsa

One problem with these instruction is that the second directory doesn't even exist, however, a directory called "C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\VsaEnv" does exist, which is perhaps what was meant. Even after registering the DLLs there, the script component editor will not open (erroring out after clicking the "Design Script..." button).

Yes I have similar issue. I cant edit my script component. I am getting an following error message when I click on "Design Script".

Cannot Show Visual Studio for Applications Editor. Engine Returned Unknown Error

Anyone else?

Thanks

Sutha

|||

I haven’t seen anything like this. From the look of it the VSA is installed properly (you mentioned that you can start designer for the script task but not for the script component). Can you design new script components on that machine?

Thanks

|||New SP2 script components and tasks can be created and edited.

Script components created prior to SP2 (at least those created on 2153 and perhaps earlier) cannot be opened, at least on Windows XP. On Windows 2003 Server (32 or 64 bit) I have not observed any issue (the editor open's fine on the same .dtsx that fails to open on an XP machine).
|||

I have the exact same issue and here is an interesting addition:

If I add a new script component (without attaching it to anything) and attempt to view the script it actually brings up the script editor with the code of the old script component that I was trying to open in the first place.

I guess I'll have to uninstall SP2 at this point.

Daryl

|||If you're on Vista, try the hotfix:
http://support.microsoft.com/default.aspx/kb/931846|||

This uneditable script component problem is specifically noticed on Windows XP and is unsolved and without reasonable workaround(e.g. total replacement of OS with Win2k3).

The Vista script component create/edit issue is indeed solved with that 931846 hotfix (the receipt of which requires a call to Microsoft PSS as it is not regression tested).

|||I can definitely confirm this exact problem after an install of SS2005 SP2a. Exactly
as described. A little confused, the problem says it is with WinXP Pro - which I have -
but patch is for Vista? Anybody install the patch on XP or found another workaround.

|||OK, there are 2 different patches for this. One for WinXP, one for Vista - they have
different patching systems. So if you call MS, make sure they know which one you want.

The patch number and KB article are the same. Welcome to Microsoft....

|||Are you saying this is resolved? I don't believe it for one second, and I'll happily admit to being wrong. What is the URL, if you would be so kind?
|||I'm having the same problem. Where can I find the XP patch?|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

KB928208

|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I am working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

http://support.microsoft.com/default.aspx/kb/928208

You have to call MS to get this.
|||After two disconnects without being able to talk to anybody, a 90 minute wait time on the third try, and two more hours trying get this error solved, we got it to work. At least, some sort of temp solution until a KB / hotfix is available.
Keep in mind this is for a Win Server 2k3 environment and not exactly the most recommended solution.
Anyways, this was my fix.
Go to your pacakge code ( right click the package in the solution explorer and select view code ). Search for every "ReferencePath" and pretty much replace
""C:\WINDOWS\assembly\GAC_MSIL\Microsoft.SqlServer.DTSRuntimeWrap\" with "C:\WINDOWS\assembly\GAC_32\Microsoft.SqlServer.DTSRuntimeWrap\". (the rightmost reference)
Viola! That's it!

For now, I'll only do this for the packages I need to edit.

I hope this helps.

Thanks,
Alonso
|||That's what I sent to Microsoft last night ( swap GAC_MSIL to GAC_32 on the reference path) and the 2153 script component starts working. Didn't post that advice on the forum because I wanted to hear back from Microsoft as to whether that was a legitimate solution, indicative of an underlying issue (perhaps with ngen.exe's queue), or both or neither. I understand that its not the most recommended solution, but its the only solution right now.

Post 2005 SP2 install, no script component can be edited.

Anyone starting to see "Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)" after installing SQL Server 2005 SP2 on x86 machines? Second, how can it be fixed?

After installing SP2, the script component editor will not edit script components created in pre SP2 releases. (I also have Visual Studio 2005 SP1 installed). The script TASK editor will start, but when attempting to open a script COMPONENT in the VSA editor, a script component created for pre-SP2 packages, the following error dialog occurs.

Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)

This same error dialog has occurred on multiple computers, none of them are running Vista (rather Windows XP SP2). All of the pre-existent pre-SP2 script components have Precompile set to true as well, since they are intended for 64 bit machines.

Now, certain posts say, register DLLs in the following directories via:
for %i in (*.dll) do RegSvr32 -s %i.

C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\common\
C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\vsa

One problem with these instruction is that the second directory doesn't even exist, however, a directory called "C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\VsaEnv" does exist, which is perhaps what was meant. Even after registering the DLLs there, the script component editor will not open (erroring out after clicking the "Design Script..." button).

Yes I have similar issue. I cant edit my script component. I am getting an following error message when I click on "Design Script".

Cannot Show Visual Studio for Applications Editor. Engine Returned Unknown Error

Anyone else?

Thanks

Sutha

|||

I haven’t seen anything like this. From the look of it the VSA is installed properly (you mentioned that you can start designer for the script task but not for the script component). Can you design new script components on that machine?

Thanks

|||New SP2 script components and tasks can be created and edited.

Script components created prior to SP2 (at least those created on 2153 and perhaps earlier) cannot be opened, at least on Windows XP. On Windows 2003 Server (32 or 64 bit) I have not observed any issue (the editor open's fine on the same .dtsx that fails to open on an XP machine).
|||

I have the exact same issue and here is an interesting addition:

If I add a new script component (without attaching it to anything) and attempt to view the script it actually brings up the script editor with the code of the old script component that I was trying to open in the first place.

I guess I'll have to uninstall SP2 at this point.

Daryl

|||If you're on Vista, try the hotfix:
http://support.microsoft.com/default.aspx/kb/931846|||

This uneditable script component problem is specifically noticed on Windows XP and is unsolved and without reasonable workaround(e.g. total replacement of OS with Win2k3).

The Vista script component create/edit issue is indeed solved with that 931846 hotfix (the receipt of which requires a call to Microsoft PSS as it is not regression tested).

|||I can definitely confirm this exact problem after an install of SS2005 SP2a. Exactly
as described. A little confused, the problem says it is with WinXP Pro - which I have -
but patch is for Vista? Anybody install the patch on XP or found another workaround.

|||OK, there are 2 different patches for this. One for WinXP, one for Vista - they have
different patching systems. So if you call MS, make sure they know which one you want.

The patch number and KB article are the same. Welcome to Microsoft....

|||Are you saying this is resolved? I don't believe it for one second, and I'll happily admit to being wrong. What is the URL, if you would be so kind?
|||I'm having the same problem. Where can I find the XP patch?|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

KB928208

|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I am working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

http://support.microsoft.com/default.aspx/kb/928208

You have to call MS to get this.
|||After two disconnects without being able to talk to anybody, a 90 minute wait time on the third try, and two more hours trying get this error solved, we got it to work. At least, some sort of temp solution until a KB / hotfix is available.
Keep in mind this is for a Win Server 2k3 environment and not exactly the most recommended solution.
Anyways, this was my fix.
Go to your pacakge code ( right click the package in the solution explorer and select view code ). Search for every "ReferencePath" and pretty much replace
""C:\WINDOWS\assembly\GAC_MSIL\Microsoft.SqlServer.DTSRuntimeWrap\" with "C:\WINDOWS\assembly\GAC_32\Microsoft.SqlServer.DTSRuntimeWrap\". (the rightmost reference)
Viola! That's it!

For now, I'll only do this for the packages I need to edit.

I hope this helps.

Thanks,
Alonso
|||That's what I sent to Microsoft last night ( swap GAC_MSIL to GAC_32 on the reference path) and the 2153 script component starts working. Didn't post that advice on the forum because I wanted to hear back from Microsoft as to whether that was a legitimate solution, indicative of an underlying issue (perhaps with ngen.exe's queue), or both or neither. I understand that its not the most recommended solution, but its the only solution right now.

Post 2005 SP2 install, no script component can be edited.

Anyone starting to see "Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)" after installing SQL Server 2005 SP2 on x86 machines? Second, how can it be fixed?

After installing SP2, the script component editor will not edit script components created in pre SP2 releases. (I also have Visual Studio 2005 SP1 installed). The script TASK editor will start, but when attempting to open a script COMPONENT in the VSA editor, a script component created for pre-SP2 packages, the following error dialog occurs.

Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)

This same error dialog has occurred on multiple computers, none of them are running Vista (rather Windows XP SP2). All of the pre-existent pre-SP2 script components have Precompile set to true as well, since they are intended for 64 bit machines.

Now, certain posts say, register DLLs in the following directories via:
for %i in (*.dll) do RegSvr32 -s %i.

C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\common\
C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\vsa

One problem with these instruction is that the second directory doesn't even exist, however, a directory called "C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\VsaEnv" does exist, which is perhaps what was meant. Even after registering the DLLs there, the script component editor will not open (erroring out after clicking the "Design Script..." button).

Yes I have similar issue. I cant edit my script component. I am getting an following error message when I click on "Design Script".

Cannot Show Visual Studio for Applications Editor. Engine Returned Unknown Error

Anyone else?

Thanks

Sutha

|||

I haven’t seen anything like this. From the look of it the VSA is installed properly (you mentioned that you can start designer for the script task but not for the script component). Can you design new script components on that machine?

Thanks

|||New SP2 script components and tasks can be created and edited.

Script components created prior to SP2 (at least those created on 2153 and perhaps earlier) cannot be opened, at least on Windows XP. On Windows 2003 Server (32 or 64 bit) I have not observed any issue (the editor open's fine on the same .dtsx that fails to open on an XP machine).|||

I have the exact same issue and here is an interesting addition:

If I add a new script component (without attaching it to anything) and attempt to view the script it actually brings up the script editor with the code of the old script component that I was trying to open in the first place.

I guess I'll have to uninstall SP2 at this point.

Daryl

|||If you're on Vista, try the hotfix:
http://support.microsoft.com/default.aspx/kb/931846|||

This uneditable script component problem is specifically noticed on Windows XP and is unsolved and without reasonable workaround(e.g. total replacement of OS with Win2k3).

The Vista script component create/edit issue is indeed solved with that 931846 hotfix (the receipt of which requires a call to Microsoft PSS as it is not regression tested).

|||I can definitely confirm this exact problem after an install of SS2005 SP2a. Exactly
as described. A little confused, the problem says it is with WinXP Pro - which I have -
but patch is for Vista? Anybody install the patch on XP or found another workaround.|||OK, there are 2 different patches for this. One for WinXP, one for Vista - they have
different patching systems. So if you call MS, make sure they know which one you want.

The patch number and KB article are the same. Welcome to Microsoft....|||Are you saying this is resolved? I don't believe it for one second, and I'll happily admit to being wrong. What is the URL, if you would be so kind?|||I'm having the same problem. Where can I find the XP patch?|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

KB928208|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I am working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

http://support.microsoft.com/default.aspx/kb/928208

You have to call MS to get this.
|||After two disconnects without being able to talk to anybody, a 90 minute wait time on the third try, and two more hours trying get this error solved, we got it to work. At least, some sort of temp solution until a KB / hotfix is available.
Keep in mind this is for a Win Server 2k3 environment and not exactly the most recommended solution.
Anyways, this was my fix.
Go to your pacakge code ( right click the package in the solution explorer and select view code ). Search for every "ReferencePath" and pretty much replace
""C:\WINDOWS\assembly\GAC_MSIL\Microsoft.SqlServer.DTSRuntimeWrap\" with "C:\WINDOWS\assembly\GAC_32\Microsoft.SqlServer.DTSRuntimeWrap\". (the rightmost reference)
Viola! That's it!

For now, I'll only do this for the packages I need to edit.

I hope this helps.

Thanks,
Alonso|||That's what I sent to Microsoft last night ( swap GAC_MSIL to GAC_32 on the reference path) and the 2153 script component starts working. Didn't post that advice on the forum because I wanted to hear back from Microsoft as to whether that was a legitimate solution, indicative of an underlying issue (perhaps with ngen.exe's queue), or both or neither. I understand that its not the most recommended solution, but its the only solution right now.

Post 2005 SP2 install, no script component can be edited.

Anyone starting to see "Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)" after installing SQL Server 2005 SP2 on x86 machines? Second, how can it be fixed?

After installing SP2, the script component editor will not edit script components created in pre SP2 releases. (I also have Visual Studio 2005 SP1 installed). The script TASK editor will start, but when attempting to open a script COMPONENT in the VSA editor, a script component created for pre-SP2 packages, the following error dialog occurs.

Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)

This same error dialog has occurred on multiple computers, none of them are running Vista (rather Windows XP SP2). All of the pre-existent pre-SP2 script components have Precompile set to true as well, since they are intended for 64 bit machines.

Now, certain posts say, register DLLs in the following directories via:
for %i in (*.dll) do RegSvr32 -s %i.

C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\common\
C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\vsa

One problem with these instruction is that the second directory doesn't even exist, however, a directory called "C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\VsaEnv" does exist, which is perhaps what was meant. Even after registering the DLLs there, the script component editor will not open (erroring out after clicking the "Design Script..." button).

Yes I have similar issue. I cant edit my script component. I am getting an following error message when I click on "Design Script".

Cannot Show Visual Studio for Applications Editor. Engine Returned Unknown Error

Anyone else?

Thanks

Sutha

|||

I haven’t seen anything like this. From the look of it the VSA is installed properly (you mentioned that you can start designer for the script task but not for the script component). Can you design new script components on that machine?

Thanks

|||New SP2 script components and tasks can be created and edited.

Script components created prior to SP2 (at least those created on 2153 and perhaps earlier) cannot be opened, at least on Windows XP. On Windows 2003 Server (32 or 64 bit) I have not observed any issue (the editor open's fine on the same .dtsx that fails to open on an XP machine).
|||

I have the exact same issue and here is an interesting addition:

If I add a new script component (without attaching it to anything) and attempt to view the script it actually brings up the script editor with the code of the old script component that I was trying to open in the first place.

I guess I'll have to uninstall SP2 at this point.

Daryl

|||If you're on Vista, try the hotfix:
http://support.microsoft.com/default.aspx/kb/931846|||

This uneditable script component problem is specifically noticed on Windows XP and is unsolved and without reasonable workaround(e.g. total replacement of OS with Win2k3).

The Vista script component create/edit issue is indeed solved with that 931846 hotfix (the receipt of which requires a call to Microsoft PSS as it is not regression tested).

|||I can definitely confirm this exact problem after an install of SS2005 SP2a. Exactly
as described. A little confused, the problem says it is with WinXP Pro - which I have -
but patch is for Vista? Anybody install the patch on XP or found another workaround.

|||OK, there are 2 different patches for this. One for WinXP, one for Vista - they have
different patching systems. So if you call MS, make sure they know which one you want.

The patch number and KB article are the same. Welcome to Microsoft....

|||Are you saying this is resolved? I don't believe it for one second, and I'll happily admit to being wrong. What is the URL, if you would be so kind?
|||I'm having the same problem. Where can I find the XP patch?|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

KB928208

|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I am working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

http://support.microsoft.com/default.aspx/kb/928208

You have to call MS to get this.
|||After two disconnects without being able to talk to anybody, a 90 minute wait time on the third try, and two more hours trying get this error solved, we got it to work. At least, some sort of temp solution until a KB / hotfix is available.
Keep in mind this is for a Win Server 2k3 environment and not exactly the most recommended solution.
Anyways, this was my fix.
Go to your pacakge code ( right click the package in the solution explorer and select view code ). Search for every "ReferencePath" and pretty much replace
""C:\WINDOWS\assembly\GAC_MSIL\Microsoft.SqlServer.DTSRuntimeWrap\" with "C:\WINDOWS\assembly\GAC_32\Microsoft.SqlServer.DTSRuntimeWrap\". (the rightmost reference)
Viola! That's it!

For now, I'll only do this for the packages I need to edit.

I hope this helps.

Thanks,
Alonso
|||That's what I sent to Microsoft last night ( swap GAC_MSIL to GAC_32 on the reference path) and the 2153 script component starts working. Didn't post that advice on the forum because I wanted to hear back from Microsoft as to whether that was a legitimate solution, indicative of an underlying issue (perhaps with ngen.exe's queue), or both or neither. I understand that its not the most recommended solution, but its the only solution right now.

Post 2005 SP2 install, no script component can be edited.

Anyone starting to see "Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)" after installing SQL Server 2005 SP2 on x86 machines? Second, how can it be fixed?

After installing SP2, the script component editor will not edit script components created in pre SP2 releases. (I also have Visual Studio 2005 SP1 installed). The script TASK editor will start, but when attempting to open a script COMPONENT in the VSA editor, a script component created for pre-SP2 packages, the following error dialog occurs.

Cannot show Visual Studio for Applications editor. (Microsoft Visual Studio)

This same error dialog has occurred on multiple computers, none of them are running Vista (rather Windows XP SP2). All of the pre-existent pre-SP2 script components have Precompile set to true as well, since they are intended for 64 bit machines.

Now, certain posts say, register DLLs in the following directories via:
for %i in (*.dll) do RegSvr32 -s %i.

C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\common\
C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\vsa

One problem with these instruction is that the second directory doesn't even exist, however, a directory called "C:\Program Files\Common Files\Microsoft Shared\VSA\8.0\VsaEnv" does exist, which is perhaps what was meant. Even after registering the DLLs there, the script component editor will not open (erroring out after clicking the "Design Script..." button).

Yes I have similar issue. I cant edit my script component. I am getting an following error message when I click on "Design Script".

Cannot Show Visual Studio for Applications Editor. Engine Returned Unknown Error

Anyone else?

Thanks

Sutha

|||

I haven’t seen anything like this. From the look of it the VSA is installed properly (you mentioned that you can start designer for the script task but not for the script component). Can you design new script components on that machine?

Thanks

|||New SP2 script components and tasks can be created and edited.

Script components created prior to SP2 (at least those created on 2153 and perhaps earlier) cannot be opened, at least on Windows XP. On Windows 2003 Server (32 or 64 bit) I have not observed any issue (the editor open's fine on the same .dtsx that fails to open on an XP machine).
|||

I have the exact same issue and here is an interesting addition:

If I add a new script component (without attaching it to anything) and attempt to view the script it actually brings up the script editor with the code of the old script component that I was trying to open in the first place.

I guess I'll have to uninstall SP2 at this point.

Daryl

|||If you're on Vista, try the hotfix:
http://support.microsoft.com/default.aspx/kb/931846|||

This uneditable script component problem is specifically noticed on Windows XP and is unsolved and without reasonable workaround(e.g. total replacement of OS with Win2k3).

The Vista script component create/edit issue is indeed solved with that 931846 hotfix (the receipt of which requires a call to Microsoft PSS as it is not regression tested).

|||I can definitely confirm this exact problem after an install of SS2005 SP2a. Exactly
as described. A little confused, the problem says it is with WinXP Pro - which I have -
but patch is for Vista? Anybody install the patch on XP or found another workaround.

|||OK, there are 2 different patches for this. One for WinXP, one for Vista - they have
different patching systems. So if you call MS, make sure they know which one you want.

The patch number and KB article are the same. Welcome to Microsoft....

|||Are you saying this is resolved? I don't believe it for one second, and I'll happily admit to being wrong. What is the URL, if you would be so kind?
|||I'm having the same problem. Where can I find the XP patch?|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

KB928208

|||Yes, resolved to my satisfaction. I got the WinXP patch and it fixed the problem
and I am working fine now. 2 iterations with MS to get the right one. Vista has
a totally new and different patching mechanism, but the patch underneath is the same.

http://support.microsoft.com/default.aspx/kb/928208

You have to call MS to get this.
|||After two disconnects without being able to talk to anybody, a 90 minute wait time on the third try, and two more hours trying get this error solved, we got it to work. At least, some sort of temp solution until a KB / hotfix is available.
Keep in mind this is for a Win Server 2k3 environment and not exactly the most recommended solution.
Anyways, this was my fix.
Go to your pacakge code ( right click the package in the solution explorer and select view code ). Search for every "ReferencePath" and pretty much replace
""C:\WINDOWS\assembly\GAC_MSIL\Microsoft.SqlServer.DTSRuntimeWrap\" with "C:\WINDOWS\assembly\GAC_32\Microsoft.SqlServer.DTSRuntimeWrap\". (the rightmost reference)
Viola! That's it!

For now, I'll only do this for the packages I need to edit.

I hope this helps.

Thanks,
Alonso
|||That's what I sent to Microsoft last night ( swap GAC_MSIL to GAC_32 on the reference path) and the 2153 script component starts working. Didn't post that advice on the forum because I wanted to hear back from Microsoft as to whether that was a legitimate solution, indicative of an underlying issue (perhaps with ngen.exe's queue), or both or neither. I understand that its not the most recommended solution, but its the only solution right now.

Friday, March 9, 2012

Possible to restrict which dbs are shown in Management Studio...

Hi,
I'm migrating a load of databases from a SQL 2000 server to SQL 2005 and was
wondering if anyone knew how to restrict the list of databases that users
see when they connect using the Management Studio to only those that they
have access to? This was done in SQL 2000 by using the following:
http://support.microsoft.com/default.aspx/kb/889696
Any help is appreciated.
Thanks - Joe.In 2005, you have meta-data security built-in. By default, a user can't even see the existence of an
object they don't have permissions to use. Database is the one exception though, but you can handle
that through the VIEW DEFINITION permission.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Joe Mills" <joemills84@.hotmail.com> wrote in message news:u2y1H$0BHHA.2328@.TK2MSFTNGP02.phx.gbl...
> Hi,
> I'm migrating a load of databases from a SQL 2000 server to SQL 2005 and was wondering if anyone
> knew how to restrict the list of databases that users see when they connect using the Management
> Studio to only those that they have access to? This was done in SQL 2000 by using the following:
> http://support.microsoft.com/default.aspx/kb/889696
> Any help is appreciated.
> Thanks - Joe.
>

Possible to restrict which dbs are shown in Management Studio...

Hi,
I'm migrating a load of databases from a SQL 2000 server to SQL 2005 and was
wondering if anyone knew how to restrict the list of databases that users
see when they connect using the Management Studio to only those that they
have access to? This was done in SQL 2000 by using the following:
http://support.microsoft.com/default.aspx/kb/889696
Any help is appreciated.
Thanks - Joe.In 2005, you have meta-data security built-in. By default, a user can't even
see the existence of an
object they don't have permissions to use. Database is the one exception tho
ugh, but you can handle
that through the VIEW DEFINITION permission.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Joe Mills" <joemills84@.hotmail.com> wrote in message news:u2y1H$0BHHA.2328@.TK2MSFTNGP02.phx
.gbl...
> Hi,
> I'm migrating a load of databases from a SQL 2000 server to SQL 2005 and w
as wondering if anyone
> knew how to restrict the list of databases that users see when they connec
t using the Management
> Studio to only those that they have access to? This was done in SQL 2000 b
y using the following:
> http://support.microsoft.com/default.aspx/kb/889696
> Any help is appreciated.
> Thanks - Joe.
>

Wednesday, March 7, 2012

Possible to cache a dataset when testing in Visual Studio?

I do a lot of work with a report that calls a stored procedure that takes
about 2 minutes to complete. It annoys me that when I change one little
formatting property in the layout, I have to wait for the stored procedure to
run again before I can see the results of my modification. I wish that I
could just cache the dataset created by this stored procedure when I'm
testing in Visual Studio and avoid rerunning it each time I change the
formatting. Can anyone tell me if this is possible? Thanks.It sounds like you did not install SP1 on your report designer machine. See
this section of the SP1 readme:
http://download.microsoft.com/download/7/f/b/7fb1a251-13ad-404c-a034-10d79ddaa510/SP1Readme_EN.htm#_report_designer_preview
SP1 can be downloaded here:
http://www.microsoft.com/downloads/details.aspx?FamilyId=580FEBF7-2972-40E7-BCCF-6CD90AC2F464&displaylang=en
-- Robert
This posting is provided "AS IS" with no warranties, and confers no rights.
"Stefan Wrobel" <StefanWrobel@.discussions.microsoft.com> wrote in message
news:FD067DE7-1DD1-463F-90E1-F835206D966C@.microsoft.com...
>I do a lot of work with a report that calls a stored procedure that takes
> about 2 minutes to complete. It annoys me that when I change one little
> formatting property in the layout, I have to wait for the stored procedure
> to
> run again before I can see the results of my modification. I wish that I
> could just cache the dataset created by this stored procedure when I'm
> testing in Visual Studio and avoid rerunning it each time I change the
> formatting. Can anyone tell me if this is possible? Thanks.

Saturday, February 25, 2012

possible bug regarding single line comments in SQL Server Management Studio

I don't know if this is a bug or something I've messed up in my settings. I am using SQL Server Management Studio with SQL 2005 service pack 1 installed, and I've been using it successfully ever since SP1 came out. All of a sudden, any time I have a query with a single line comment (i.e. using dash dash -- ), the rest of the query is ignored as if the single line comment is really a multi-line comment without the closing */

An example:

select top 100 *

from myTable

-- this is a comment

where myTableID = 1234

This would normally return exactly one row, but instead returns 100 rows ( as if the where clause did not exist). If I move the where clause above the comment, it works as expected. Any ideas?

In trying to fix this, I've uninstalled and reinstalled and even reinstalled SP1, but it still isn't fixed.

You've got me stumped. I took the code you have posted and it ran fine for me.

Can you post the exact code that you are using? Maybe we'll see that hanging character you missed or somthing.

|||

I used the exact query, merely changing the table name and ID column.

I ended up going through the process yet again (uninstalling the tools, reinstalling the tools, then installing SP1) and rebooted but still had the problem. However, after a second reboot, it starting behaving properly again. I hope my problem does not resurface.

|||We (me a colleague of mine), have withnessed this same behaviour and, atfer some deep analysis, we have concluded that this bug arises when the Transact-Sql line terminates with a CR (Carriage Return, Ascii(13)) only charaters when it should terminate with both CR (Carriage Return, Ascii(13)) followed by an LF (Line Feed, Ascii(10))

It seems that once SqlServer reachs a single-line comment identifier (--) it keeps fetching bytes untill a compounded line termination (CR followed by LF) is reached.

In the following sample, the {CR+LF} and {CR} are representations of their respective invisible ascii codes.

--This is just a normal single-line comment {CR+LF}
SELECT 'This command works fine' {CR+LF}

--This is a buggy single-line comment {CR}
SELECT 'This command does not work'{CR}
SELECT 'This command does not work either' {CR+LF}
SELECT 'This command work fine too' {CR+LF}

Moreover we have reasons to bellieve that this bug resides in Query Editor provided with SQL Server Management Studio Express Edition (at least, this was version my colleague was using when this bug arose). Anyway, although this bug must be corrected, LF should just be ignored when dealing with Sql scripts.

Running software:

SQL Server Management Studio Express Edition

Ms SQLServer 2000 (8.0.2039)

Win XP Portuguese SP2


Getting this sample you can:

- Load and execute it, using QueryAnalyzer to see the refered behaviour;
- View it, using Notepad, to see what actually happened.

possible bug regarding single line comments in SQL Server Management Studio

I don't know if this is a bug or something I've messed up in my settings. I am using SQL Server Management Studio with SQL 2005 service pack 1 installed, and I've been using it successfully ever since SP1 came out. All of a sudden, any time I have a query with a single line comment (i.e. using dash dash -- ), the rest of the query is ignored as if the single line comment is really a multi-line comment without the closing */

An example:

select top 100 *

from myTable

-- this is a comment

where myTableID = 1234

This would normally return exactly one row, but instead returns 100 rows ( as if the where clause did not exist). If I move the where clause above the comment, it works as expected. Any ideas?

In trying to fix this, I've uninstalled and reinstalled and even reinstalled SP1, but it still isn't fixed.

You've got me stumped. I took the code you have posted and it ran fine for me.

Can you post the exact code that you are using? Maybe we'll see that hanging character you missed or somthing.

|||

I used the exact query, merely changing the table name and ID column.

I ended up going through the process yet again (uninstalling the tools, reinstalling the tools, then installing SP1) and rebooted but still had the problem. However, after a second reboot, it starting behaving properly again. I hope my problem does not resurface.

|||We (me a colleague of mine), have withnessed this same behaviour and, atfer some deep analysis, we have concluded that this bug arises when the Transact-Sql line terminates with a CR (Carriage Return, Ascii(13)) only charaters when it should terminate with both CR (Carriage Return, Ascii(13)) followed by an LF (Line Feed, Ascii(10))

It seems that once SqlServer reachs a single-line comment identifier (--) it keeps fetching bytes untill a compounded line termination (CR followed by LF) is reached.

In the following sample, the {CR+LF} and {CR} are representations of their respective invisible ascii codes.

--This is just a normal single-line comment {CR+LF}
SELECT 'This command works fine' {CR+LF}

--This is a buggy single-line comment {CR}
SELECT 'This command does not work'{CR}
SELECT 'This command does not work either' {CR+LF}
SELECT 'This command work fine too' {CR+LF}

Moreover we have reasons to bellieve that this bug resides in Query Editor provided with SQL Server Management Studio Express Edition (at least, this was version my colleague was using when this bug arose). Anyway, although this bug must be corrected, LF should just be ignored when dealing with Sql scripts.

Running software:

SQL Server Management Studio Express Edition

Ms SQLServer 2000 (8.0.2039)

Win XP Portuguese SP2


Getting this sample you can:

- Load and execute it, using QueryAnalyzer to see the refered behaviour;
- View it, using Notepad, to see what actually happened.