I have used this query but it gives me percentage of only single project. Answer It is a little unclear what you want. If you want the proportion within a project: If you want the proportion over all projects:
Tag: ssms
Error in SSMS when running query from SQL On-Demand endpoint
I am attempting to pull in data from a CSV file that is stored in an Azure Blob container and when I try to query the file I get an error of File ‘https://.blob.core.windows.net/&…
Find the max date to last one year transaction for each group
I have to query in sql server where I have to find for each id it’s volume such that we have last 1 year date for each id with it’s volume. for example below is my data , for each id I need to query the last 1 year transaction from when we have the entry for that id as
How to group data if difference between rows is mothe than 1 minute
Im trying to create a new table on SQL which will have summarized data. For example. In the original table i have this data: If you see rows 9, 10 and 11 they are consecutive, so i want to group them …
Is there a way to separate query results in SQL Server Management Studio (SSMS)?
I got a simple query which return a results from an OrderLine table. Is there a way to visually separate the query results to make it easier to read, like in the image shown here? Results: Answer
Join repeats rows too many times
List the employees (first and last name in same column), that work in retail or food and drink. Include the building they work in and shop type. This is what I have. Whenever I run it everything repeats so there’s over a hundred rows now. Can anybody help me? EDIT I’ve tried various joins for this to make this work
Joining two tables when one table has multiple corresponding values
For some background, what I have is an ordering system that populates a database. In the database there are two tables, order_Parent, order_Children. order_Parent contains broader information such as ID, shippingDesination, createdBy, highPriority. There are more columns but the ones that I am focused on are the ID column and highPriority for order_Parent. When looking at the order_children table there
Get direct hierarchy in SQL without siblings of searched id
I have a pretty simple table called Types which contians ID, ParentID and Name. What I need is to get the full hierarchy from an ID, but without including the siblings of the searched ID. I have written the following SQL, which gives me the full hierarchy of the table (with the topmost parent being id ‘246’): So far, so
System Catalog vs Information Schema
When looking at SQL Server Management Studio (SSMS), which one is better and why? Are there cases where we should use one over the other? I can’t tell the difference between them. Answer INFORMATION_SCHEMA is there for compatibility, it doesn’t expose all the information about objects on the instance. sys however, fully exposes any relevant information, though you do need
How to select and join field with max date?
I have two tables joined on RECID and AAATRANSPORTORDERRECID : AAATRANSPORTTABLE AAALTLCHANGEREQUEST I need to select the record shown from AAATRANSPORTTABLE and join the AAALTLCHANGEVALUE value for the most recent CREATEDDATETIME from AAALTLCHANGEREQUEST. My query is as below: It produces these results: My desired output is Answer The problem is you are selecting max(l.CREATEDDATETIME) in your select query but you