Forum Replies Created

Viewing 15 posts - 736 through 750 (of 761 total)

  • RE: Need Help with the Error 'Subquery returned more than 1 value'.

    I think your DDL and sample data script is not correct. Its returning errors. I think you should check it.

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: Need Help with the Error 'Subquery returned more than 1 value'.

    Grass (4/12/2012)


    Hi Vinu:

    I checked entity_id,and user_id are retruning multiple records in a table. So, what field do I need in my statement as a distinct.Are these entity_id

    ,user_id ones? or something...

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: how to sum up instances only 3 of the 4 values that can occur in a given column

    capn.hector (4/12/2012)


    vinu512 (4/12/2012)


    dwain.c (4/11/2012)


    Being the contrarion that I am, I'll offer another solution.

    DECLARE @t TABLE (id INT, test VARCHAR(10), status VARCHAR(10))

    INSERT INTO @t (id, test, status)

    SELECT 1, 'test1', 'Passed' UNION...

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: I want to run a batch file from query window or from Trigger.

    Edit: All this has to be done by connecting to the database and not to Integration Services in the connection window.

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: I want to run a batch file from query window or from Trigger.

    Follow the steps to add job:

    1. Right click on jobs in SQL server agent and select "new job".

    2.Fill in a name for the job and click "Steps" at the left...

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: open query in analysis service

    Oops!!! my bad then....Sorry.

    Didn't know much about mining structures.

    It was just a wild guess.

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: I want to run a batch file from query window or from Trigger.

    This is how you call a job inside a trigger:

    CREATE TRIGGER <TriggerName>

    ON <TableName>

    AFTER INSERT, UPDATE, DELETE

    AS

    EXEC msdb..sp_start_job

    @job_name...

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: update problem

    Please post your DDL and sample data.

    Without that, from what I understand, you should create the po no field as an identity. So, every time a new order is placed...

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: Need Help with the Error 'Subquery returned more than 1 value'.

    You should check your table for duplicates because one of your sub queries is returning multiple records from the table based on your parameters. This could happen if you have...

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: ISNULL function

    This might be another way....do correct me if I am wrong.

    Declare @test datetime

    If Not Exists(Select ID From Test Where Id = 219798)

    Begin

    Set @test = getdate()

    End

    Select @test

    Hope this helps.

    Vinu Vijayan

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: rows repeating

    Works Perfectly for me with IS NULL.

    Tried it like this :

    Create Table Ex

    (item1 int,

    item2 varchar(5),

    item3 int)

    Insert Into Ex

    Select 1, 'pen', 34

    Union All

    Select 1, 'pen', null

    Select * From...

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: select rows based on code

    How does the database know that item3 holds the value "pen, pencil"?...Is there a table where you have specified that item3 refers to "pen, pencil"?....

    If there is then you need...

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: how to sum up instances only 3 of the 4 values that can occur in a given column

    dwain.c (4/11/2012)


    Being the contrarion that I am, I'll offer another solution.

    DECLARE @t TABLE (id INT, test VARCHAR(10), status VARCHAR(10))

    INSERT INTO @t (id, test, status)

    SELECT 1, 'test1', 'Passed' UNION ALL

    SELECT 2,...

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: open query in analysis service

    This might sound stupid.

    But why don't you use import data using a package in SSAS if you dont want to use SSMS??....That can be done from BIDS. right??....

    Please do correct...

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

  • RE: PIVOTing multiple columns?

    Please post the DDL of the tables and sample data so thatits easier for us to understand and provide a solution.

    Vinu Vijayan

    Vinu Vijayan

    For better and faster solutions please check..."How to post data/code on a forum to get the best help" - Jeff Moden[/url] 😉

Viewing 15 posts - 736 through 750 (of 761 total)