Viewing 15 posts - 526 through 540 (of 670 total)
Is there a foreign key between the 2 tables? Is it possible for a record to be in the history table but not the linkto table?
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 12, 2010 at 8:38 am
Another concern with leaving deleted records in the table is primary key issues. If a user enters a record that was previously deleted, it will fail on the primary...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 12, 2010 at 7:02 am
I assume you want to delete the records from wce_history.
delete h
from wce_history h
join...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 12, 2010 at 6:20 am
You're going to need to be more specific on what you want. Can you provide table layouts, sample data and expected results? See the first link in my...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 9, 2010 at 9:04 am
select *
from #orders o
inner join (select orderLocation_FK, order_FK, max(orderLocationHistoryTS) orderLocationHistoryTS
...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 9, 2010 at 7:21 am
Are you looking for this? I think there's a better way to write this, but I want to make sure I have the correct result set first
select * ...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 9, 2010 at 6:42 am
What are you looking for? All records where there was a OrderLocation of Not Processed?
select *
from #orders o
inner...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 9, 2010 at 6:20 am
I re-read your problem. See how this works? I found this concept from another thread on this site. I'm not going to take credit for all of...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 7, 2010 at 3:07 pm
I think you just did!! Glad I could help!
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 7, 2010 at 2:08 pm
we're going to need a little more than this. Can you provide table layouts, sample data, and expected results? It'll be better than us guessing at what the...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 7, 2010 at 2:05 pm
here is the setup that I am using. The final query returns all insurers regardless of activity. Then if the activity is in the year 2010 it is...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 7, 2010 at 1:59 pm
That won't work since it will only return 2010 data. You need to add the filter to the sum statement. Keep in mind that since there is no...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 7, 2010 at 12:41 pm
I'm not sure what you did or what you are looking for. Can you post what you did? If you are looking for all records for the Year...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 7, 2010 at 12:24 pm
what are the constraints on the new table? You will probably end up with something like Field1 not in (1,2,3) and Field2 not in (4,5,6), etc...
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 7, 2010 at 12:14 pm
not really sure what your question is. Can you pare down your code and add a little more detail to your question?
For better, quicker answers, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
July 7, 2010 at 12:10 pm
Viewing 15 posts - 526 through 540 (of 670 total)