|
|
|
|
|
|
|
Question of the Day |
Today's question (by Steve Jones - SSC Editor): | |
Azure Data Studio Server Group Colors | |
I have a number of Server Groups in Azure Data Studio. I can edit any of these groups and there is a list of colors available: I want to add newer, yellow color to this list. How can I do this? | |
Think you know the answer? Click here, and find out if you are right. |
Yesterday's Question of the Day (by Steve Jones - SSC Editor) |
The Broken UDF I have this code on SQL Server 2017: CREATE FUNCTION AddOne (@i INT) RETURNS INT AS BEGIN DECLARE @result INT; SELECT @result = @i + 1; RETURN @result; END; GO SELECT AddOne(3) When I execute this, I get the following error: Msg 195, Level 15, State 10, Line 11 'AddOne' is not a recognized built-in function name. What is wrong? Answer: The schema is not specified in the function execution Explanation: While you can create a UDF in your default schema, you must use at least the two part naming (schema+name) to execute the function. Ref: CREATE FUNCTION- https://docs.microsoft.com/en-us/sql/t-sql/statements/create-function-transact-sql?redirectedfrom=MSDN&view=sql-server-ver16#general-remarks |
Database Pros Who Need Your Help |
Here's a few of the new posts today on the forums. To see more, visit the forums. |
SQL Server 2017 - Administration |
AG upgrade - I will be running the application upgrade process which will run for couple of hours and behind the seen it will make couple of table changes such as create the new table with the field changes and then insert data into the new table from old table and rename it back to same as old […] |
SQL Server 2016 - Administration |
maintenance plan issue - one of our maintenance plan is geting failed with the below error , checked in logs but not able to find any thing The Execute method on the task returned error code 0x80131501 (An exception occurred while executing a Transact-SQL statement or batch.). The Execute method must succeed, and indicate the result using an "out" […] |
SQL Server 2016 - Development and T-SQL |
SQL server help with counting - I am including some sample data to explain the requirement. I need a column that gives the total of Prg1 to Prg6 if the values are different Ex: Need to compare each field data from prg1 to prg6. If all 6 fields have different values (p1, p2, p3, p4, p5, p6), I need the count as […] |
How to replicate data with increasing PK - I have a case where in non prod environment, i will have to replicate existing data multiple times with a increasing PK value. Can anyone please help achieving this without loops or cursors. For example CREATE TABLE Table_A (Id1 Numeric(5,0) not null PRIMARY KEY,Name1 Varchar(20) null,date1 datetime2(7) null) go INSERT INTO Table_A VALUES('1','A1',GETDATE()) INSERT INTO […] |
DateDiff days as column headings - Good Morning Have two tables Customers (Customer_ID CREATE TABLE UHC_customers ( customer_id int NOT null, --Primary key unique values AgeFallGroup varchar(6), InsuranceStartDate Date, Region varchar(20), CustStatus Varchar(10) ); INSERT INTO UHC_customers VALUES (1001, '20-29', '03/25/2022','North America','Active') INSERT INTO UHC_customers VALUES (1002, '40-49', '02/18/2022','Asia','Active'); INSERT INTO UHC_customers VALUES (1003, '20-29', '01/01/2022','Asia','Active'); INSERT INTO UHC_customers VALUES […] |
The step was retried the requested number of times (5) without succeeding. - We have one schedule job which is copying the backup to the offsite server through xcopy. This job successfully run for 4-5 days in a week and failed for 1-2 days due to following error. Executed as user: service_Account. The step was retried the requested number of times (5) without succeeding. The step failed. Sharing […] |
SQL 2012 - General |
Migrating from MS SQL Server Standard 2012 to SQL Server Express 2019? - I'm the IT guy with no real SQL experience. We are currently on SQL Server Standard 2012. Our database is 2gb and we have no jobs that are running. Powers that be don't want to spend the $3k on the SQL Server Standard 2019 license and SQL Express is compatabile with the software we are […] |
SQL Server 2019 - Administration |
SQL Server and Azure Blob Storage - I'm fairly new to Azure Blob Storage. Every once and awhile we will be restoring and the azure database backup file will be in use by another process. From what I understand, I need to break the lease on the backup file, so that my process can then acquire a lease. I'm really looking for […] |
Does SQL cache linked server destination IPs? - We use DNS aliases in our linked servers that point to the server where each database lives. Tonight we moved some databases to new servers. TTL was set to 1 minute before the DNS aliases were changed to the new hosts. There was a view on a separate server that referenced a moved database via […] |
General Cloud Computing Questions |
Cloud path for beginners - Hi, I am in my junior year of an undergrad degree in electronics and communication. Looking for a way to enter the Cloud industry. As I don't belong to the computer science field, what are the basic pre-requisite for starting a career in the cloud? should I start looking for a job after my degree […] |
Azure Data Factory |
Pass Dynamic content from Trigger into pipeline for use - I am needing help in passing a dynamic value from the trigger into the parameters/variables of the ADF pipeline. What I have so far is: A snapshot_date parameter A snapshot_date variable With a Set variable activity where my variable name is snapshot_date and the value is @pipeline().parameters.snapshot_date When I hit Debug at the top, I […] |
General |
Excluding deprecated columns from EF - We have a handful of deprecated columns in a table that is referenced by multiple applications. We were going to remove these columns but there are a couple legacy modules that still reference them and these are not going to be changed. So we're going to leave the columns in the table but we don't […] |
SQL and Feature Flag Use in Software Development - Hi this is Palak Sharma I am in final year of my engineering and I have start developing Software, however I am on the way in this development but I have some confusion in this process that how SQL and Feature Flag play important role in Software Development. I have google for same problem but […] |
Strategies and Ideas |
Data warehouse - how to handle 2 FACT tables? - Hello, I am quite new to data warehousing and was just wondering what people think the best approach would be for the below? We have a star schema in place however I have been tasked to add a new Fact table (the payments one) into our existing SSAS model. I am planning on using the […] |
Integration Services |
How to import updated records from XML files into SQL Database? - Hello everyone, So from last few weeks I was trying to design a SSIS package that would read some XML files that I have and move the data from it to the multiple tables I want. These file contains different nodes like (parent node) and, , (all child nodes of Individual) etc. […] |
| |
©2019 Redgate Software Ltd, Newnham House, Cambridge Business Park, Cambridge, CB4 0WZ, United Kingdom. All rights reserved. webmaster@sqlservercentral.com |