Forum Replies Created

Viewing 15 posts - 31 through 45 (of 133 total)

  • RE: making records unique

    Full Text Index is for "Text Fields" rather than "Full Index" -

    you would have to define ALL columns that are in the table as an index key.

  • RE: making records unique

    No problem - glad to help.

  • RE: Log file backup growth (how long's a piece of string...)

    It does depend on the amount of transactions that are happening within the tables / applications.

    I would suggest that the T-LOGs are backed up every hour or even every 2...

  • RE: making records unique

    by doing the SELECT DISTINCT - you will only get the DISTINCT records returned from the SELECT statement.

    Any Index violations would be eliminated by the SELECT.

    Hope this helps ?

  • RE: making records unique

    something like this -

    insert into NEWPostCodesAndAddressesBt

    (

    Postcode varchar(10) ,

    BuildingName varchar(200),

    housenumber varchar(20) ,

    SubBuilding varchar(100) ,

    County varchar(100),

    Town varchar(100) ,

    LocalName varchar(100) ,

    PostOutCode varchar(100),

    PostInCode varchar(100),

    Throughname varchar(100),

    Throughdesc varchar(100),

    poboxno varchar(100),

    BusinessName varchar(200),

    locality varchar(200)

    )

    select

    DISTINCT

    Postcode varchar(10) ,

    BuildingName varchar(200),

    housenumber...

  • RE: making records unique

    Mick,

    sorry - script for above .. ( well start of )

    Update PostCodesAndAddressesBt

    SET Postcode = 'N/A' Where Postcode is NULL

    Update PostCodesAndAddressesBt

    SET BuildingName = 'N/A' Where BuildingName is NULL

    Update PostCodesAndAddressesBt

    SET housenumber =...

  • RE: making records unique

    Right - so we could start by populating the "NULLS" with "Blanks" ?

    This can be easy - just do ;

    Update Table

    set field1 = ' ' where field1 is null

    you could...

  • RE: making records unique

    Hi Mick,

    Sorry - looks like the results show the ID and just a counter - I will have another look at this. Not sure what the scripts were going to...

  • RE: making records unique

    This should give you a result set - that shows where the records are NOT unique - ie. Greater than One

    So these will need to be made unique for your...

  • RE: making records unique

    Hi,

    This one works;

    ;WITH Deleter AS (

    SELECT

    ID,

    rn = ROW_NUMBER() OVER(ORDER BY Postcode,BuildingName,housenumber,SubBuilding,County,Town,

    LocalName,PostOutCode,PostInCode,Throughname,Throughdesc,poboxno,BusinessName,locality)

    FROM PostCodesAndAddressesBt

    )

    SELECT *

    FROM Deleter

    WHERE rn > 1

  • RE: Count all months with "0's" starting today

    Sounds like you need to create a Pivot Table and groupings with a count of number months at zero ....

    I will look into an example as this is something already...

  • RE: Creating a CSV file from a Trigger

    Unfortunately it is a 3rd party warehouse - so therefore a different system and we have to provide a CSV file for them to import.

    I have been toying with the...

  • RE: making records unique

    Yes - you can do a select into, and do a case when login per field - as its a one off pain at first but then its done

  • RE: Add a record to a replicated table.....

    I am assuming that because you think it is a system SP - you have not created any or someone else in your organisation has not created ?

    If you check...

  • RE: restore database bakup

    Are you trying to restore the database over the LIVE or restore to a point in time ( from a backup )to a different database so you can do some...

Viewing 15 posts - 31 through 45 (of 133 total)