I have a table that returns results like abc yes abc no cdef no cdef no cdef no xyz yes xyz no xyz no sample query with abc as( select 'abc' as b
I have the below query that has only one condition, which is if the companies are included in the table, then mark them as "Yes" under [Competitor] column, if t
After I converted the version from .NET Core 3.1 to 6.0, I figured out that all decimal(10, 5) type columns were automatically rounding the decimal part of the
I am using PowerShell to backup a SQL Server database and use Windows task scheduler to schedule the script Test Run the script manually, it works. Both SQL Ser
Getting this error when using Get Data with PowerBI Desktop to connect to SQL database Microsoft SQL: The ORDER BY clause is invalid in views, inline functions,
I have SSMS 2017 and VS 2019. I was trying to configure SSRS 2017. It says: The database engine instance you selected is not valid for this edition of report s
I have a trigger which declares a table variable. DECLARE @TREarn_aaa table ( aaaID bigint NOT NULL PRIMARY KEY, Bbb decimal (18, 8) NULL, Ccc dec
My SQL Server table looks like this ID a_Toyota a_Mazda a_Nissan a_Kia a_Honda a_Subaru SoldCar CarOrder 1 8000 7000 6200
I would like to do a PIVOT on my table but I don't have aggregation column. SELECT CONVERT(date, DataHora) AS dia, CONVERT(VARCHAR(5), DataHora, 108) A
I have a table of students and classes. I would like to find what classes were dropped from one semester to another (and a similar query for classes added). Stu
I am struggling with the problem with nesting root for every day (it's an element of my table). I'd like to get nested Key: value pair of day from table Day. He
Here is the code of server side i.e of NotificationHub where i intend to add some logic by which i get realtime update from database based on client send value
While trying to run my migrations in a Laravel App I have in an EC2 server, I run into this error message. SQLSTATE[08001]: [Microsoft][ODBC Driver 18 for SQL
I use the layer2 cloud connector to sync between Sharepoint DB (right) and SQL Server database (left). I sync from right to left only. I make a dynamic column o
Write a SELECT statement that returns the LastName, FirstName, and AnnualSalary columns of each instructor that has a unique annual salary. In other words, don
I have a master table and a detail table. Question 1: I would like my view to look like this master1 row, nulls master1 row, detail1 row for master1 master1 row
I have some query in which I am substituting 2 dates in a field "between". SELECT ... FROM ... WHERE o.EventDate between @startDate and @endDate How to make it
I have a table (Table 1) which is a list of employees and data points about them. The data that populated Table 1 is regularly changed and added to in its sourc
Currently, this is the only way I know Create @tempTable1 Insert into @tempTable1 Exec mySP1 input1, input2 Create @tempTable2 Insert into @tempTable2
I have a complex subquery within a query giving me this: Col 1 Col 2 value1 NULL NULL value2 value3 NULL NULL value4 value5 value5 But instead, I need this ou