Forum Replies Created

Viewing 15 posts - 31 through 45 (of 202 total)

  • RE: recursive cte to count subfolders

    It works ....Thank you so much Sean...I really appreciate your help.

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: recursive cte to count subfolders

    Here is complete code, I hope this will make the query more clear now...

    In words the requirement is to count all the Folders including subfolders in the given root folder,...

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: recursive cte to count subfolders

    Ohh I stepped out...SET based ..I never tried that ..

    What details would you require from me for that....(also do you need a NYQUIL???? :-))

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: recursive cte to count subfolders

    yeah the mainId is actually hard coded by me...

    I think this is what I have to do but instead of @ChildID I will have to use Cursor to fetch the...

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: recursive cte to count subfolders

    Well,There is no MainId column in the SRC table, there is only ChildId and ParentID, I just created that test table as sample data table...

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: recursive cte to count subfolders

    Hmm...This will be runnning for a hardcoded child Id (in this case 87)

    What if I run like this changing the where caluse to IN ----Where childId in...

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: recursive cte to count subfolders

    Thanks but this is not what I am looking for

    once i get this fixed for 87 I will use this function to run for other MAINID's

    So basically I need count...

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: create folders using t-sql

    Thanks Lowell...

    Your answer is perfect but I cannot use xp_cmdshell as No permission

    Msg 15281, Level 16, State 1, Procedure xp_cmdshell, Line 1

    SQL Server blocked access to procedure 'sys.xp_cmdshell' of component...

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: create folders using t-sql

    HI,

    The query is like this:

    Select Name from Mytable

    Returns:

    ACCOUNT

    FINANCE

    PURCHASING

    PERSONAL

    COMPUTER

    Now I will set a path as :

    C:\test

    So All these names folder should be created inside Test.

    If already exists then don't...

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: How to remove CrLf from strings in sql

    Thanks Scott/Jason

    Works fine........

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: Custom data flow component..

    Phil Thanks for your suggestion,I really like it and prefer it too, but still I have to develop a script for this, as this is assigned to me.

    Is it so...

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: query to get all childs and grand children for a prent

    Hi all..

    here is the solution...

    http://stackoverflow.com/questions/1686340/sql-server-how-to-get-all-child-records-given-a-parent-id-in-a-self-referencing

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: query to get all childs and grand children for a prent

    Data looks sommthing like this:

    Parent Id Child_Id

    2 3

    2 4

    2 5

    6 7

    6 8...

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: top without using TOP

    HAHAHA

    very funny

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • RE: top without using TOP

    Here is the complete code with inserts... to find 3rd highest salary

    try it..

    CREATE TABLE [SAL](

    [name] [varchar](12) NULL,

    [salary] [int] NULL

    )

    select * from SAL

    INSERT INTO sal ( name,salary)...

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

Viewing 15 posts - 31 through 45 (of 202 total)