tablediff.exe  is a Microsoft Internal tool in SQL Server 2008. this is used to check a quick comparison between 2 table in 2 different instanced.tablediff.exe can  do a comparison search on row level ,common level and schema level, this command is located in the C:Program FilesMicrosoft SQL Server100COM path,

syntax of tablediff.exe is as below

tablediff
[ -? ] |
{
        -sourceserver source_server_name[instance_name]
        -sourcedatabase source_database
        -sourcetable source_table_name
    [ -sourceschema source_schema_name ]
    [ -sourcepassword source_password ]
    [ -sourceuser source_login ]
    [ -sourcelocked ]
        -destinationserver destination_server_name[instance_name]
        -destinationdatabase subscription_database
        -destinationtable destination_table
    [ -destinationschema destination_schema_name ]
    [ -destinationpassword destination_password ]
    [ -destinationuser destination_login ]
    [ -destinationlocked ]
    [ -b large_object_bytes ]
    [ -bf number_of_statements ]
    [ -c ]
    [ -dt ]
    [ -et table_name ]
    [ -f [ file_name ] ]
    [ -o output_file_name ]
    [ -q ]
    [ -rc number_of_retries ]
    [ -ri retry_interval ]
    [ -strict ]
    [ -t connection_timeouts ]
}

implementation

“C:Program FilesMicrosoft SQL Server100COMtablediff.exe” -sourceserver RAMESH-LT -sourcedatabase Replication_Test -sourcetable replic -destinationserver RAMESH-LTMSSQL2K8 -destinationdatabase Replication_Test -destinationtable replic -et Difference

output screen

Leave a Reply

Your email address will not be published. Required fields are marked *