Category "sql-server"

Getting timeout error - increase the send timeout value on binding

WCF service returns timeout error as below. The request channel timed out while waiting for a reply after XX:XX: XX increases the send timeout value on binding.

MS SQL: extremely slow query with 4 OR condition, but each condition alone run very quickly

I have two physical tables: notTempBaseLine with 50k records (index on Version, SrcDimension2_) notTempTrans with 400k records (index on BaseLineVersion, Dimens

SSIS - package works in VS, fails with "Failed to compiled scripts contained in the package". There are no script objects in the package

VS2017, Deploy to SS2016. Package runs without any errors from VS. Project deployment to a server that previously had package deployments only - we're moving to

Using variable arrays in models

Is it possible to define an array in the vars section and use it inside the SQL syntax of a model? Something like this dbt_project.yml: vars: active_country_c

SSIS Alternatives to one-by-one update from RecordSet

I'm looking for a way to speed up the following process: I have a SSIS package that loads data from Excel files on a weekly basis to SQL Server. There are 3 fi

ADF copy activity - ignore the new columns in source without throwing an error

I have a pipeline that copies data from source (dynamics) to SQL server datawarehouse. There is a ForEach activity which iterates over the list of all the table

"Authentication failed for user" when running prisma db pull on a SQL Server database

I am trying to import a SQL Server database into prisma using to prisma db pull command. I created a new DB user with proper rights (that I can log in to SQL Se

Connectionstring: is it the right form?

I'm new to SQL Database C# projects and I have a problem with connecting to my database in a windows form application which is a single user app and I want to u

Validate SQL Server database backup path permission programatically before performing backup

I worked on a screen from which we can save the backup directory (C:\Program Files\Microsoft SQL Server\MSSQL12.SQLEXPRESS\MSSQL\Backup) to be able to perform

I have a SQL Table with employees and a timestamp for their every action. How to calculate how much they worked, and how much they idled (20min gaps)?

I have a very simple query that looks like this SELECT Username ,FORMAT(Timestamp, 'MM/dd/yyyy') as Date ,FORMAT(Timestamp, 'hh:mm tt') as Time FROM

Cannot restore SQL Server 2008R2 database

I took a backup of the database on a disk from a server that I do not have online access to. Trying to restore the database on my local machine using: RESTORE

How do I send query output from mssql-cli on a Linux machine to a text file on that machine in CSV format?

How do I send output from a database query executed in mssql-cli (the Microsoft SQL command line interface application) on a Linux machine to a text file on tha

SSRS avoid WHERE clause if select all is selected

I am working on an SSRS report and a part of my sql query is like WHERE SuperVisorId IN (@SupervisorIDs) AND CreatedDate> @StartDate where the @SupervisorID

how to get no of dates appear between Fromdt to Todt and fetching thouse dates in column

![enter image description here][1] I have table called tbl_monthly_leave in below table i am trying to take dates between fromdt to Todate like (Fromdt , Todate

Can I set a default value for field.types when using dbWriteTable?

I'm trying to write a dataframe to SQL Server using the following line dbWriteTable(conn,"r_test_upload",df, field.types = c(longnotes ="varchar(max)")) By d

Alternative for Cartesian and Cross Join

I want to output all the possible combination in two tables without using cartesian join or cross join. Is this possible?

How do I read SQL stored procedure data through pyodbc and get results into a dataframe?

I have a stored proc in SQL Server called test.storedproc My py script is as follows import pyodbc import pandas as pd conn = pyodbc.connect('Driver={SQL Server

Making database mdf work across different computers

I know this is kind of a stupid question but it gives me a lot of problems. Me and my partners in college projects have a lot of issues making the database mdf

Return smalldatetime value from scalar function SELECT query

I'm looking to create a scalar function in SQL Server (2017) that leverages a calendar table I built awhile back in order to calculate and return a date a given

Remove banned words then collapse the data

Gets 'exact' banned words matched against a set of blog comments. It then creates a result set collapsing the banned words into the owner (the blog comment) sho