Forum Replies Created

Viewing 15 posts - 12,616 through 12,630 (of 13,460 total)

  • RE: Distinct question, waiting on line, thanks

    here's an example to show all records based on the criteria you described

    SELECT SOMETABLE.* FROM SOMETABLE

    INNER JOIN

    (

    SELECT F1,F2,F3,F4,F5,F6,F7 FROM SOMETABLE

    GROUP BY F1,F2,F3,F4,F5,F6,F7

    HAVING COUNT(F1) > 1 --FINDS ALL RECORDS WITH...

    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: Alert for New Database

    same here...in my case, developers were dropping and recreating databases all the time, just needed to be aware of it really; so i had to save the previous data 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: sudden slow down

    spot on analysis of some of the detriments of Oracle vs SQL Server...my shop has to support both as well.

    we often copy the same identical database to SQL and Oracle...

    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: DATABASE DESIGN

    creepy...looked in BOL for the CREATE database example, and their database is named Sales, just like you are asking:

    CREATE DATABASE Sales

    ON

    ( NAME = Sales_dat,

       FILENAME = 'c:\program files\microsoft sql...

    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: Alert for New Database

    you can also save a copy of sysdatabases to a table, and schedule a job to compare that table to the current sysdatabases to compare changes....same thing at the 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: Which One Do You Want?

    I've always been interested in getting and programming a robot arm, but anything in the sub $500 price range are cheap, rinky dinky, have a lift limit of like 6...

    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: sql query efficient or NOT?

    wouldn't this query return all duplicates:

    SELECT Acct_Num_CH  from TrxDetailCard

    WHERE (Date_DT >= cast( convert( char(10), getdate(), 121 ) as datetime )) 

    group by Acct_Num_CH

    having count(Acct_Num_CH) >1

    with that, i think...

    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: Select nthrow to mth row

    in my case, I have a search function that does the top 50 similar to what you were asking for///however when i need the next 50, i make sure 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: Help - How to build this query

    most likely true now that i re-read the question; like almost of your posts, I try to give a solid working answer on a question, when it is worthy...but 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: FTP file to a server

    i have this procedure which is designed to handle FTP to a site, with some minimal validation as to whether it sent or not...hope this helps: you'd want to expand...

    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: Help - How to build this query

    Assuming Resum is the same as BookNum that appears in most of the tables:

    SELECT BookNum,X.PRICE + Y.PRICE + Z.PRICE AS PRICE

    FROM HotelSegment

    LEFT OUTER JOIN (SELECT BookNum ,SUM(Price) AS PRICE...

    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: can anyone help in rebuildin this query..??

    if the contactEnquiries table is small, the optimizer will always do a table scan regardless, and ignore the index;That means if the table is less than 8MB in size, it will always...

    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: Adding description into the modify tables.

    here is an example:

    results:

    TableNameColumnNameDataTypeprecISNULLABLEcolidVALUE
    T1idINT10NOT

    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: Adding description into the modify tables.

    the sp_addextendedproperty  Mohammed mentioned is the Description field you are talking about.

    From enterprise manager, no you cannot add columns tot eh design view of the tables....but you can select 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: Wrong index chosen when variable in WHERE clause

    could this be realted to the parameter sniffing issue that sometimes occurs...that is exactly the symptom...works fine with static value, very slow with variable... search for parameter sniffing  and see...

    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,616 through 12,630 (of 13,460 total)