Forum Replies Created

Viewing 15 posts - 61 through 75 (of 95 total)

  • RE: TSQL Version Control

    Yes...discipline and a "big stick". We've been using VSS for version control of all DDL and sql code for a while now. Periodically our Audit Team does a...

  • RE: DataType Prob

    Just glancing over this quickly...

    You have several attributes in your table ddl as tinyint, however you do an implicit conversion of decimal datatype in your stored procedure.

    I'd guess altering your...

  • RE: weekly report

    create #table

    (

    date datetime,

    hours numeric(10,2)

    )

    --insert some stuff into #table

    declare @start_date datetime

    --set your start date if you want

    select @start_date = min(date)

    from #Table

    declare @results table

    (

    week int primary key,

    hours numeric(10,2)

    )

    insert @results

    select datediff(day,@start_date,date)/7+1 WEEK,sum(hours)

    from...

  • RE: User with limited permissions for distributed app

    Create a view of the table that enforces your access rules.

    If you have your DDL....I could help you further.

    HTH

  • RE: Need Some Simple Stored Proc Help

    If I'm understanding you...this should work...

    Update time_check2

    set TimeLastRun = @mydate,

    TimeNextRun = dateadd(minute,skdDuration,@myDate)

    from time_check2 c

    join

    (

    SELECT AlertNumber from time_check2 where DATEDIFF(MINUTE,timeLastRun,@myDate) = Schedule_Duration

    )q

    on q.AlertNumber = c.AlertNUmber

    HTH

  • RE: ISQL

    I agree with Allen....if you are looking for a command line solution...create a DTS package and run it using dtsrun.

    HTH

  • RE: Delcaring Variables

    ..or using [Information_Schema] views may be more apt...You'll save yourself a headache in migrating to SQL Server 2005.

  • RE: Distinct and Group by

    I don't believe so.

    Of course I assume you mean..

    SELECT Distinct Person_Name, Count(*) From Person_table

    Group BY Person_Name

  • RE: SQL

    use open row set....

    Here is an example..

    select k.*,x.* FROM

    OPENDATASOURCE

    (

    'MICROSOFT.JET.OLEDB.4.0',

    'DATA SOURCE="x:\LOCATION\X.MDB";

    USER ID=ADMIN;PASSWORD='

    )...TABLE_INACCESS k

    join some_table x

    on x.some_field = k.some_field

    ..or you can make a linked server

  • RE: Help required on sql query(Good and twist question)

    Not exactly what your looking for..but here's something I wrote to address a similar issue..

    --##1 HAS SOME SUBSET OF THE ATTRIBUTES OF ##2

    DECLARE @CHILD_FLAG INT

    DECLARE @QUERY NVARCHAR(100)

    SELECT * INTO ##2...

  • RE: Server Name (local)

    Where are you "registering" the local name ?

  • RE: Even more newbie than the most newbie question...

    Although the Henderson series of Guru vooks are must haves for anyone working with Sql Server, it's a bit intimidating for the beginner. Instead try something like the...

  • RE: Even more newbie than the most newbie question...

    Murarch's book on T-sql and SQL Server is a great Newbie Book.  It assumes you know Nothing at ALL, and has lots of examples.  There's lots of stuff in there...

  • RE: Removing embedded duplicate rows

    Bob..

    Does 'Camel 1' comprise one field or 2 ??

    did you mean

    select description, {id}

    from FEATS_PictureTEST order by newid() ??

  • RE: Removing embedded duplicate rows

    Your DDL would be helpful here....

Viewing 15 posts - 61 through 75 (of 95 total)