Here's a few of the new posts today on the forums. To see more, visit the forums.
|
SQL Server 2017 - Administration |
Fetch IP address in query/job - Hi, I am trying to fetch IP address of the SQL Server through Query with below commands and it is working fine. But when I add it in a job it is not fetching/showing the IP. Please help. Select cONVERT(VARCHAR,CONNECTIONPROPERTY('local_net_address') ) select local_net_address FROM sys.dm_exec_connections WHERE SESSION_ID = @@SPID Problem is when i run this […] |
SQL Server 2016 - Administration |
Two beginner Availability Groups questions - Hello experts, I'm an accidental DBA who recently joined a new group, and I'm learning how to work with availability groups. Luckily, the more senior guys are patient, but I want to get up to speed asap and stop feeling ignorant about AGs. I have two noob AG questions I hope someone can help me […] |
SQL Server 2016 - Development and T-SQL |
Case when index scan faster then index seek (see example) - Hi, we had case today where query with index seek provided much worst performance compare to index scan. original query using 40+ union and 5+ intersect ( it is machine build by java script..) I used AdventureWorks2017 to recreate similar scenario Step 1 create nonclustered index IDX_AG_001 on [Person].[Address] (AddressLine1) with(online =on) Step 2 set […] |
Administration - SQL Server 2014 |
Transactions/Second - Hello.Does anybody have a way to identify what transactions ran in an interval (i.e. 1 minute or 5 minute)? I have Solarwinds telling me that the Baseline transaction rate is increasing 10 fold every 2nd minute - i.e theTransactions / second follows this pattern - 100 / 1300 / 100 / 1300......... Obviously this looks […] |
Development - SQL Server 2014 |
SSIS Excecute SQL Task not executing simple T-SQL correctly. - Hello, I have an SSIS package with an Execute SQL Task that runs the following query: SELECT startDate = ISNULL (MAX (c.FileDate), DATEADD (dd, -8, GETDATE ())) , endDate = GETDATE () , fileDate = CAST(FORMAT (GETDATE (), 'yyyyMMddHHmmss') AS VARCHAR(16)) FROM stage.MI_ChildSupportFile c WHERE RecordType = 3 AND RecordSent = 1; There is no […] |
SQL 2012 - General |
How to update status with conflict data where chemical temp table have same chem - How to update status with conflict data where chemical temp table have same chemical Id on temp table #temp ? steps to achieve that 1- get related parts to part exist on temp table #temp that have same masked id from temp table #parts in this case result will be PartId MaskId ChemicalId 200 1000 […] |
How to handle date on temp table when is null or not ? - How to handle date on temp table when is null or not ? I work on SQL server 2012 I using format dd/mm/yyyy I need to handle date on #temp table on both of from date or to date . if i have null on from date or to date what i do if some […] |
SQL Server 2019 - Administration |
SSMS Freezing when Editing SQL Agent Job Steps - I've spent several hours trying to overcome an odd technical bug on two SQL Server 2019 servers. I'm installing SQL2019 on WS2016 with SSMS18.4. Following a tried and tested routine (on previous versions of SQL Server), I've installed Ola Hallengren's MaintenanceSolution.sql and scheduled the SQL backup jobs which work fine. Problem is that when I […] |
cardinality estimation - Just a quick question I'm putting in a new SQL 2019 server and an external consultant has advised that we should not use 2019 compatibility mode as there are issues with cardinality estimation - we should use 2017 compat mode I've googled this and found nothing. has anyone seen this ? |
RTO 15 minutes with differential backups - Hi. I'm working through the official exam reference book for 70-764 by Isakov and some of the sample questions + answers are driving me crazy! One such example is for a question which asks you to come up with a backup strategy to meet a set of requirements, one of these requirements being that the […] |
Recruitment question - Thanks for fielding this question in advance: We are searching for a Microsoft SQL DBA in the NYC area... haven't had any luck sourcing candidates on all the normal job posting sites and LinkedIn. Any advice? |
SQL Server 2019 - Development |
Deleting duplicate records with a CTE - This code is modified from an example I saw. The purpose is to delete duplicate records. WITH DupRecords AS ( SELECT *, ROW_NUMBER() OVER (PARTITION BY fName, EmpID, Department, City ORDER BY ID) AS RowNumber FROM dbo.DeleteDuplicateRecords ) DELETE FROM DupRecords WHERE RowNumber > 1 The table with duplicates is called dbo.DeleteDuplicateRecords. DupRecords is […] |
SQL Group by in STUFF function - I have one question in SQL and would like to take some help from you. I am using the below query to group by based on the test results and then can able to send these results to the recipients. SELECT alertQueue.[Prod No] AS ProdNumber , SUBSTRING(alertQueue.[Prod No], PATINDEX('%[^0]%', alertQueue.[Prod No] +'.'), LEN(alertQueue.[Prod No])) AS […] |
Azure Data Factory |
Blob to ADF to Stored proecure - I'm reading file from BLOB through ADF and I would like to pass the whole content of the file to stored procedure..Is it possible? If so, can somebody give me some pointers? Thanks. |
Analysis Services |
Attribute in the hierarchy display as one value - Hello Friends, I want to display the attributes in a hierarchy as one value in the cube. Just the last leaf level. Please refer the below image. Is it possible to display as '11A Base Maintenance' ? I am wondering if this is possible in cube by adjusting some properties instead of doing through ETL/database. |