Forum Replies Created

Viewing 15 posts - 1 through 15 (of 65 total)

  • RE: Add new 'line number' counters to existing data.

    You can use NTILE() for the same. Below is the query that you can use on the line table after adding the Actual_Line_Number field:

    UPDATE X SET X.Actual_Line_Number = Y.Rank

    FROM LINE...

  • RE: Confusing inner/outer join issue...

    Hey Nolan,

    It was being very difficult for me to guide you toward the lane however, below is the solution for your situation.

    create table book(id int identity(1,1), name varchar(20))

    create table employee(id...

  • RE: IF EXISTS High Duration

    also provide the amount of data in both the tables along with the available indexes.

  • RE: query of information

    icampbell (5/19/2009)


    If you have two tables A & B

    A.ref_no= b.ref_no

    how do i retrieve the detail of table A which do not appear in table B. The rows which only...

  • RE: tracking\logging database access

    try sp_who2. it will give you the detailed information about who all are logged into the server and the tasks being performed by them.

  • RE: Validation for password field

    Chandru (10/23/2008)


    create table login(name varchar(20),pwd varchar(20));

    insert into login values('Martin','Test123');

    insert into login values('Ricky','test123');

    insert into login values('Watson','tesT123');

    If such situation is very common, I would suggest you to look in the...

  • RE: Dynamic query error

    dva2007 (10/23/2008)


    Dynamic query error

    hi,

    my query is below:

    declare @myfield varchar(20)

    declare @mysql nvarchar(100)

    declare @myresult varchar(100)

    set @myfield='CategoryName'

    set @mysql='select ' + @myfield + ' from Categories...

  • RE: ERROR WITH TRANSCATIONS

    I just got the error myself. There was a call made to an external procedure with in the proc. This call was also wrapped in the transaction and was covered...

  • RE: Rebuilding indexes

    SQL Server takes as much RAM as it needs and never let go of it, even though that doesn't seem right to me :ermm: but it seems like sql server...

  • RE: ORDER BY CLAUSE

    I am afraid that there is no way out then dynamic SQL. Its not that bad why dont you want to use it?

  • RE: Guideline.....

    b_boy (9/19/2008)


    Hello

    Does anyone know how I can script in T-SQL a result similar to the attached excel template?

    I just need a sample, not an actual script to put me in...

  • RE: Need Help Fixing Stored Proceedure that selects random row, updates it, and then returns the whole row...

    me (9/15/2008)


    Working on a stored proceedure that will select a random row in the table, update it as "won" and add winner info and then return

    select * from table...

  • RE: SQL Q

    for the last time entering somenum 1

    Please clarify

  • RE: ISNULL and Count using SQL SERVER 2005

    please provide the table schema

  • RE: Changing to other Database by command

    anilyadav83 (9/15/2008)


    How can i change to other database using command.

    In stored procedure I am unable to write "USE DataBaseName"

    Is there any other command?

    declare @TargetDB as varchar(100)

    declare @DBQry as varchar(100)

    select @TargetDB...

Viewing 15 posts - 1 through 15 (of 65 total)