Viewing 15 posts - 5,026 through 5,040 (of 8,731 total)
You're missing the SELECT.
And BTW, I suggest to remove the scalar function if possible. We can help you build a faster option.
April 10, 2015 at 8:45 am
That's weird. The image is hosted in here.
Does anybody else have the same problem?
EDIT: Original source of the picture in here: http://www.moef.dk/fishfingers/
April 9, 2015 at 6:09 pm
You're assigning a string to an integer variable.
April 9, 2015 at 4:23 pm
This article by Wayne Sheffield should help you to get what you want.
http://www.sqlservercentral.com/articles/comma+separated+list/71700/
April 9, 2015 at 4:05 pm
Calling a scalar UDF inside another scalar UDF is a call for disaster.
Sean mentioned that this could be done in a single statement because inline table-valued functions are pretty fast....
April 9, 2015 at 3:48 pm
Or maybe like this:
SELECT String,
LEFT( Phone.number, CHARINDEX( '''', Phone.number) - 1)
FROM (VALUES( '@City=''New York'', @Phone=''2035551212'' (10 characters, no dashes)'),
...
April 9, 2015 at 3:33 pm
I was expecting an advice from Grant involving a kilt. 😀
Seriously, now.
- Try to be very organized as your time is very limited.
- Measure the time...
April 9, 2015 at 3:27 pm
Something like this should help.
SELECT String,
SUBSTRING( String, Start.Position, CHARINDEX( '''', String, Start.Position + 1) - Start.Position)
FROM (VALUES( '@City=''New York'', @Phone=''2035551212'' (10 characters, no dashes)'),
...
April 9, 2015 at 3:08 pm
I finally found Dwain's secret.
April 9, 2015 at 12:06 pm
As long as the columns just have DEFAULTs assigned, you can treat them as any other column.
April 9, 2015 at 10:18 am
Just as a suggestion that might not solve anything.
I'd recommend you to use QUOTENAME() instead of inserting the brackets yourself.
CREATE TABLE dbo.Areyoukidding(
My_ID int,
...
April 9, 2015 at 10:03 am
You can connect with SSMS to any version of SQL Server (AFAIK), but you might be missing some options due to compability.
You can restore a backup from 2 previous versions,...
April 8, 2015 at 2:21 pm
This might get you started.
WITH SampleData(CustomerID, VisitDate) AS(
SELECT *
FROM (VALUES(908,'2012-07-28 00:00:00.000'),
...
April 8, 2015 at 2:19 pm
Thank you all for your help.
After a quick speed test, I got the following execution times after 10 executions for one million rows.
-----------------------------------------------------------------------------------------
|Version | 1 |...
April 8, 2015 at 1:03 pm
CELKO (4/8/2015)
I have a column which needs to be 9 digits long. The first four digits are independent from the other digits. The following digits need to be 5 and...
April 8, 2015 at 12:26 pm
Viewing 15 posts - 5,026 through 5,040 (of 8,731 total)