Viewing 15 posts - 2,866 through 2,880 (of 7,191 total)
Sergiy (1/6/2016)
Those who know how to design databases and program in SQL...
January 6, 2016 at 3:23 am
Sergiy (1/5/2016)
The fact is - CTE is a foreign construction in SQL.
Is that a problem? Should the language be kept in a glass case and never added to or...
January 6, 2016 at 2:08 am
Edvard
Not directly, no. You could do some additional fancy date arithmetic to subtract Saturdays or Sundays, or you could create a Dates table, and join to that, counting only...
January 5, 2016 at 7:58 am
Nicole
You say it's for ETL processing - are you using SSIS? If so, you might consider weeding out the invalid values in your data flow. There are ways...
January 5, 2016 at 3:21 am
Nicole
You say it's for ETL processing - are you using SSIS? If so, you might consider weeding out the invalid values in your data flow. There are ways...
January 5, 2016 at 3:21 am
One way to get round it is to dynamically set the properties of the connection manager, instead of the data source.
John
January 4, 2016 at 8:28 am
Try this. It relies on there being a unique key in your table, which I've represented by the column OrderbyThisCol.
CREATE TABLE Names (
OrderbyThisCol int NOT NULL PRIMARY KEY
,Name varchar(10)...
January 4, 2016 at 5:37 am
Satheesh
What error message do you get when the connection fails? Is there anything in the errorlog? What protocol are you using both locally and remotely to connect with...
December 24, 2015 at 4:58 am
I prefer CTEs to subqueries because you can get all the definitions out of the way at the front, and then the main query looks more neat and compact.
John
December 24, 2015 at 2:41 am
It's partly about preference, and partly about using the right tool for the right job. If a CTE is unnecessary, don't use it. If you prefer subqueries, don't...
December 24, 2015 at 2:01 am
I suppose you could create the table on the fly if you don't want a permanent one. This is a common technique. It would be a bit fiddly,...
December 23, 2015 at 10:16 am
Here's one way of doing it. It may or may not be the most efficient. Create a table of dates with one row for each date between the...
December 23, 2015 at 9:30 am
The trigger fires once per update, not once per row updated. It will have an adverse effect on performance if you use a loop instead of a set-based update....
December 23, 2015 at 9:21 am
murtzd (12/22/2015)
I can't get that piece of code to work.
Error messages? Unexpected results?
What is the % sign in the join?
Please see here. It's so that we only consider...
December 22, 2015 at 6:02 am
Shazme
It's not always a problem if the database collation doesn't match that of the server. You usually get issues if your code creates temp tables and joins to...
December 22, 2015 at 5:50 am
Viewing 15 posts - 2,866 through 2,880 (of 7,191 total)