Situation:
I'm using VS 2017 to build an SSIS package for MS SQL 2017. While building a Data Flow, I add the OLE DB Source and Destination. After mapping the destination, VS correctly identifies a truncation issue and gives me the warning message. (I was trying to put an nvarchar(50) into an nvarchar(10).)
I correct the issue by updating the source to limit the column width to 10 characters. SSIS build and runs fine, but the warning message persists.
Question:
Is there some way to force VS to reevaluate the package for warnings/errors? The only way I've found is to delete and re-add the destination, but that is obviously a pain. (Especially when it means remapping columns.)
Am I missing something obvious?
Not terribly. Slightly less painful might be to select a table above/below the current on in the destination. Click OK and then you get errors everywhere. Go back to the original table and the warnings have gone away.
I suppose closing and re-opening would force the designer to re-evaluate the metadata as well. But no, no button or mouse click to say call the underlying object's ReinitializeMetaData() method. At least, I assume that's the call the designer makes and then evaluates conditions like truncation possibilities
You can right-click on the Connection Manager for the components that are throwing errors and warnings (this works for errors too), set it to "Work Offline", and then do the same thing - right-click on the Connection Manager to remove the checkmark on "Work Offline".
When a Connection Manager changes state from "offline" to "online", all of the components and tasks that use it get re-validated.
I don't remember what version I was working with, but I've seen metadata get "stuck" with the wrong input length, and no amount of reinitializing would clear it. I had to open the Advanced Editor and manually change the length of the input column in order to get the warning to clear.
Related
Using Visual Studio 2019 Professional v16.8.2. Whenever code is modified, automatic re-compile is triggered in the background. This has the effect of marking/unmarking error squiggles, adding/removing items from the Error List window, and Intellisense related to these errors.
To demonstrate, ensure Tools > Options > Text Editor > General > Show error squiggles is enabled and view the Error List window. Take any large C++ or C# project which compiles correctly, and deliberately add a closing brace } somewhere in a method. In one small example for me, this generated 251 errors and related error squiggles, though it is possible to generate thousands of errors this way. Now repeatedly delete and then re-add the closing brace...Visual Studio starts to lag as it tries to mark/unmark, and add/remove all these errors.
When typing fast, pasting code, or just using the IDE as a text editor, this is distracting and incredibly annoying.
Is it possible to configure a delay from last keypress before automatic compilation? Ideally I'd like something like ~2000ms, or even the ability to only re-compile manually.
It's working as intended.
It's a function of the Precompiler and Intellisense. Their whole purpose is to catch compiler errors before you try to compile your code which may take a long time (re: your example of "a large project").
There was an update to VS2019 today as of this posting and I just noticed an option under Tools > Options... > Text Editor > Advanced labeled "Auto cancel long running auxiliary operations on typing" with the following radiobox settings:
Automatically adjust maximum allowed typing latency
Maximum allowed typing latency in milliseconds [textbox]
The first option is the one selected by default. You might try changing the setting to force a maximum allowed time to 2000ms (or whatever suits your needs) and see if that helps.
As a side note: I have the exact opposite problem: the squiggles don't go away even on perfectly normal and well-formed code until I save and/or manually compile. (It's a crap shoot on which one actually works first.)
I have a setup created that installs an application, and still does, but it started giving a strange warning at the end out of the blue. So, when the installation process finishes, the following appears:
The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2810.
So I checked 2810, and it says:
On the dialog [2] the next control pointers do not form a cycle. There is a pointer from both [3] and [5] to [4].
I was not changing anything in the "User interface" or "Custom actions" so this came unexpected. Also the installation completes if you just click ok and everything works fine, it just doesn't look good from a user perspective. Any help or similar issues encountered?
Control_Next: This is probably just the tab-order for the controls on the dialog. See the Control_Next column of the Control Table. You need to find a way to visit each control of the dialog in sequence and sort out so there are no loops or double links.
TAB Order: In the dialog in question (launch the setup and get yourself to the FinishedForm dialog), try hitting TAB repeatedly to see what happens. It might work, but you might see the control order being messed up so TAB unexpectedly moves around the dialog haphazardly going in "reverse" selecting a control already visited or similar.
Fix: Fixing this depends on what tool you are using. You can "test fix" directly in the final MSI using ORCA or a similar tool to edit the Control Table directly (just open the MSI and do it). The real, lasting fix will be in the sources used to compile the setup. WiX, Installshield, Advanced Installer, Visual Studio Installer, or whatever tool you are using. Exact fix depends on tool. A screen shot of the Control Table content could give us the clue we need.
(combining comments into an actual solution)
If you're using the common script EnableLaunchApplication.js within a Visual Studio Installer project, then the 2810 error code is most likely caused by a single line within that script, along with a recent Visual Studio update.
The fix, as mentioned by user Olaf:
in the EnableLaunchApplication.js I changed the line INSERT INTO 'Control' ... and replaced the value 'CloseButton' with 'Line1'. – Olaf Jan 9 at 14:16
With the entire corrected script linked by user Shangwu:
Here is the latest JavaScript without causing error 2810. stackoverflow.com/a/59888956/6079057 – Shangwu Jan 24 at 0:49
The underlying reason can be found in answers by Adam cosby and Stein Åsmul.
I actually had the same problem and my Control Table was over populated just as you mentioned above. I beleive it was related or at least co-incided with the Visual Studio update from 16.3 to 16.4.2. For me I used the Visual Studio Installer too and on the older version of VS it compiles fine but the same commit number on a different machine with the new version it causes the same issue and the Control Table has a lot more Control_Next entries populated. Still not sure how to fix yet though in the source.
Edit:
Ok I discovered the problem. The issue with it now populating more of the Control_Next I can only put down to a the update. However, the automatic entries put in by Visual Studio would have been fine but I realised we had the MSI launch the exe after install using this: Visual Studio Installer > How To Launch App at End of Installer technique.
That meant I was injecting and modifying the Control_Next and thus caused the loop of Control_Next to be non circular. It is worth noting that the Control_Next is basically the tab order of the MSI screen and it must always be closed (imagine the tab without anywhere to go).. Anyway, it was ultimately caused by us modifying on the post build process the Control_Next to add in the checkbox. After working out the last entry on a build without our code running i just modified the original last entry and then slotted in out one there. Now it works fine.
Hope this helps
Essentially, I encounter the same problem as the question below, except that the accepted answer does not resolve it. I have neither warnings nor errors in the Error List:
See complete tooltip error message for Data Flow SSIS element in Visual Studio
Similar to the question noted above I can see a truncated warning message on the Data Flow design surface.
However, no corresponding warning is visible in Visual Studio's Error List view.
How can I view the entire warning?
This is a bit misleading from Visual Studio and could have been handled better. The long and the short of it is that the Error List window lists only messages that are related to build issues.
The warnings and errors that you see in design time are related to the execution flow. In other words, a package can be built correctly but is designed in such a way that it will generate an error. For more reading:
MSDN: Cannot see errors or warnings in SSIS - why ?
SQLServerCentral: Cannot see errors or warnings in SSIS – why ?
You will need to run the package in debug mode and then go to the Progress window. From there, you can see all messages (e.g., information, warnings, errors, etc.). Some messages may be so long that they cannot be seen. For those messages, you can click on them and paste them into your favorite text editor.
Note: when you stop debugging, the Progress window changes its name to Execution Results and the error List window becomes available.
Update
Per Hadi's follow-up comment, I was initially able to re-create the OPs problem by just modifying an existing package to create the warning message. I then built and ran the project with without receiving any error messages.
Now, after having left the office and shutting down Visual Studio, I am unable to recreate the error. The Error List window now populates with the messages. I tried building a new package from scratch without any luck either. My best recommendation at this point would be to, as with all Microsoft products, restart the application if it is not working as it should be.
This text truncation issue/bug is not just tooltips.
It's in SSIS Toolbox (description box at bottom) - no way to see the entire text describing the task/component (if not too big you can increase the width of the pane but that is not really acceptable).
(VS/SSDT 2019)
Many things to try
Try to change the combobox selected value from Build + Intellisense to Build only
Open and close the OLEDB Source by double clicking on it, since you tried to build the package the warnings disappears from the Error List, you must revalidate the component to show them
Try to update the Visual Studio 2017 to the latest release
When I ignore specific errors in "Errors in Solution" window, Resharper remembers this setting.
I tried to reboot and restart Visual Studio, the ignored errors stayed ignored. Now I wanted to pass the ignored errors list to another programmers in the team by putting some setting file under version control. But I could not find where does Resharper store which errors are ignored.
I have the following versions of SW.
Visual Studio 2012
JetBrains ReSharper 8.2.1 Full Edition
Build 8.2.1000.4556 on 2014-05-19T10:12:38
Update:
I removed files in the following folder and the ignored errors reset, all errors became unignored.
%AppData%\..\Local\JetBrains\ReSharper\v8.2\SolutionCaches\
So it keeps the ignored errors somewhere in those files. Still I did not see the way to put it under version control.
Though not related to the exact issue of the original poster, you might have stumbled upon this question looking for the answer below :)
If you've changed the behavior of an inspection from the glyph like this and saved it to a configuration layer and set it to Do Not Show or something else and then saved it to the Team level:
Then depending on where you set the value, Computer, Solution personal or Solution Team, it's stored in a different settings file.
You can then add the Solution.sln.DotSettings file to source control to share these suppression between all team members.
To undo the supression of such warnings, you'll have to venture into the layered options structure of Resharper, which can be a little confusing if you haven't gone in there before.
Then depending on where it's saved, look under the wrench item for the selected layer:
Find the inspection and set it:
In the toolbar to the solution errors window, there should be an export button. You should be able to export all ignored items to xml or html here.
In my control flow window, I have a data flow task that has a validation warning icon on it. The tool tip text displays a general message: "Validation Warnings Occurred". When I double-click to view it in the data flow task window, none of the objects have a validation warning.
It is is difficult to find the warning in the error list window because I have a over 30 connection managers that do not map to my TFS local path and it produces 2 notifications per un-mapped connection manager.
Is there another way to determine where or what this warning is referring to?
I am using VS 2005 Professional with SSIS version 9.00.05000.00
Those warnings sometimes hang around after the issue has been resolved. Try closing and re-opening the package.
Also you can execute the package and review the Output window.