Forum Replies Created

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

  • RE: Converting an Nested IIf statement to a CASE statement

    So, does it work as expected? 😉

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: Error while importing the data from one server to another

    Are you using a Data Conversion task? It seems as if you're trying to cast character data to a numeric data type, and there illegal values in the source.

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: Converting an Nested IIf statement to a CASE statement

    Did you post the entire expression? The inequality test at the end does not seem to fit.

    Anyway, here's an example you could try:

    case

    when[StudentStatus] <> 'Active'

    then

    case

    when[EnrollmentLDA] Is Null

    then'N'

    else''

    else''

    end

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: openrowset using excel on XP machine with SP2 on SS2K5 errors, works on sample DB but not mine

    What has changed on your machine? What account is the SQL Server service running under?

    I'm not sure what you mean with "adding" a database. Attaching, on the other hand, is...

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: Lancer un package SSIS à partir de vb.net

    I think you'd be much better off asking this question in english. 🙂

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: openrowset using excel on XP machine with SP2 on SS2K5 errors, works on sample DB but not mine

    Is the workbook already open? Also, check Task Manager for excel.exe if you've closed the application but you still get the error.

    Does the SQL Server service account have appropriate permissions...

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: Load Data Directly into a sql server 2005 table using openxml

    Please, explain the mapping between the XML nodes and the destination table columns.

    Also take a look at this simple example:

    declare@xxml

    set@x = N'<persons>

    <person>

    <name>Phil</name>

    <age>45</age>

    </person>

    <person>

    <name>Jim</name>

    <age>47</age>

    </person>

    <person>

    <name>Verne</name>

    <age>34</age>

    </person>

    </persons>'

    selectPersons.Person.query('name').value('.', 'varchar(32)') as PersonName

    ,Persons.Person.query('age').value('.', 'int') as PersonAge

    from@x.nodes

    ('

    /persons/person

    ') Persons (Person)

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: nEED HELP IN DISPLAYING COLUMN VALUES IN TOWS

    Why? Can't you do that in the client application?

    Have you tried googling "cross-tab query"?

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: UPgrade advisor runs only on sql server 2000 or also on 2005?

    So, are remote connections allowed on the instance? You should check that in SQL Server Surface Area Configuration: under Database Engine/Remote Connections. If you're connecting remotely (e.g. through TCP/IP) you...

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: Full text searching

    No, "ARG" does not represent any of those expressions.

    But what are your actual business requirements?

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: Help with Dynameic SQL

    Glen (8/28/2008)


    CurrentLevelXID is of the varchar type. You have to use single quotes in WHERE condition. Otherwise, something like (CurrentLevelXID = 70 AND 1=0) will return TRUE.

    Try to debug the...

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: Row-Column Comparision

    Please, explain your actual business requirements in more detail. At least show us the expected result.

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: Help with Dynameic SQL

    I suggest you read these two articles on dynamic SQL by Erland Sommarskog:

    http://www.sommarskog.se/dynamic_sql.html

    http://www.sommarskog.se/dyn-search.html

    In fact, I think you should read all of Erland's articles, but you should at least start with...

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: SQL XML explicit

    Look up the BCP utility in Books Online.

    However, IMHO a much better option would be to design a client application to save the data to a file. This would give...

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

  • RE: Using Created Fields in Stored Procedures

    Please, post the entire query.

    From what I could understand from your post you could use a subquery or a derived table.

    E.g.:

    selectC = derived_table_B.B + derived_table_B.A

    from(

    selectB = derived_table_A.A + 1

    ,derived_table_A.A as...

    ML

    ---
    Matija Lah, SQL Server MVP
    http://milambda.blogspot.com

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