User Profile
MCarr10
Copper Contributor
Joined 4 years ago
User Widgets
Recent Discussions
Re: Multi-level constraints
I am not able to paste the image. What I can do is share the text of the tables with foreign keys. CREATE TABLE [dbo].[SkillName]( [SkillName] [varchar](50) NOT NULL, CONSTRAINT [PK_SkillName] PRIMARY KEY CLUSTERED ( [SkillName] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY] ) ON [PRIMARY] GO SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE TABLE [dbo].[Trade]( [TradeName] [varchar](50) NOT NULL, [SkillName] [varchar](50) NOT NULL, CONSTRAINT [PK_Trade] PRIMARY KEY CLUSTERED ( [TradeName] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY] ) ON [PRIMARY] GO SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE TABLE [dbo].[Worker]( [WorkerName] [varchar](50) NOT NULL, [TradeName] [varchar](50) NOT NULL, CONSTRAINT [PK_Worker] PRIMARY KEY CLUSTERED ( [WorkerName] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, OPTIMIZE_FOR_SEQUENTIAL_KEY = OFF) ON [PRIMARY] ) ON [PRIMARY] GO ALTER TABLE [dbo].[Trade] WITH CHECK ADD CONSTRAINT [FK_Trade_SkillName] FOREIGN KEY([SkillName]) REFERENCES [dbo].[SkillName] ([SkillName]) GO ALTER TABLE [dbo].[Trade] CHECK CONSTRAINT [FK_Trade_SkillName] GO ALTER TABLE [dbo].[Worker] WITH CHECK ADD CONSTRAINT [FK_Worker_Trade] FOREIGN KEY([TradeName]) REFERENCES [dbo].[Trade] ([TradeName]) GO ALTER TABLE [dbo].[Worker] CHECK CONSTRAINT [FK_Worker_Trade] GO1.3KViews0likes1CommentRe: SSIS Excel Connection Manager error
Based on the last error message I would say it is a 64-bit vs. 32-bit issue. SSIS is probably one and Office 365 is the other. I am not sure which is which in your case. The remedy is to download the missing Microsoft Engine redistributable. https://www.microsoft.com/en-us/download/details.aspx?id=54920 If SSIS is 64-bit but Office 365 is 32-bit then you need to install the 64-bit version. If Office 365 is 64-bit but SSIS is 32-bit then you need to install the 32-bit version.3.8KViews0likes2CommentsRe: Error syncing Excel query to Access db: The operating system is not presently configured to run this
Based on the error, Office might need to be updated. Hope the link below helps. https://support.microsoft.com/en-us/topic/error-the-operating-system-is-not-presently-configured-to-run-this-application-when-trying-to-use-access-database-engine-odbc-interfaces-fc268e32-d828-4731-86a9-3c6279285aba1.1KViews0likes1CommentRe: Join different table columns into one using Azure SQL
This question is old and I am sure you already found a solution. I thought I would post a solution in case someone else has the same question. The tables needed to be unioned together. Because each table contains unique data, union all is the more efficient way to go. SELECT [Location] ,[Date] ,SUM(TableACount) AS TableACount ,SUM(TableBCOunt) AS TableBCount ,SUM(TableCCount) AS TableCCount FROM ( SELECT [Location] ,[Date] ,TableACount ,NULL As TableBCount ,NULL As TableCCount FROM TableA UNION ALL SELECT [Location] ,[Date] ,NULL ,TableBCount As TableBCount ,NULL As TableCCount FROM TableB UNION ALL SELECT [Location] ,[Date] ,NULL As TableACount ,NULL As TableBCount ,TableCCount FROM TableC ) AS X GROUP BY [Location], [Date] ORDER BY [Date] ASC, [Location] DESC1.3KViews0likes0CommentsRe: Always On replica prefered FailOver Order
There is a limitation that only 3 nodes can be configured for automatic failover. Hopefully the links below are helpful. The topic of the link below is automatic failback, but it presents the failover side as well. https://charbelnemnom.com/automate-failback-for-sql-alwayson-availability-group/ This link contains some helpful information on configuring AO failovers. https://docs.microsoft.com/en-us/sql/database-engine/availability-groups/windows/configure-flexible-automatic-failover-policy?view=sql-server-ver15757Views0likes0Comments
Groups
Recent Blog Articles
No content to show