SSMS not flagging basic errors after IIF statement
DMF_SSMS_SQL_IIF_Err.pdf I just wanted to notify Microsoft of an error I believe I found with SSMS error notification. Going thru some scripts, I came across one that had a CASE and IIF in it. I accidently did a typo, no errors, but failed. I then…
Microsoft SQL Server Studio - Dark Mode
Is there any official method to use Microsoft SQL Server Management Studio Studio with Dark Mode?
Trying to Bulk Insert SSN data into an always Encrypted column and is not working. Any guidance please.
I am having trouble Bulk inserting the SSN data from a simple SQL table to a table where I have an always encrypted column. I am not getting any right solution after googling around. Please share if anyone has done similar kind of work. Thanks, SK.
Querying with Filename and Filepath Functions in Synapse Serverless
Hello, I have been reading about using filename() and filepath() in t-sql statements with synapse serverless sql: https://learn.microsoft.com/en-us/azure/synapse-analytics/sql/query-specific-files#functions Wondering if for the following statement:…
i have few snapshot transactions, now i need to put nolock/read uncommit for perticular table
hi, I have few snapshot transactions , now my admin has informed me that put no lock in all tables in snapshot transactions, as it was blocking locking deadlocking with others. so I suggested to put read uncommited instead of snapshot when u are…
Can't figure out why The select list for the INSERT statement contains fewer items than the insert list
Hi everyone, I want to create a stored procedure that will create a table and return value, but I got this message: Msg 120, Level 15, State 1, Procedure sp_Month01_FYCalendar, Line 36 [Batch Start Line 9] The select list for the INSERT…
SQL Server - Question marks inserted with Hebrew collation
SQL Server 2019, Developer edition, Windows 10. The client is SSMS 18. When database is created with Hebrew collation, for example, Hebrew_CI_AI, there is no problem, Hebrew strings are inserted and being read as they are. When database is created…
Exception problem
Hi, I've got issue due to this line below. reader = cmd.ExecuteReader(); Can it be owing to no record returned?
EDI cross reference table
Any suggestions on building and maintaining a table in SQL server that will be used to cross refence for EDI?
query taking long time to match
Hi Team, how to split the query to check data missmatch fint.eabl column if there multiple left joint and taking time to match it query attached
Help with SQL
Hi Experts, Need help in creating calculated columns as below. My Data: Expected Result of two calculated columns: Calculated Column 1 = Previous calculated value in Calculated Column 1 * Rate Calculated Column 2 = RecentMinRent * current…
remove values from string
Hi Expert, how will i remove all the characters from values in sql Create table test1 (id string, details string) insert into test1 values('20kjk','3ddf') Regards
COALESCE and CONCAT Address Line 1 and Address Line 2 separated by a comma
We are trying to COALESCE and CONCAT Address Line 1 and Address Line 2 separated by a comma "," from potentially two data sources. So like...123 Main St., Apt. 101 The first part is easy enough... CONCAT ( COALESCE ( LTRIM (RTRIM…
Parsing First, Last, Middle Initial and suffix from full name
I am trying to extract first last middle initial and suffix from a name field and there's no set pattern please see the pattern of the in my table LOPEZ ROQUE, CARMELINA ORTEGA, GISELLE A A RUSSELL JR, WILLIE C NUNEZ, LILIANA I have looked online and…
The transaction log for database is full due to 'REPLICATION'
Hi! I have a SQL 2019 database that is a member of 3 node always on availability group. It is also the subscriber being populated from a DB2 database. The log keeps filling up and I am unable to shrink or backup.. I get the message: The transaction log…
Data output error using specific scenario in SQL Join
Going though something very strange while running the SQL Query. External Table: dl.tableA has a varchar value "EmployeeSequenceNumber" in column EmployeeSequenceNumber , while doing the inner join with dim.tableB, the query is getting…
Windows 11 SQL Server install error Wait on the Database Engine Recovery Handle Failed
In Windows 11 Machine, unable to install SQL server 2019. I tried multiple versions. but got the following error message. I tried multiple times and restart the machine. nothing worked out. Please somebody help with this. Edition Windows 11…
Unable to add a index hint to a simple query
I have a table with milions of records CREATE TABLE documents ( id bigint primary key, external_system nvarchar(50), external_docid nvarchar(50)) and non clustered filtered unique index CREATE UNIQUE INDEX documents_ix19 ON…
sql query where with condition
Hi, I have a query same but only one of the where clauses differ. If (@accountID = 100) Begin select field1, field2 FROM table1 left outer join table 2 where status = 'x' and ISNULL(accountid, @accountID) = @accountID END Else select field1,…
Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression. 'Document' (RDOC)
how to identify the field that brings more than one value? when I run the store procedure I don't see the error