First  |  Prev |  Next  |  Last
Pages: 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
Query to find when a total is hit
We are trying to get some statistics on our Inventory people to see if they are issuing material to work orders on time. My work order table has a field that shows the last transaction date of the order, but if Inventory issue all the material then has to issue more because of scrap later they get dinged as be... 28 May 2010 09:20
Conditional UNION
I have a stored procedure that I want to do a UNION ALL if a parameter value is passed. I have tried this and I get 2 errors as follows: Incorrect syntax near the keyword 'UNION'. Incorrect syntax near 'END'. The stored procedure is too large to paste but the concept is shown below. Any help is appreciate... 27 May 2010 20:23
Return value from stored procedure that returns a recordset
I need a stored procedure that returns a recordset and a return value, for example, (oversimplified, of course) CREATE PROC test_proc as begin set nocount on declare @err int select * from customers select @err = @@ERROR set nocount off return @err go The stored procedure will b... 27 May 2010 19:18
Person's age based on DOB
I have a table called member, in which contains memberid and dob. How can I calculate memberid's age based on DOB Thanks, qjlee ... 29 May 2010 19:02
Help with query for consecutive years
I have a table that contains donation data. What I want to do is pull records based on if they gave $1000 or more for 3 or more consecutive years or more. The years in the table range from 2005 to 2010. I'm running SQL Server 2005. I've included some sample data to put into the table. Can anyone help with this... 27 May 2010 23:38
Help with Query
I want to run a query to exclude all Projects from the pjproj table EXCEPT those starting with and L, C, 08, 09, 10, 11, 01PM and 05PM I tried something like below but that did not work. select project from pjproj where project not in ('L%', 'C%', '08%', '09%', '10%', '11%', '01PM%', '05PM%') Id appreciat... 27 May 2010 01:41
partition wizard
http://www.partitionwizard.com BenNevare wrote: After you create a partition function and a partition scheme you can partition 03-Dec-07 After you create a partition function and a partition scheme you can partition an existing table by dropping its clustered index and creating this clustered index agai... 26 May 2010 04:50
Change Tracking Help?
I have a table with a varchar column and datetimeoffset column. SQL Server 2008 (not R2) Change Tracking is enabled on the database and the table and column-tracking is enabled. On one DB connection, I inserted 3 rows. On a different connection, I updated 1 row's varchar and datetimeoffset. I want to know w... 2 Jun 2010 10:56
Error Sorting Strings
I'm trying to sort the below table by numbers first, then string-only records. The numeric records will come first, a double digit "10" sorts before a single digit "4", etc. I've tried several suggested methods but I'm getting a string conversion error. Can someone take a look at this DDL and explain how can I ... 26 May 2010 19:12
PIVOT data
I'm trying to get the first result pivoted so that the each of the 6 type of permissions show up as individual columns. But looks like I''m missing something since there is no real aggregation. Can someone help me? The Result of the first query looks good but each of the permissions results in a row which is n... 27 May 2010 18:11
First  |  Prev |  Next  |  Last
Pages: 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47