Category "sql-server"

How to use Backup-SqlDatabase with SAS token?

I'm trying to implement log shipping using Backup-sqldatabase command, but SqlCredential is a required parameter for Azure Storage uploads according to the docs

Inserting rows into Microsoft SQL Server using pandas raises precision error

I am trying to insert data into a mssql database. I needed as fast method for this so I set the fast_executemany param to true. The upload works fine for most p

ApplicationIntent=ReadOnly with SQL Server Import and Export Wizard

I pull data down from an Azure based SQL Server every now and then using the SQL Server Import and Export Wizard (which I already know isn't the best way to go

EF core Invalid column name after reverse engineering database using EF Power Tools

I have an API using ASP.NET Core 6 & EF6 and I reverse engineered my database (SQL Server) using the EF Core Powers Tool extension. When I try to insert a P

SQL Server - Regex pattern match only alphanumeric characters

I have an nvarchar(50) column myCol with values like these 16-digit, alphanumeric values, starting with '0': 0b00d60b8d6cfb19, 0b00d60b8d6cfb05, 0b00d60b8d57a2b

Removing leading zeros from a string in SQL Server

i have removed all leading Zeros in my column but what if the same column has a space its replaced by '0'.. Example: batch number has 000123, 0000145 but when t

Using a public key on Azure server, and the private key on-premise

This question is about how to use a public key/private key pair to encrypt sensitive customer data. The data will be input by the customer in a web portal in az

Most current price based on effective date

I am using SQL Server Management Studio and want to show the most current price for every day in a date calendar table. There are two tables: the Calendar table

There is already an object named 'Id' in the database. Could not create constraint or index

im using EF core 3.1 and trying to Update-Database after adding migration, but im getting this error "There is already an object named 'Id' in the database. Cou

Best Method to Delete 12M rows from SQL table

I have a table currently with 100M+ rows of telemetry data. The table often receives duplicate records. I can identify duplicate records using a row_number() pa

Node.js MS SQL transaction

Can anyone help to implement MS SQL transactions in Node.js . I am try to execute multiple stored procedures inside a promise. Method 1 const executeProcedure =

ParquetSharp's UTC adjustment

I am trying to use the ParquetSharp library (https://github.com/G-Research/ParquetSharp) to write some Parquet files from an SQL server database. As the origina

Getting previous month of last year

I want to get the previous month data but of the following year. So if it's May 2022, I want the data for April 2021. Here is what I currently have, but it is s

Getting previous month of last year

I want to get the previous month data but of the following year. So if it's May 2022, I want the data for April 2021. Here is what I currently have, but it is s

Is there a free version of SQL server that has Integration Services Catalog too?

Trying to understand what free version of sql server allows to create Integration Services Catalog for SSIS pacakges. Any help is appreciated. Thanks.

I need to merge data from one table to another, but I have one value that comes from a different table

This is my code MERGE OrderDetailsStructure AS Target USING SalesOrderData AS Source ON Source.WebOrderNo=Target.WebOrderNo WHEN NOT MATCHED BY TARGET THEN INSE

Unable to download SQL Server on M1 Mac

I have been trying to download SQL Server on my Mac with an Apple Chip. I've been following the steps that include downloading docker and entering code into my

How to upload whole Excel range of data to SQL server using VBA (without Wizards or looping row by row)?

I am trying to upload a range of data in excel (same structure as target SQL table) to a table in SQL server using VBA. I do not want to loop row by row but tra

which is best using delete or truncate when i need to delete all data from table?

I work on sql server 2017 I need to delete all rows from table student_course but I don't know which is best for use delete from student_course OR truncate tab

Subscriptions are not creating in the report server database

I have written the code to create the subscriptions by adding the reference to ReportService2010.asmx. Please see the below screenshot for code and result [Id =