First  |  Prev |  Next  |  Last
Pages: 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85
Retrieve Records if a Value is Null/Empty in SQl Server 2005
select Field1, Field2, Field3, Field4, Field5, Field6 from Mytable I need to retrieve records if any of the listed filed value is empty/null. ... 5 Mar 2010 13:58
Export table with Cursor
Hi there, I'm using SQL Server 2008 on Windows Vista x64 In Northwind database I wrote DECLARE @List varchar(50) DECLARE c1 CURSOR READ_ONLY FOR select Table_NAME from INFORMATION_SCHEMA.TABLES where TABLE_TYPE = 'BASE TABLE' OPEN c1 FETCH NEXT FROM c1 INTO @List WHILE @@FETCH_STATUS = 0 BEGIN Print... 6 Mar 2010 09:39
Q;re Descriptive stats
Hi Suppose I have the following data in a column (if is sample data, but the DB I am working with has some specific values to indicate other data properties - I fully accept that there may well be better ways to indicate this). Elapsed Days 1 2 3 4 5 6 7 8 NULL -99999 -88888 What SQL can I wr... 5 Mar 2010 11:42
Opposite to INNER JOIN
There is a simple task - to return the records from table1 where the key table1.key1 doesn't exist in the table2. The first idea was to write it as: SELECT * FROM table1 WHERE NOT table1.key1 IN (SELECT table2.key2 FROM table2) Simple, but it's way too inefficient for sure. Is there some trick that I'm miss... 8 Mar 2010 04:15
CTE with multiple anchors
I have a recursive function that is pretty complicated but there are many anchors. All the examples I see have only one anchor such as this from: ********************************** USE AdventureWorks; GO WITH DirectReports (ManagerID, EmployeeID, Title, ... 5 Mar 2010 15:06
Tivoli Storage Manager 5.4
Officially, TSM Server 5.4 does not support Windows Server 2008 and SQL Server 2008 ... Does anyone know if unofficially it works or not ? ... 4 Mar 2010 16:58
Change management - views that select data from tables in diff
Plamen - thanks for the pointer. I hate to sound dense, but if the synonym could be used to identify a database it would be perfect. However, the article and related links appear to state you can only create synonyms for objects within a database, not the db itself. I need help with the case where the view... 4 Mar 2010 14:41
SQL SELECT Help! (supersets)
Hi. I have an Orders database (orders, products, orderlines tables). What I want to write is, a select statement that, when there is an incoming order (containing let's say 4 products), it shows all other orders that contain at least those products the incoming order contains, or more. Which should be the pro... 5 Mar 2010 06:09
non-equal DRI: a possible new sql feature
(contrived example coming) if i sell christmas trees and hire temp workers each year and i also reward the top sellers how can i enforce sales data within the timeframe the employee works for me? The same guy could work for me each year. I don't want to be concerned having to figure out sales from an Emp that were... 4 Mar 2010 18:05
CLR UDF, how to tell selectivity to the optimizer?
We use some CLR UDFs to process BLOBs. In many cases, the optimizer seems to choose a bad plan because it guesses that our UDF will limit the results much more than it does. For example, when we have a WHERE condition such as OurUDF( Data ) = 1, the optimizer apparently guesses that the number of rows will drop... 4 Mar 2010 18:05
First  |  Prev |  Next  |  Last
Pages: 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85