Forum Replies Created

Viewing 15 posts - 10,261 through 10,275 (of 13,469 total)

  • RE: list tables and columns referenced by functions, stored procs, views

    sp_depends yourtable

    select * from sysdepends where object_id(id) = 'YourTable'

    this will accurately identify any dependencies help by views or functions and is accurate for most procedures; however, because of a feature...

  • RE: How to update a table using multiple joins

    your joins look a little funky, and you are missing an AND in the join.

    pseudo code sucks, because it hides real issues(table1,table2,etc...column1,column2, etc)

    ...you should show the real code you were...

  • RE: How to split a string into two different substring

    the trick is to use the CHARINDEX function to find the dash....potentially it could be in a different place than your example

    this might get you started:

    create table #example(SOC_MAPPING varchar(1200) )

    insert...

  • RE: Performance issue with temporary table

    using a function on a column in the WHERE statement slows things down because it's not SARGable...that is a searchable argument that can be take advantage of the indexes...

  • RE: Windows 7 and SQL Server 2005 Standard

    That's weird Mark;

    SQL 2000 would automatically dummy itself down to the Desktop version if you installed SQL 2000 Standard or Enterprise on a non-Server OS, but every time I've ever...

  • RE: pull all values from reference table

    shouldn't you just change the first table in the query to be refTrkNonAdmitReason as the base table, and join everything to that in order to get zeros for all reasons?

    SELECT...

  • RE: Missing entries report

    i am completely spoiled by 2005 i swear.

    assuming you create this tally table complements of Jeff Moden:

    --===== Create and populate the Tally table on the fly

    SELECT TOP 11000 --equates...

  • RE: Missing entries report

    oops didn't notice the 2000 forum; easy to fix; here is the same solution, but witht he TallyCalendar as a correlated subquery instead:

    DECLARE @mn datetime,

    ...

  • RE: Missing entries report

    ok i think i followed your logic; this was fun for me. made me think hard about how to get a calendar in 12 increments.

    correct me if i'm wrong, but...

  • RE: how to combine two queries in sql server

    if the first query returns 6 rows, and the second returns 1, that is the results of the cartesian join we warned you about.

    you have to determine what joins the...

  • RE: time difference HELP!!

    you'll want to use the datediff function; but would you want a value in minutes if the difference was say 1823 minutes, or would you rather see 30 hours and...

  • RE: error creating a linked server from sql server 2005 to 2000

    can you connect with SSMS to the server 'targetsvrname' as the user sql2000login?

    if the server was rebuilt, the login sql2000login might not exist and need to be re-added.

  • RE: how to combine two queries in sql server

    does this work? if your SQLs return just one line, this look good, otherwise it'd do a cartesian join unless you add a where statement.

    SELECT

    X.MemoryPages, X.MemoryAvailableMbytes, X.ProcessorTime, X.[DateTime], Y.MemoryPages_1

    FROM

    (

    ...

  • RE: error creating a linked server from sql server 2005 to 2000

    RP this is the syntax i've always used,a dn works without any problems for me:

    here i'm connecting to a SQL instance named "DBSQL2K5", but for fun, I'm aliasing it as...

  • RE: Windows 7 and SQL Server 2005 Standard

    both Standard and Enterpise will only install on server versions of windows: 2000 Server/Advanced Server, 2003 Server, etc.

    Express, Professional, Workgroup, etc versions will install on any Windows Operating system, as...

Viewing 15 posts - 10,261 through 10,275 (of 13,469 total)