When I try to shrink one of my db's, I get the following error: "File ID 1 of database ID 6 cannot be shrunk as it is either being shrunk by another process or is empty."
The database is 140GB, of which it shows 40GB free, I just can't get it to shrink. I have done DBCC shrinkfile, and DBCC...
I would like to select top rows by multiple criteria. I have division and dollars, and I would like to select the top 200 from each division by dollars. I keep trying things like this:
SELECT TOP 200 DIV, Dollars
FROM [This Week Data]
WHERE ((([This Week Data].DIV)=11))
ORDER BY [This Week...
I have 11 different databases to query from, each with a different IP address, name, etc. I have installed SDK, the driver version is 3.80. My problem is this:
I have created 11 data sources, 11 entries in the hosts file also, but each data source points to the same host. If I change the...
I have a query which returns about 10,000 rows. One of the columns is dept. My customer would like me to create one Excel sheet per value of dept (all in the same .xls file, about 30 of them). It's easy enough, though tedious, to copy and paste, or create multiple queries, but I would like to...
I can't get the following query to work:
SELECT DIV_NO,ITM_NO, RANK() OVER (ORDER BY ITM_LAST_SH_DT) AS R1
FROM NOKDE.OKIITIO
WHERE ITM_NO= '15310'
It gives me a "Function Rank was not found" error. I thought Rank was an ANSI standard function. There's always the chance our system was...
I have 2 tables that I can't delete from the Relationships window. They have no line between them, they just won't go away. I delete them, but when I show all again, they reappear. It's preventing me from making a change to one of my tables. Any ideas?
Thanks,
Paul
I have several tables which I want to join into one very large table (~950 columns). These tables all have a key to link them, but that key has the same name in all tables. So when I type in:
select a.*, b.*, c.*
from a left outer join b left outer join c
(I've simplified to save space)
I...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.