Forum Replies Created

Viewing 15 posts - 121 through 135 (of 248 total)

  • RE: help for data transfer from access db

    You should do it either:

    a) Via a DTS package (it will connect from access to SS2k and port over the data).  This can be scheduled as well is there is...

  • RE: Recommended DTS Books?

    I agree.  That is the best book out there on DTS.  There is a lot of material available at this site as well among other good DTS books:

    http://www.sqldts.com/default.aspx?400

     

  • RE: Update Statistics

    That is true but please be aware that sp_updatestats does not do a fullscan of the rows - it instead does sampling of the records.  For tables and indexes that...

  • RE: list of sql server running in my domain

    You can also do this from the command line:

    osql /L

    From BOL: This option lists the locally configured servers and the names of the servers broadcasting on the network

  • RE: compare two tables

    You can make it even simpler by just using a FULL OUTER JOIN, example:

    CREATE TABLE TEST1 (COL1 VARCHAR(10), COL2 INT)

    CREATE TABLE TEST2 (COL1 VARCHAR(10), COL2 INT)

    INSERT INTO TEST1 VALUES ('A',...

  • RE: Update with table from diff database

    And in addition to what Kenneth said, if the second database "DB2" resides on a separate instance, you would need to use linked servers.  Look up linked servers in BOL...

  • RE: How to list the column name(s) which are Primary key(s) of any table?

    In case your primary key has more than one column, you would be interested in the column order as well..you can use this:

    SELECT

    COLS.CONSTRAINT_NAME,COLS.COLUMN_NAME,COLS.ORDINAL_POSITION

    FROM INFORMATION_SCHEMA.KEY_COLUMN_USAGE AS COLS

     INNER JOIN INFORMATION_SCHEMA.TABLE_CONSTRAINTS...

  • RE: link server is giving error message 7399

    Take a look at this KB article:

    http://support.microsoft.com/kb/306212

    Though the error that you are getting seems to indicate that the ODBC DSN connection itself is not working.  Did you create it...

  • RE: Accessing sql server remotely

    What credentials are you using to connect ?  If you are using SQL Server authentication, then check the permissions assigned to the user (in the user databases) to which that...

  • RE: How to query Active Directory

    Take a look at this KB from Microsoft:

    http://support.microsoft.com/default.aspx?scid=kb;en-us;Q299410

    I had tried this only once before and it worked fine at that time.  Don't have it set up right...

  • RE: Count all Rows in all Tables

    sp_MSforeachtable is un-documented so be aware of that.  The behavior might change in future versions.  And Jennifer, you do not need to put anything for the ?.  That is just...

  • RE: OUTPUT OF A QUERY/STORED PROCEDURE INTO A EXCEL FILE

    Then you have two choices (can't use bcp then):

    1)  Have a stored procedure or a script that runs and populates the tables (could be different tables or the same...

  • RE: Fill View based on null criteria?

    You can also use COALESCE() function.

    CREATE TABLE TESTCASE (ID INT IDENTITY(1,1), NAME_EN VARCHAR(10), NAME_FR VARCHAR(10))

    GO

    INSERT INTO TESTCASE VALUES ('ENG', NULL)

    INSERT INTO TESTCASE VALUES (NULL, 'FRENCH')

    INSERT INTO TESTCASE VALUES ('ENG', 'FRENCH')

    GO

    SELECT...

  • RE: OUTPUT OF A QUERY/STORED PROCEDURE INTO A EXCEL FILE

    Regarding the first question, the column is a variable length column so you will get only what you have in the field - if you want, you can cast that...

  • RE: Limit date to one day

    CREATE TABLE TESTCASE (COL1 DATETIME)

    GO

    INSERT INTO TESTCASE VALUES (GETDATE())

    INSERT INTO TESTCASE VALUES (GETDATE())

    INSERT INTO TESTCASE VALUES (DATEADD(DD, 1, GETDATE()))

    INSERT INTO TESTCASE VALUES (DATEADD(DD, 2, GETDATE()))

    GO

    SELECT * FROM TESTCASE

    --Output

    COL1                                                  

    ------------------------------------------------------

    2005-11-03...

Viewing 15 posts - 121 through 135 (of 248 total)