13

Assuming that the error happens during the build process, and that you do not have any actual syntax errors, and it is a simple :r path\to\file.sql then the error also occurs when the file being imported does not exist. Please check the location of the file. If you did not provide an absolute path, then the path will be relative to the solution folder (at ...


9

I played around a bit to figure out what these settings do... when I commented, I only mentioned what our settings are without understanding them; I'm not the project lead for our migration to Database Projects, so I wasn't familiar with the minutiae of this stuff. The Model Aware property needs to be set to True. This property is poorly documented, but ...


5

You need to specify a SqlFacet for the return value. This is the same as specifying a SqlFacet for an input parameter, except you prefix it with return: For (max) length, use MaxSize=-1 in the SqlFacet attribute, example follows: using System.Data.SqlTypes; using Microsoft.SqlServer.Server; public partial class UserDefinedFunctions { [SqlFunction ...


4

have built my SSIS packages to check and make sure that the day isn't a holiday by comparing the date to a table that contains holidays. You can have your 1st job step as IF EXISTS (SELECT 1 FROM HolidayTable WHERE Date = GETDATE()) begin RAISERROR ('There is nothing to run as today is holiday !', 16, 1) end else print 'The job can run .. as ...


4

I stumbled across this blog post, which while the author didn't have the exact same problem as me, our issues seemed similar enough that his fix might work for me to. I downloaded the SSDT-BI 2012 package and installed it, and lo and behold, things work fine again. I'll just not even consider that somehow things worked fine for a year or more without ...


4

I have VS 2012, 2013, 2015 installed and faced the same issue. After looking in the Event viewer it was apparent that it was 2015 VSTA causing the issue. This solved it for me without re-installing everything.... Uninstalling: Microsoft Visual Studio Tools For Applications 2015 Microsoft Visual Studio Tools For Applications 2015 Language Support ...


3

You're looking in the correct menu for the Locals (Ctrl+Alt+V, L) window. The issue is that this is a context sensitive menu. With an SSIS project open, I see a similar menus as you under Debug/Windows However, if I set a breakpoint and launch the debugger, then I'll get the full suite of debugging windows available under the Debug/Windows menu


3

Valid Error This is because :r somescript.sql isn't valid sql. You are seeing a syntax error, which is precisely what the error message states. SQL80001: Incorrect syntax near ':'. SQLCMD Mode The post deployment script is executed under SQLCMD Mode. The sqlcmd utility lets you enter Transact-SQL statements, system procedures, and script files at ...


2

apparently this is because I need to download and install Microsoft SQL Server Data Tools - Business Intelligence for Visual Studio 2013 http://www.microsoft.com/en-us/download/confirmation.aspx?id=42313 I will get this done and if it all works I will accept this answer.


2

The order in which Stored Procedures are created in SQL Server should not, in most cases**, cause any errors. If dependent objects do not exist at the time of CREATE PROCEDURE or ALTER PROCEDURE, you should merely get a warning about SQL Server not being able to register the dependency in the meta-data (i.e. sys.sql_expression_dependencies). If you are ...


2

Certainly appears you can do that in Visual Studio 2012. I just created a Database Project "database1", then added another database project to the same Solution, named "database2". I then right-clicked the "Database1" project, clicked "Add Database Reference" and selected the "Database2" project. Then, under "Database Location" I chose "Same Database".


2

It looks like your installation of Visual Studio 2015 registered itself as the editor for script task instead of what it was before. What you need to do is make sure the right editor is used again to edit script components. You could get away with re-registering the correct components for use with script tasks, but it could be needed to remove some ...


2

I know this is an old question, but I want to throw this out there in case anyone else happens upon this post. Create a "scripts" folder in your SQL Database Project, and add a Pre-Deploy script that will create the temporary table in Oracle; right click on the script and set the Build Action to PreDeploy. I know it's not the most elegant solution, but it'...


2

Here is and article explaining a good way to do this will little extra effort. The article describes comparing the SQL Database Project with the EF generated LocalDB to persist schema changes. Use EF to make schema/entity updates like you would normally in you development workflow. The use the EF database as your comparison DB to update your SQL Database ...


1

Short answer, maybe. If being able to open a previously saved .scmp file makes life easier through time savings or consistency, I'd say it's worth saving. With a schema compare window open, there is a cog wheel icon which opens the Schema Compare Options dialog. There are quite a few options under General and Object Types. Some are selected, others are not ...


1

Copying and pasting SSIS packages can lead to a few issues. It sounds like you have simple packages - a dataflow with a source to destination. Generally, those don't have the hangup I've run into but I have seen situations where people were inconsistent in their definition of data types. Email - varchar(40), varchar(80), varchar(120), nvarchar(256) all in ...


1

As this answer on Stack Overflow indicates there is no built in functionality to do what you want but there are alternatives: export your tables to csv files and then import into MySql using LOAD DATA INFILE. This solution does not scale well for large databases or schemas with clobs and blobs that are images or documents. SQL Developer can help you ...


1

I solved my own problem. I needed to grant data reader rights to that database for the user. I do that by right clicking the user name under Security\Logins and choosing properties. In there I go to User Mapping. Make sure the user is mapped to the database being queried and under the Database Role Membership make sure db_datareader is checked.


Only top voted, non community-wiki answers of a minimum length are eligible