Forum Replies Created

Viewing 15 posts - 12,166 through 12,180 (of 13,460 total)

  • RE: Compatibility Level 8.0

    we had to maintain level 80 compatibility for a while;

    tracing the application, we found that some sql statements which you could get away with in 80 fail in 90;

    specifically it...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Functions VS Procedures

    a function is a special, more limited type of stored procedure. it is specialized, so it has more limitations.

    here's some high points, but there's a lot of infor to google...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: hypothecated index

    select * from sysindexes where name like '_Wa_Sys%' in sql 2000 or 2005.

    SQL server collects statistics on every query you run....those statistics can be used to determine whether a...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Removing a % character from char data so I can convert it to float

    I'm properly chastized for talking without testing...

    my answer is appropraite for WHERE statements, but not a replace...

    LIKE '%%%%' would be where a percent sign exists in the data, for example.

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Removing a % character from char data so I can convert it to float

    two of the same character in a row is the escape for any special character in sql:brackets, percents, single quotes, etc.

    replace(somecolumn,'%%','') to get rid of a percent sign, if it...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: How to create a table schema using an Excel file with 200 field definitions?

    maybe i read your attachment too quickly, but i didn't see a worksheet with the data, only the sheet with the column definitions.

    if there was a worksheet with just data...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: xp_cmdshell problem

    ok, The command line you pasted does make it a little clearer...and I'm going to guess that the issue is still permissions;

    hrggrouper.exe

    -i D:\PCT_Warehouse\LoadFiles\GrouperFiles\AEGrouperTemp.csv <--input file i...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: How to create a table schema using an Excel file with 200 field definitions?

    you could also do the same thing with a calculated column in Excel:

    =IF(E3="N",B3 & " DECIMAL("&F3&","&G3&"),",B3 & " VARCHAR("&D3&"),")

    that would return this for the fiurst column:

    YPNO DECIMAL(8,0),

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: How to create a table schema using an Excel file with 200 field definitions?

    i just took what i thought were the relevant columns, pasted them in editPlus, and then ran some find and replace macros agaisnt it...I assumed AlphaNumeric columns were varchars,...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: random name generator query

    there's a similar thread where someone needed to generate the same kind of random sample...read matt Millers example here: http://www.sqlservercentral.com/Forums/Topic427826-338-2.aspx you'd change just the portion that did TOP 1000000...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: xp_cmdshell problem

    looks like we'll need more info...can you post the actual contents of the bat file?

    I've used xp_commandshell lots of times, and usually, if it doesn't come back it's due to...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Convert RTF data

    glad you got it working Leonard; this is one of those things that adds to the toolbox, but you don't use too often.

    I made this function to try and...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Convert RTF data

    I tested this just now with the same example I had posted, but with 2005; I had to enable OLE witht he surface area tool first, of course.

    It works on...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Begin,RollBack,Commit

    similarly, there is a SET command which rollsback automatically if an error occurs, so there's no need to explicitly check for @@errors:

    create proc name

    as

    begin

    SET XACT_ABORT ON

    begin tran

    update .....

    update......

    update......

    update......

    commit tran

    end

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • RE: Formatting numeric value of calculated column in View

    if you care to use SQL's built in rounding, you can simply use the convert function:

    select convert(decimal(10,3),108451.4587) results in 108451.459

    so simply format the column in your view as convert(decimal(10,3),columnmname)

    if you...

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

Viewing 15 posts - 12,166 through 12,180 (of 13,460 total)