View to Fill Time Gaps in SQL
I am working on onboarding data onto a platform which can visualize data only at hour grain or day grain. I provided them with connection string to my db and that system pulls data from it and shows it as a graph and do a bunch of slice and dice operations. Problem is its chart based visualization works only at hour or day grain and my data is once every 4 hours. It considers this as missing data and the graph comes up as dots instead of continuous line. So I thought of exposing a view which can time gap fill data at hour grain with the last data used and the platform can use it. This is presenting with some issues.
Create Index without name while creating table
I have following temporary table with index. This works since I expolicitly name it as “IX_#Final_1”. How do I create the index without explicit name?
How to Replace any instance of item in a SQL Database
I’m working with an MS SQL Database where the object ‘Target’ is extensively used. It appears in various forms such as a field name (Target), a variable (@Target), and within several table-valued functions.
SQL server 2019 datetime column in where condition
In sql server 2019 version when we are using datetime data type column in where condition it’s giving 0 records.
How to find rows in table per group that are not in another group of the same table
I have a table of products which lists all the products held within our branches. This includes whether a product is a PackingLine one. A product either is or is not a PackingLine, it doesn’t change per branch, however not all branches have every packing line. I need to find those branches and products. A simplified version would be
Small percentage of parameters cause very slow queries on SQL Server
I have two tables (in an Azure SQL database):