Forum Replies Created

Viewing 15 posts - 11,866 through 11,880 (of 13,460 total)

  • RE: Incorrect syntax

    awe comeon, you didn't need to post a question for this:

    your error says line 24;

    if you go to your query, you'll see this, starting (guess where? line 24!):

    ','+ @Col1 ...

    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: Row_number() not recognized

    if the database you are connecting to is set at compatibility level 80, the newer syntaxes will be rejected; you just need to change the compatibility level:

    right click

    properties

    options

    third drop down...

    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: Simple Insert problem, I think

    sure;

    declare @FLD4 int

    SET @FLD4=42

    INSERT INTO Table_B(Fld_1, Fld_2, Fld_3, FLD_4)

    SELECT Fld_1, Fld_2, Fld_3,@FLD4

    FROM Table_A

    homebrew01 (11/19/2008)


    I want to insert into a table from another table, and from a variable

    So Table_A has 3...

    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: Cursor Issues

    googled sql error 913 and the first hit came up with this:

    http://www.lcard.ru/~nail/sybase/error/8662.htm

    Possible causes of Error 913 are:

    Accessing a stored procedure or view that refers to a table in a database...

    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 analyze query like that

    yeah queries from profiler can be hell to get your arms around;

    I've formatted your query in the attachment you see; it's just a bunch of find and replaces to get...

    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: Too Many Indexes, Deleting those not needed

    I'm not sure how you'd identify unused indexes; hopefully someone has an idea on how to do that.

    if you use the search function and poke around the Scripts section for...

    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: What is the best way to import a image to sql server

    ouch...that is a hard one.

    I think you are saying you have an excel spreadsheet that contains embedded images. say someone pasted half a dozen images into an excel worksheet, 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: SP for row count of tables

    yeah it depends on how accurate your data needs to be; a developer might just need to know whether some table has a lot of rows or not, but other...

    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: Alter Schema

    2000 doesn't have a Schema, just object owners...for each test.object, you want to use sp_changeObjectOwner instead.

    sp_changeObjectOwner 'test.table','dbo'

    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: page loadingin SQL Server

    2005 makes it REALLY easy by using a Common Table Expression(CTE) and the Row_number () function

    here's a simple example:

    with MyQuery As (

    select row_number() over (order by name) as RowNumber,*...

    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: SP for row count of tables

    thre's two ways to do this;

    the sysindexes table has a rowcount column in it, but it is possible that it is not quite accurate; it's a good approximation of the...

    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 trigger a auto update

    i would think you'd need to add a linked server on washington to point to The california server, and repeat the process on the Cali server to point to washington.

    once...

    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: INSERT INTO table with an NOT NULL column ?

    your psuedocode is pretty much the SQL;

    update table2.maj_grp_seq with the table3.maj_grp_seq where table1.mgrp = table3.name.

    only thing you are missing is how the data is related to table2; since they...

    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: Selecting from combined fields across tables

    you'll be best served if you do this with a full text search.

    Believe it or not, it's not that difficult, and there was a recent article here on SSC 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: triggers in multi client update

    if the table1.Key field should not repeat, why not put a unique constraint on it? why are you trying to do a constraint in a trigger, when there's a built...

    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 - 11,866 through 11,880 (of 13,460 total)