Viewing 15 posts - 12,151 through 12,165 (of 13,469 total)
I would have changed the process to get the data myself. your proc is what my boss calls "putting wings and wheels on a horse"...that is, using one procedure to...
January 25, 2008 at 8:40 am
if the tablename is a parameter, then you must use dynamic sql.
here's an example:
--for users who are too lazy to type "SELECT * FROM"
CREATE procedure sp_show...
January 25, 2008 at 8:24 am
since YEAR() function returns an integer, you could use where Year() > 2003 instead:
select distinct CustNumber
from dbo.InvoicesView
where CustNumber in
( select distinct CustNumber
from dbo.InvoicesView
...
January 25, 2008 at 8:07 am
ok here's a script that creates the statements to delete or truncate where appropriate, and creates the statements in Foreign Key Hierarchy Order.
now remember there are always tables you...
January 25, 2008 at 6:59 am
try this and look at the results:
SELECT *
FROM GRADSTUDENTS G
FULL OUTER JOIN TA T ON G.LOGINID = T.LOGINID
--WHERE G.LOGINID IS NULL
--WHERE T.LOGINID IS NULL
the first rows in...
January 24, 2008 at 6:36 pm
it has to do with mix mode being allowed or not. on express, it's turned off by default, but usually on for production servers.
1) Open up SQL Server Management Studio...
January 24, 2008 at 12:31 pm
when you get a problem where it say find data that is NOT [whatever]
you typically need to use a LEFT OUTER JOIN, instead of an INNER JOIN
the word "join" in...
January 24, 2008 at 12:27 pm
I'm just guessing, but it might be the size of the variable being passed; I'm also assuming your not using the fnParseRTF, since that doesnt need CLR or OLE.
add this...
January 24, 2008 at 12:12 pm
it might be that all your objects are not owned by dbo.
you might have tables that need to be referenced by mike.tablename or webdev.tablename, for example .... instead of just...
January 23, 2008 at 10:26 am
Similar to what someone else posted, this procedure "UGLYSEARCH" is not for use on a production box...if you have a database with 50K columns that are varchar, etc, this is...
January 22, 2008 at 11:23 am
sp_executesql is probably being used after building a dynamic sql string...
the inherent problem with that is you could execute a command which makes data changes, but makes so many changes...
January 22, 2008 at 11:16 am
you could try the stored proc sp_fkeys [tablename]
that will list all the tables that reference any column in the selected table via a foreign key reference...
if you ment a GUI...
January 18, 2008 at 10:14 am
doesn't matter which version of SQL; the script at that link is 2000/2005 compatible.
download the script form the link I posted...it's basically CREATE FUNCTION ProperCase AS....
open SQL Query Analyzer,...
January 18, 2008 at 10:08 am
well let me be more detailed: only one server can use the actual .mdb and ldb files at any one time. restored databases were just copies of hte current data.
1.first...
January 18, 2008 at 8:37 am
no problems at all; we had both servers up and running at the same time for a week; the databases we detatched and reattched were developer databases, so they had...
January 18, 2008 at 8:22 am
Viewing 15 posts - 12,151 through 12,165 (of 13,469 total)