Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. carlen

    adding composite unique constraint with no check

    Keep in mind that you can't violate the rules for creating a primary key on a table if it's already got data. If you use a current column as a key, it has to have unique values on it. In the case of the primary key, if you have a repeated value in a column, applying the primary key constraint...
  2. carlen

    Data import question

    Ideally you would want 3 tables a thing table ThingID Descriton 1 thing1 2 thing2 3 thing3 a people table PersonID Descriton 1 Bob 2 Kate 3 Ashley and an ownership table DataID PersonID ThingID 1 3 1 2 3 2 3...
  3. carlen

    Find duplicates

    select count(*) AS CN,Account, Client, DealerNam, MSEG, Tier INTO #T FROM TABLE GROUP BY Account, Client, DealerNam, MSEG, Tier DELETE FROM #T WHERE CN < 2 SELECT * FROM TABLE T LEFT JOIN #T ON T.Account = #T.Account AND T.Client = #T.Client AND T.DealerNam = #T.DealerNam AND T.MSEG = #T.MSEG...
  4. carlen

    using sql to make several calculations

    ignore the double select thats my fat fingers
  5. carlen

    using sql to make several calculations

    select select right(convert(char(11),getdate(),13),8), sum(col1),sum(col2),sum(col3),sum(col4) group by right(convert(char(11),getdate(),13),8) if col 1 is a bit collumn u will get an error as cant perform math on bits so will need to cast or convert to an int
  6. carlen

    How to output properly formated select to an excel file

    alternativley a work around would be selecting the defined columns eg column1 column2 column3 or whatever is in your table and appending a comma to the end of the result then using a csv as your output file which excel will use nicely. nb u may want to use isnull incase there is no output to...
  7. carlen

    How would you save a portion of your database if you had to?

    if you know which Point in time u will want to be looking at an easy way to do it would be to take a full backup everytime you need the information and then simply restore it to a second database whenever required. alternativley create a table called records or something have a recordid and...
  8. carlen

    &quot;Q Mo&quot; intermitently hangs tsm

    The version i am unsure of i know it is 5.6 something in this case though our actlog is empty it shows normal ops right up till the hang and then is empty until the taime the tsm service is killed.
  9. carlen

    &quot;Q Mo&quot; intermitently hangs tsm

    all drivers are uptodate. this is only a very rare instance it is very intermittent about 2wice every 3 weeks. this error has appeared in the last 2-3 months in a couple of environments. no errors on the aix log. all hardwear has been looked at by an ibm engineer and tested okay. it happend...
  10. carlen

    &quot;Q Mo&quot; intermitently hangs tsm

    randomly running a q mo returns no information and appears to hang the system, (this may be that its already hung or the q mount is causing it) there is nothing in the actlog and no errors are thrown up it just hangs, no backups proceed they all stay qued. this requires a reset of the tsm...

Part and Inventory Search

Back
Top