<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:copyright="http://blogs.law.harvard.edu/tech/rss" xmlns:image="http://purl.org/rss/1.0/modules/image/">
    <channel>
        <title>SQL Server Discovery</title>
        <link>http://weblogs.sqlteam.com/phils/Default.aspx</link>
        <description>Better, faster, cheaper ...pick two.</description>
        <language>en-US</language>
        <copyright>Phil Streiff</copyright>
        <generator>Subtext Version 2.5.1.0</generator>
        <image>
            <title>SQL Server Discovery</title>
            <url>http://weblogs.sqlteam.com/images/RSS2Image.gif</url>
            <link>http://weblogs.sqlteam.com/phils/Default.aspx</link>
            <width>77</width>
            <height>60</height>
        </image>
        <item>
            <title>Test database connectivity</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2010/08/31/test-database-connectivity.aspx</link>
            <description>&lt;p&gt;If you need to test connectivity from your workstation to a remote database server, here is a handy trick which will help you accomplish it.&lt;/p&gt;
&lt;p&gt;Right-click on a blank area of your windows desktop and choose create new text file:&lt;font face="" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img border="0" alt="" src="http://a.imageshack.us/img525/1103/1createnew.png" /&gt; &lt;/p&gt;
&lt;p&gt;Create and save the file name with something like TestConn.udl &lt;/p&gt;
&lt;p&gt;Notice the file extension is UDL which stands for Universal Data Link. &lt;/p&gt;
&lt;p&gt; &lt;a title="ImageShack - Image And Video Hosting" target="_blank" href="http://img90.imageshack.us/i/2testconnudl.png/"&gt;&lt;img border="0" alt="" src="http://a.imageshack.us/img90/3204/2testconnudl.png" /&gt; &lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Double-click the file shortcut to launch the UDL applet and choose the data provider connectivity you wish to test: &lt;/p&gt;
&lt;p&gt;&lt;a title="ImageShack - Image And Video Hosting" target="_blank" href="http://img836.imageshack.us/i/4provider.png/"&gt;&lt;img border="0" alt="" src="http://a.imageshack.us/img836/5961/4provider.png" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt; Click Next, then type server name, authentication, database and click Test Connection: &lt;/p&gt;
&lt;p&gt;&lt;a title="ImageShack - Image And Video Hosting" target="_blank" href="http://img714.imageshack.us/i/5serverdbconn.png/"&gt;&lt;img border="0" alt="" src="http://a.imageshack.us/img714/3941/5serverdbconn.png" /&gt; &lt;/a&gt;&lt;/p&gt;
&lt;p&gt;1. If Test Connection succeeds, a confirmation message displays: &lt;/p&gt;
&lt;p&gt;&lt;a title="ImageShack - Image And Video Hosting" target="_blank" href="http://img405.imageshack.us/i/6success.png/"&gt;&lt;img border="0" alt="" src="http://a.imageshack.us/img405/2523/6success.png" /&gt; &lt;/a&gt;&lt;/p&gt;
&lt;p&gt;2. After test connection succeeds, click ok to save the file.&lt;/p&gt;
&lt;p&gt;The valid connection string just created can be viewed by right-clicking the file shortcut and choose 'Open With' &amp;gt; Notepad: &lt;/p&gt;
&lt;p&gt;&lt;a title="ImageShack - Image And Video Hosting" target="_blank" href="http://img33.imageshack.us/i/8openwith.png/"&gt;&lt;img border="0" alt="" src="http://a.imageshack.us/img33/1009/8openwith.png" /&gt; &lt;/a&gt;&lt;/p&gt;
&lt;p&gt;You can now copy-paste the connection string and use it in code, scripts or clients to make a successful database connection: &lt;/p&gt;
&lt;p&gt;&lt;a title="ImageShack - Image And Video Hosting" target="_blank" href="http://img251.imageshack.us/i/9notepad.png/"&gt;&lt;img border="0" alt="" src="http://a.imageshack.us/img251/3134/9notepad.png" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Hope this helps!&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/61193.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil Streiff</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2010/08/31/test-database-connectivity.aspx</guid>
            <pubDate>Tue, 31 Aug 2010 20:33:55 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2010/08/31/test-database-connectivity.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/61193.aspx</wfw:commentRss>
        </item>
        <item>
            <title>SQL Server 2008 - Management Studio issue</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2010/04/19/sql-server-2008-management-studio-issue.aspx</link>
            <description>&lt;p&gt;This is a known issue with SQL Server 2008, that certain DDL operations like ALTERing a column datatype using Management Studio GUI fails.&lt;/p&gt;
&lt;p&gt;For example, in Object Explorer, navigate to a table column &amp;gt; right-click on column &amp;gt; Modify. Change column datatype or length, then save and this error message displays:&lt;/p&gt;
&lt;p&gt;&lt;font face=""&gt;&lt;font face="" /&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;a title="ImageShack - Image And Video Hosting" target="_blank" href="http://imageshack.us/photo/my-images/203/cantsavecolaltererror.png/"&gt;&lt;img border="0" alt="" src="http://img203.imageshack.us/img203/2545/cantsavecolaltererror.png" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt; &lt;br /&gt;
&lt;font face=""&gt;To workaround this problem, go to Query Editor and issue the following DDL statement instead:&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face=""&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;ALTER &lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;TABLE&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; dbo&lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;.&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;FTPFile &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;ALTER&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;COLUMN&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; CmdLine &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2"&gt;VARCHAR &lt;/font&gt;&lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;(&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;100&lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;)&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; &lt;/font&gt;&lt;font color="#808080" size="2"&gt;&lt;font color="#808080" size="2"&gt;;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;&lt;font color="#0000ff" size="2" /&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;GO&lt;br /&gt;
 &lt;/p&gt;
&lt;p&gt;The column change is successfuly applied now.&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/61130.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil Streiff</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2010/04/19/sql-server-2008-management-studio-issue.aspx</guid>
            <pubDate>Mon, 19 Apr 2010 17:51:53 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2010/04/19/sql-server-2008-management-studio-issue.aspx#feedback</comments>
            <slash:comments>6</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/61130.aspx</wfw:commentRss>
        </item>
        <item>
            <title>Find System information using SQL Server</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2009/02/11/60839.aspx</link>
            <description>&lt;p&gt;If you don't have local login rights on a Server and need to find system resources onboard. Here is a little TSQL script that will display useful information like CPU, memory and pagefile size:&lt;/p&gt;
&lt;div style="BORDER-BOTTOM: gray 1px dashed; BORDER-LEFT: gray 1px dashed; BACKGROUND-COLOR: white; PADDING-LEFT: 10px; BORDER-TOP: gray 1px dashed; BORDER-RIGHT: gray 1px dashed"&gt;&lt;br /&gt;
&lt;code style="FONT-SIZE: 12px"&gt;&lt;span style="COLOR: blue"&gt;USE&lt;/span&gt; [master];&lt;br /&gt;
GO&lt;br /&gt;
&lt;span style="COLOR: blue"&gt;select&lt;/span&gt; &lt;br /&gt;
    cpu_count&lt;br /&gt;
,    hyperthread_ratio&lt;br /&gt;
,    physical_memory_in_bytes / 1048576 &lt;span style="COLOR: blue"&gt;as&lt;/span&gt; &lt;span style="COLOR: red"&gt;'mem_MB'&lt;/span&gt;&lt;br /&gt;
,    virtual_memory_in_bytes / 1048576 &lt;span style="COLOR: blue"&gt;as&lt;/span&gt; &lt;span style="COLOR: red"&gt;'virtual_mem_MB'&lt;/span&gt;&lt;br /&gt;
,    max_workers_count&lt;br /&gt;
,    os_error_mode&lt;br /&gt;
,    os_priority_class&lt;br /&gt;
&lt;span style="COLOR: blue"&gt;from&lt;/span&gt; &lt;br /&gt;
    sys.dm_os_sys_info &lt;br /&gt;
&lt;/code&gt;&lt;br /&gt;
&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;
Hope it helps!&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/60839.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil Streiff</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2009/02/11/60839.aspx</guid>
            <pubDate>Thu, 12 Feb 2009 00:31:59 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2009/02/11/60839.aspx#feedback</comments>
            <slash:comments>4</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/60839.aspx</wfw:commentRss>
        </item>
        <item>
            <title>Database Inventory - Part II</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2007/11/27/60414.aspx</link>
            <description>&lt;p&gt;I worked on my Database Inventory script a bit and am releasing an enhanced version of the original. &lt;/p&gt;
&lt;p&gt;When run in the Master database, the script displays a list of all user databases located in the specified sql named instance, along with file name, file type, file path and file size columns.   &lt;/p&gt;
&lt;pre style="BORDER-BOTTOM: gray 1px dashed; BORDER-LEFT: gray 1px dashed; BACKGROUND-COLOR: white; PADDING-LEFT: 10px; BORDER-TOP: gray 1px dashed; BORDER-RIGHT: gray 1px dashed"&gt;&lt;code style="FONT-SIZE: 12px"&gt;&lt;span style="COLOR: blue"&gt;&lt;br /&gt;USE &lt;/span&gt;&lt;span style="COLOR: black"&gt;[Master]&lt;br /&gt;GO&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="COLOR: blue"&gt;SELECT&lt;br /&gt;   &lt;/span&gt;&lt;span style="COLOR: gray"&gt;(&lt;/span&gt;&lt;span style="COLOR: blue"&gt;SELECT &lt;/span&gt;&lt;span style="COLOR: red"&gt;'file_type' &lt;/span&gt;&lt;span style="COLOR: blue"&gt;=  
   &lt;/span&gt;&lt;span style="COLOR: magenta"&gt;CASE  
       &lt;/span&gt;&lt;span style="COLOR: blue"&gt;WHEN &lt;/span&gt;&lt;span style="COLOR: black"&gt;sysaltfiles.groupid &lt;/span&gt;&lt;span style="COLOR: gray"&gt;&amp;lt;&amp;gt; &lt;/span&gt;&lt;span style="COLOR: black"&gt;0 &lt;/span&gt;&lt;span style="COLOR: blue"&gt;THEN &lt;/span&gt;&lt;span style="COLOR: red"&gt;'data'
       &lt;/span&gt;&lt;span style="COLOR: blue"&gt;WHEN &lt;/span&gt;&lt;span style="COLOR: black"&gt;sysaltfiles.groupid &lt;/span&gt;&lt;span style="COLOR: blue"&gt;= &lt;/span&gt;&lt;span style="COLOR: black"&gt;0 &lt;/span&gt;&lt;span style="COLOR: blue"&gt;THEN &lt;/span&gt;&lt;span style="COLOR: red"&gt;'log'
   &lt;/span&gt;&lt;span style="COLOR: blue"&gt;END&lt;/span&gt;&lt;span style="COLOR: gray"&gt;) &lt;/span&gt;&lt;span style="COLOR: blue"&gt;AS &lt;/span&gt;&lt;span style="COLOR: red"&gt;'file_type'
&lt;/span&gt;&lt;span style="COLOR: gray"&gt;,  &lt;/span&gt;&lt;span style="COLOR: black"&gt;sysdatabases.name &lt;/span&gt;&lt;span style="COLOR: blue"&gt;AS &lt;/span&gt;&lt;span style="COLOR: red"&gt;'db_name'
&lt;/span&gt;&lt;span style="COLOR: gray"&gt;,  &lt;/span&gt;&lt;span style="COLOR: black"&gt;sysaltfiles.name &lt;/span&gt;&lt;span style="COLOR: blue"&gt;AS &lt;/span&gt;&lt;span style="COLOR: red"&gt;'logical_file_name'
&lt;/span&gt;&lt;span style="COLOR: gray"&gt;,  &lt;/span&gt;&lt;span style="COLOR: black"&gt;sysaltfiles.filename &lt;/span&gt;&lt;span style="COLOR: blue"&gt;AS &lt;/span&gt;&lt;span style="COLOR: red"&gt;'physical_file_name'
&lt;/span&gt;&lt;span style="COLOR: gray"&gt;,  (&lt;/span&gt;&lt;span style="COLOR: black"&gt;sysaltfiles.size &lt;/span&gt;&lt;span style="COLOR: gray"&gt;* &lt;/span&gt;&lt;span style="COLOR: black"&gt;8 &lt;/span&gt;&lt;span style="COLOR: gray"&gt;/ &lt;/span&gt;&lt;span style="COLOR: black"&gt;1024&lt;/span&gt;&lt;span style="COLOR: gray"&gt;) &lt;/span&gt;&lt;span style="COLOR: blue"&gt;AS &lt;/span&gt;&lt;span style="COLOR: red"&gt;'file_size(MB)' &lt;/span&gt;&lt;span style="COLOR: green"&gt;-- file size in MB
&lt;/span&gt;&lt;span style="COLOR: blue"&gt;FROM 
   &lt;/span&gt;&lt;span style="COLOR: black"&gt;dbo.sysdatabases
&lt;/span&gt;&lt;span style="COLOR: blue"&gt;JOIN
   &lt;/span&gt;&lt;span style="COLOR: black"&gt;dbo.sysaltfiles &lt;/span&gt;&lt;span style="COLOR: blue"&gt;ON
   &lt;/span&gt;&lt;span style="COLOR: gray"&gt;(&lt;/span&gt;&lt;span style="COLOR: black"&gt;dbo.sysdatabases.dbid&lt;/span&gt;&lt;span style="COLOR: blue"&gt;=&lt;/span&gt;&lt;span style="COLOR: black"&gt;dbo.sysaltfiles.dbid&lt;/span&gt;&lt;span style="COLOR: gray"&gt;)
&lt;/span&gt;&lt;span style="COLOR: blue"&gt;WHERE
   &lt;/span&gt;&lt;span style="COLOR: black"&gt;sysdatabases.dbid &lt;/span&gt;&lt;span style="COLOR: gray"&gt;NOT &lt;/span&gt;&lt;span style="COLOR: blue"&gt;IN &lt;/span&gt;&lt;span style="COLOR: gray"&gt;(&lt;/span&gt;&lt;span style="COLOR: red"&gt;'1'&lt;/span&gt;&lt;span style="COLOR: gray"&gt;,&lt;/span&gt;&lt;span style="COLOR: red"&gt;'2'&lt;/span&gt;&lt;span style="COLOR: gray"&gt;,&lt;/span&gt;&lt;span style="COLOR: red"&gt;'3'&lt;/span&gt;&lt;span style="COLOR: gray"&gt;,&lt;/span&gt;&lt;span style="COLOR: red"&gt;'4'&lt;/span&gt;&lt;span style="COLOR: gray"&gt;)
&lt;/span&gt;&lt;span style="COLOR: blue"&gt;ORDER BY
   &lt;/span&gt;&lt;span style="COLOR: black"&gt;dbo.sysdatabases.name&lt;/span&gt;&lt;/code&gt;

&lt;/pre&gt;
&lt;br /&gt;
&lt;p&gt;Hope this helps! &lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/60414.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil Streiff</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2007/11/27/60414.aspx</guid>
            <pubDate>Tue, 27 Nov 2007 20:08:18 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2007/11/27/60414.aspx#feedback</comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/60414.aspx</wfw:commentRss>
        </item>
        <item>
            <title>SQL Server 2005 Best Practice Analyzer</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2007/03/27/60142.aspx</link>
            <description>&lt;p&gt;I've been testing the re-released Best Practice Analyzer called &lt;a href="http://www.microsoft.com/downloads/details.aspx?familyid=da0531e4-e94c-4991-82fa-f0e3fbd05e63&amp;amp;displaylang=en"&gt;SQL Server 2005 Best Practice Analyzer 2.0&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I find this tool to be very handy for identifying database Security &amp;amp; Performance issues and making fix recommendations, even though it is CTP and not final release yet.&lt;/p&gt;
&lt;p&gt;It does NOT have to be installed on a remote server, just on a DBA's Mgmt Studio workstation. It DOES, however, require that you have Admin priviledges on the remote SQL Server in order to access the Windows registry.&lt;/p&gt;
&lt;p&gt;Give it a spin and see what you think.&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/60142.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2007/03/27/60142.aspx</guid>
            <pubDate>Tue, 27 Mar 2007 20:33:20 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2007/03/27/60142.aspx#feedback</comments>
            <slash:comments>6</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/60142.aspx</wfw:commentRss>
        </item>
        <item>
            <title>Gather a Database Inventory</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2007/02/28/gather-a-database-inventory.aspx</link>
            <description>&lt;p&gt;As a DBA for a large corporation, I manage literally hundreds of databases. In order to help keep track of all the databases and log files, I needed a way to quickly gather an inventory of all databases located on each sql named instance, so I came up with this simple little script that also includes a filesize in megabytes column: &lt;br /&gt;
&lt;/p&gt;
&lt;pre style="BORDER-BOTTOM: gray 1px dashed; BORDER-LEFT: gray 1px dashed; BACKGROUND-COLOR: white; PADDING-LEFT: 10px; BORDER-TOP: gray 1px dashed; BORDER-RIGHT: gray 1px dashed"&gt;&lt;code style="FONT-SIZE: 12px"&gt;
&lt;font color="#0000ff"&gt;USE &lt;/font&gt;&lt;font color="#000000"&gt;[Master]&lt;/font&gt;
&lt;font color="#0000ff"&gt;GO &lt;/font&gt;
&lt;font color="#0000ff"&gt;SELECT &lt;/font&gt;
	&lt;font color="#000000"&gt;sysdatabases&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#0000ff"&gt;name AS &lt;/font&gt;&lt;font color="#ff0000"&gt;'db_name'  &lt;/font&gt;
&lt;font color="#000000"&gt;,	&lt;/font&gt;&lt;font color="#ff0000"&gt;(&lt;/font&gt;&lt;font color="#0000ff"&gt;select &lt;/font&gt;&lt;font color="#ff0000"&gt;'file_type' =  &lt;/font&gt;
	&lt;font color="#808000"&gt;CASE  &lt;/font&gt;
		&lt;font color="#0000ff"&gt;WHEN &lt;/font&gt;&lt;font color="#000000"&gt;sysaltfiles&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#000000"&gt;groupid &lt;/font&gt;&lt;font color="#ff0000"&gt;= &lt;/font&gt;&lt;font color="#000000"&gt;1 &lt;/font&gt;&lt;font color="#0000ff"&gt;THEN &lt;/font&gt;&lt;font color="#ff0000"&gt;'data'&lt;/font&gt;
		&lt;font color="#0000ff"&gt;WHEN &lt;/font&gt;&lt;font color="#000000"&gt;sysaltfiles&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#000000"&gt;groupid &lt;/font&gt;&lt;font color="#ff0000"&gt;= &lt;/font&gt;&lt;font color="#000000"&gt;0 &lt;/font&gt;&lt;font color="#0000ff"&gt;THEN &lt;/font&gt;&lt;font color="#ff0000"&gt;'log'&lt;/font&gt;
	&lt;font color="#0000ff"&gt;END&lt;/font&gt;&lt;font color="#ff0000"&gt;) &lt;/font&gt;&lt;font color="#0000ff"&gt;as &lt;/font&gt;&lt;font color="#ff0000"&gt;'file_type'	&lt;/font&gt;
&lt;font color="#000000"&gt;,	sysaltfiles&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#0000ff"&gt;name AS &lt;/font&gt;&lt;font color="#ff0000"&gt;'file_name'&lt;/font&gt;
&lt;font color="#000000"&gt;,	&lt;/font&gt;&lt;font color="#ff0000"&gt;(&lt;/font&gt;&lt;font color="#000000"&gt;sysaltfiles&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#0000ff"&gt;size &lt;/font&gt;&lt;font color="#ff0000"&gt;* &lt;/font&gt;&lt;font color="#000000"&gt;8 &lt;/font&gt;&lt;font color="#ff0000"&gt;/ &lt;/font&gt;&lt;font color="#000000"&gt;1024&lt;/font&gt;&lt;font color="#ff0000"&gt;) &lt;/font&gt;&lt;font color="#0000ff"&gt;AS &lt;/font&gt;&lt;font color="#ff0000"&gt;'file_size(MB)' &lt;/font&gt;&lt;font color="#008000"&gt;-- file size in MB&lt;/font&gt;
&lt;font color="#0000ff"&gt;FROM &lt;/font&gt;
	&lt;font color="#000000"&gt;dbo&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#000000"&gt;sysdatabases&lt;/font&gt;
&lt;font color="#0000ff"&gt;JOIN&lt;/font&gt;
	&lt;font color="#000000"&gt;dbo&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#000000"&gt;sysaltfiles &lt;/font&gt;&lt;font color="#0000ff"&gt;ON&lt;/font&gt;
	&lt;font color="#ff0000"&gt;(&lt;/font&gt;&lt;font color="#000000"&gt;dbo&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#000000"&gt;sysdatabases&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#000000"&gt;dbid&lt;/font&gt;&lt;font color="#ff0000"&gt;=&lt;/font&gt;&lt;font color="#000000"&gt;dbo&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#000000"&gt;sysaltfiles&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#000000"&gt;dbid&lt;/font&gt;&lt;font color="#ff0000"&gt;)&lt;/font&gt;
&lt;font color="#0000ff"&gt;WHERE&lt;/font&gt;
	&lt;font color="#000000"&gt;sysdatabases&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#000000"&gt;dbid &lt;/font&gt;&lt;font color="#ff0000"&gt;NOT IN ('1'&lt;/font&gt;&lt;font color="#000000"&gt;,&lt;/font&gt;&lt;font color="#ff0000"&gt;'2'&lt;/font&gt;&lt;font color="#000000"&gt;,&lt;/font&gt;&lt;font color="#ff0000"&gt;'3'&lt;/font&gt;&lt;font color="#000000"&gt;,&lt;/font&gt;&lt;font color="#ff0000"&gt;'4')&lt;/font&gt;
&lt;font color="#0000ff"&gt;ORDER BY&lt;/font&gt;
	&lt;font color="#000000"&gt;dbo&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#000000"&gt;sysdatabases&lt;/font&gt;&lt;font color="#ff0000"&gt;.&lt;/font&gt;&lt;font color="#0000ff"&gt;name&lt;/font&gt;

&lt;/code&gt;&lt;/pre&gt;
&lt;br /&gt;
&lt;p&gt;Run this script in the Master database and it will output a database list that you can export to a spreadsheet for reporting or futher analysis. If anyone knows a better way to do this or some enhancement suggestions to include additional useful information, let me know.&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/60122.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil Streiff</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2007/02/28/gather-a-database-inventory.aspx</guid>
            <pubDate>Wed, 28 Feb 2007 15:40:55 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2007/02/28/gather-a-database-inventory.aspx#feedback</comments>
            <slash:comments>7</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/60122.aspx</wfw:commentRss>
        </item>
        <item>
            <title>Fast importing of text files with format files and bulk insert</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2006/05/31/10026.aspx</link>
            <description>&lt;p&gt;When creating SQL Server 2000 ETL solutions like importing of text files, it is common for developers to employ DTS packages to accomplish results quickly. The downside of this approach is that DTS packages have certain programmability limitations and don't always offer the best performance.&lt;/p&gt;
&lt;p&gt;If you are importing very large raw text files that don't include formatting like column headers, a high-performance solution is to use BULK INSERT with format files.&lt;/p&gt;
&lt;p&gt;For example, the format file may be named major.fmt (note the file extension .fmt) and would be placed in the same file system directory where the import source text files are located.&lt;/p&gt;
&lt;p&gt;Here is a sample of what a format file looks like: &lt;/p&gt;
&lt;pre&gt;&lt;div style="BORDER-RIGHT: gray 1px dashed; BORDER-TOP: gray 1px dashed; PADDING-LEFT: 10px; BORDER-LEFT: gray 1px dashed; BORDER-BOTTOM: gray 1px dashed; BACKGROUND-COLOR: white"&gt;
8.0
4
1   SQLCHAR   0   0   "\""      0	x	SQL_Latin1_General_CP1_CI_AS
2   SQLCHAR   0   0   "\",\""   1	WTN	SQL_Latin1_General_CP1_CI_AS
3   SQLCHAR   0   0   "\",\""   2	Major	SQL_Latin1_General_CP1_CI_AS
4   SQLCHAR   0   0   "\"\r\n"  3	MktSeg	SQL_Latin1_General_CP1_CI_AS
&lt;br /&gt;
&lt;/div&gt;&lt;/pre&gt;
&lt;p&gt;&lt;br /&gt;
Look in SQL Server Books On Line to find more details about how to use format files.&lt;/p&gt;
&lt;p&gt;Now you can perform BULK INSERTS from the source text file like this:&lt;/p&gt;
&lt;pre style="BORDER-RIGHT: gray 1px dashed; BORDER-TOP: gray 1px dashed; PADDING-LEFT: 10px; BORDER-LEFT: gray 1px dashed; BORDER-BOTTOM: gray 1px dashed; BACKGROUND-COLOR: white"&gt;&lt;br /&gt;&lt;font face="Courier New"&gt;&lt;font color="#000000"&gt;BULK &lt;/font&gt;&lt;font color="#0000ff"&gt;INSERT &lt;/font&gt;&lt;font color="#000000"&gt;Database_name&lt;/font&gt;&lt;font color="#ff0000"&gt;..&lt;/font&gt;&lt;font color="#000000"&gt;MajorAccount &lt;/font&gt;
&lt;font color="#0000ff"&gt;FROM &lt;/font&gt;&lt;font color="#ff0000"&gt;'\\ServerName\Textfiles$\major.txt' &lt;/font&gt;
&lt;font color="#0000ff"&gt;WITH &lt;/font&gt;&lt;font color="#ff0000"&gt;(&lt;/font&gt;&lt;font color="#000000"&gt;FORMATFILE &lt;/font&gt;&lt;font color="#ff0000"&gt;= '\\ServerName\Textfiles$\major.fmt')&lt;/font&gt;&lt;/font&gt;&lt;br /&gt;
&lt;/pre&gt;
&lt;font face="Arial"&gt;
&lt;p align="left"&gt;&lt;br /&gt;
Your data loads will now complete way faster than trying to accomplish the same results with DTS packages in SQL   Server 2000.&lt;br /&gt;
&lt;br /&gt;
Hope this helps!&lt;/p&gt;
&lt;/font&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/10026.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil Streiff</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2006/05/31/10026.aspx</guid>
            <pubDate>Thu, 01 Jun 2006 02:24:00 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2006/05/31/10026.aspx#feedback</comments>
            <slash:comments>4</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/10026.aspx</wfw:commentRss>
        </item>
        <item>
            <title>Linked Server  to Text Files - SQL2000</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2006/04/28/linked-server-to-text-files-sql2000.aspx</link>
            <description>&lt;p&gt;Sometimes it's handy to create a Linked Server to text files in order to perform distributed queries or bulk inserts of flat-file data into SQL Server.&lt;/p&gt;
&lt;p&gt;In order to demonstrate this capability with SQL Server 2000, create a text file copy of the Categories table from Northwind database and place the text file named CATEGORIES.TXT in a subdirectory named TEXTFILES on a hard drive attached to the SQL Server machine.&lt;/p&gt;
&lt;p&gt;Then add a Linked Server to the text file with a script like this:&lt;/p&gt;
&lt;div style="BORDER-BOTTOM: gray 1px dashed; BORDER-LEFT: gray 1px dashed; BACKGROUND-COLOR: white; PADDING-LEFT: 10px; BORDER-TOP: gray 1px dashed; BORDER-RIGHT: gray 1px dashed"&gt;&lt;br /&gt;
&lt;font face="Courier New"&gt;&lt;font color="#0000ff"&gt;exec &lt;/font&gt;&lt;font color="#000000"&gt;sp_addlinkedserver NW_TEXT, &lt;/font&gt;&lt;font color="#ff0000"&gt;'Jet 4.0'&lt;/font&gt;&lt;font color="#000000"&gt;,&lt;/font&gt; &lt;font color="#ff0000"&gt;'Microsoft.Jet.OLEDB.4.0'&lt;/font&gt;&lt;font color="#000000"&gt;, &lt;/font&gt;&lt;font color="#ff0000"&gt;'Z:\TEXTFILES'&lt;/font&gt;&lt;font color="#000000"&gt;, &lt;/font&gt;&lt;font color="#ff0000"&gt;NULL&lt;/font&gt;&lt;font color="#000000"&gt;, &lt;/font&gt;&lt;font color="#ff0000"&gt;'Text'&lt;/font&gt; &lt;/font&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;
Alternatively, you can add a Linked Server in Enterprise Manager:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 1&lt;/strong&gt;&lt;br /&gt;
&lt;a target="_blank" href="http://s45.photobucket.com/albums/f96/pjstreiff/Screen%20shots/?action=view&amp;amp;current=LinkSvrProp_General.png"&gt;&lt;img border="0" alt="Linked Server Properties" src="http://i45.photobucket.com/albums/f96/pjstreiff/Screenshots/NewLinkedServer.png" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;strong&gt;

&lt;p&gt; &lt;strong&gt;Step 2&lt;/strong&gt;&lt;br /&gt;
&lt;a target="_blank" href="http://s45.photobucket.com/albums/f96/pjstreiff/Screen%20shots/?action=view&amp;amp;current=NewLinkedServer.png"&gt;&lt;img border="0" alt="New Linked Server dialog box" src="http://i45.photobucket.com/albums/f96/pjstreiff/Screenshots/LinkSvrProp_General.png" /&gt;&lt;/a&gt; &lt;/p&gt;&lt;/strong&gt;

&lt;p&gt; &lt;strong&gt;Step 3&lt;/strong&gt;&lt;br /&gt;
&lt;a target="_blank" href="http://s45.photobucket.com/albums/f96/pjstreiff/Screen%20shots/?action=view&amp;amp;current=LinkSvrProp_Security.png"&gt;&lt;img border="0" alt="Linked Server Properties - Security" src="http://i45.photobucket.com/albums/f96/pjstreiff/Screenshots/LinkSvrProp_Security.png" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 4 &lt;/strong&gt;&lt;br /&gt;
&lt;a target="_blank" href="http://s45.photobucket.com/albums/f96/pjstreiff/Screen%20shots/?action=view&amp;amp;current=LinkSvrProp_SvrOptions.png"&gt;&lt;img border="0" alt="Linked Server - Server Options tab" src="http://i45.photobucket.com/albums/f96/pjstreiff/Screenshots/LinkSvrProp_SvrOptions.png" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;This now allows you execute queries against the text file like this: &lt;/p&gt;
&lt;div style="BORDER-BOTTOM: gray 1px dashed; BORDER-LEFT: gray 1px dashed; BACKGROUND-COLOR: white; PADDING-LEFT: 10px; BORDER-TOP: gray 1px dashed; BORDER-RIGHT: gray 1px dashed"&gt;&lt;font face="Courier New"&gt;&lt;font color="#0000ff"&gt;&lt;br /&gt;
select &lt;/font&gt;&lt;font color="#ff0000"&gt;* &lt;/font&gt;&lt;font color="#0000ff"&gt;from &lt;/font&gt;&lt;font color="#000000"&gt;NW_TEXT&lt;/font&gt;&lt;font color="#ff0000"&gt;...&lt;/font&gt;&lt;font color="#000000"&gt;categories#txt&lt;/font&gt; &lt;/font&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;
You can use a schema.ini file (Text File Driver) to provide formatting like column headers in a text file and make the file(s) browsable just like tables are when displaying them from the Linked Server node in Enterprise Manger. &lt;/p&gt;
&lt;p&gt;For this example, create a schema.ini file that looks like this:&lt;/p&gt;
&lt;div style="BORDER-BOTTOM: gray 1px dashed; BORDER-LEFT: gray 1px dashed; BACKGROUND-COLOR: white; PADDING-LEFT: 10px; BORDER-TOP: gray 1px dashed; BORDER-RIGHT: gray 1px dashed"&gt;&lt;br /&gt;
&lt;font face="Courier New"&gt;[CATEGORIES.TXT] &lt;br /&gt;
Format=CSVDelimited &lt;br /&gt;
CharacterSet=ANSI &lt;br /&gt;
ColNameHeaders=True &lt;br /&gt;
Col1=CategoryID Short &lt;br /&gt;
Col2=CategoryName Text Width 15 &lt;br /&gt;
Col3=Description Text Width 100 &lt;br /&gt;
&lt;/font&gt;&lt;br /&gt;
&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;
For further information, check &lt;a href="http://msdn.microsoft.com/library/default.asp?url=/library/en-us/odbc/htm/odbcjetschema_ini_file.asp"&gt;Schema.ini (Text File Driver)&lt;/a&gt; on Microsoft MSDN.&lt;br /&gt;
&lt;br /&gt;
One caveate I ran across though, is that the maximum number of columns or fields that you can specify in a schema.ini file is 255. So, if you have a really W-I-D-E data file with lots of columns, and you are considering Linked Server with a schema.ini file, be aware of this limitation.&lt;/p&gt;
&lt;p&gt;Hope this helps.&lt;br /&gt;
-pj&lt;/p&gt;
&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/9726.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil Streiff</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2006/04/28/linked-server-to-text-files-sql2000.aspx</guid>
            <pubDate>Fri, 28 Apr 2006 19:59:00 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2006/04/28/linked-server-to-text-files-sql2000.aspx#feedback</comments>
            <slash:comments>7</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/9726.aspx</wfw:commentRss>
        </item>
        <item>
            <title>Linked Server to Teradata - SQL2000</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2006/02/28/linked-server-to-teradata-sql2000.aspx</link>
            <description>&lt;p&gt;1.) Download and install Teradata OLE DB driver on the target server where SQL Server 2000 is hosted.&lt;/p&gt;
&lt;p&gt;2.) Right-click the Linked Server node under Security node in Enterprise Manager and select “New Linked Server...”&lt;/p&gt;
&lt;p&gt;3.) On the General Tab:&lt;br /&gt;
     -Choose a Linked Server name.&lt;br /&gt;
     -Select “OLE DB Provider for Teradata“ from the “Provider Name“ Dropdown list under “Other data source“.&lt;br /&gt;
     -Choose a name for the Linked Server in the “Product Name“ textbox.&lt;br /&gt;
     -Enter the name of the Teradata database in the Product Name field.&lt;br /&gt;
     -Enter a server domain name or IP address of the server that Teradata database is hosted on.&lt;br /&gt;
     -Leave Provider String field blank.&lt;/p&gt;
&lt;p&gt;&lt;a target="_blank" href="http://s45.photobucket.com/albums/f96/pjstreiff/Screenshots/?action=view&amp;amp;current=ss2k_td_lnksvr1.jpg"&gt;&lt;img border="0" alt="Linked Server Properties - Teradata" src="http://i45.photobucket.com/albums/f96/pjstreiff/Screenshots/ss2k_td_lnksvr1.jpg" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;4.) Click the “Provider Options“ button and&lt;br /&gt;
     -Check the “Allow InProcess“ checkbox&lt;br /&gt;
     -Check the “Index as Access Path“ checkbox&lt;/p&gt;
&lt;p&gt;&lt;a target="_blank" href="http://s45.photobucket.com/albums/f96/pjstreiff/Screenshots/?action=view&amp;amp;current=ss2k_td_lnksvr2.jpg"&gt;&lt;img border="0" alt="Teradata Linked Server - Provider Options" src="http://i45.photobucket.com/albums/f96/pjstreiff/Screenshots/ss2k_td_lnksvr2.jpg" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;5.) On the Security Tab:&lt;br /&gt;
     -Under login section, select “Be made using this security context” Radio Button&lt;br /&gt;
     -Enter your Teradata login name in the “Remote Login” field&lt;br /&gt;
     -Enter your Teradata password in the “With Password” field&lt;/p&gt;
&lt;p&gt;&lt;a target="_blank" href="http://s45.photobucket.com/albums/f96/pjstreiff/Screenshots/?action=view&amp;amp;current=ss2k_td_lnksvr3.jpg"&gt;&lt;img border="0" alt="Teradata Linked Server - Security" src="http://i45.photobucket.com/albums/f96/pjstreiff/Screenshots/ss2k_td_lnksvr3.jpg" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;6.) On the Server Options make sure the following options are checked:&lt;br /&gt;
     - Data Access&lt;br /&gt;
     - Use Remote Collation&lt;/p&gt;
&lt;p&gt;&lt;a target="_blank" href="http://s45.photobucket.com/albums/f96/pjstreiff/Screenshots/?action=view&amp;amp;current=ss2k_td_lnksvr4.jpg"&gt;&lt;img border="0" alt="Teradata Linked Server - Server Options" src="http://i45.photobucket.com/albums/f96/pjstreiff/Screenshots/ss2k_td_lnksvr4.jpg" /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;7.) OK out and you should be able to select the Tables node underneath the Linked Server you just created and the tables will appear as browsable objects.&lt;/p&gt;
&lt;p&gt;For fast and efficient distributed queries use the OPENQUERY method like this:&lt;/p&gt;
&lt;pre style="BORDER-BOTTOM: gray 1px dashed; BORDER-LEFT: gray 1px dashed; BACKGROUND-COLOR: white; PADDING-LEFT: 10px; BORDER-TOP: gray 1px dashed; BORDER-RIGHT: gray 1px dashed"&gt;&lt;font face="Courier New"&gt;
&lt;font color="#0000ff"&gt;SELECT &lt;/font&gt;&lt;font color="#ff0000"&gt;* &lt;/font&gt;
   &lt;font color="#0000ff"&gt;FROM &lt;/font&gt;&lt;font color="#000000"&gt;OPENQUERY&lt;/font&gt;
   &lt;font color="#ff0000"&gt;(&lt;/font&gt;
   &lt;font color="#000000"&gt;TERADATA_DATABASE, &lt;/font&gt;
   &lt;font color="#ff00ff"&gt;'select &lt;/font&gt;
&lt;font color="#ff00ff"&gt;       field1&lt;/font&gt;
&lt;font color="#ff00ff"&gt;   ,   field2&lt;/font&gt;
&lt;font color="#ff00ff"&gt;   from &lt;/font&gt;
&lt;font color="#ff00ff"&gt;      table1'&lt;/font&gt;
   &lt;font color="#ff0000"&gt;)&lt;/font&gt;
&lt;/font&gt;
&lt;/pre&gt;
&lt;br /&gt;
&lt;p&gt;This performs all the query processing on the Teradata source server before pulling it across the wire to your local SQLServer machine making the operation much faster.&lt;/p&gt;
&lt;p&gt;Hope this helps those of you needing to perform Teradata ETL with SQLServer 2000. &lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/9145.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil Streiff</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2006/02/28/linked-server-to-teradata-sql2000.aspx</guid>
            <pubDate>Tue, 28 Feb 2006 22:02:00 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2006/02/28/linked-server-to-teradata-sql2000.aspx#feedback</comments>
            <slash:comments>3</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/9145.aspx</wfw:commentRss>
        </item>
        <item>
            <title>Linked Server to Teradata - SQL2005</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2005/11/30/linked-server-to-teradata-sql2005.aspx</link>
            <description>&lt;p&gt;Maybe this is known among those who have to connect to Teradata stores from SQL Server but I needed to accomplish this from SQL Server 2005 and didn't find any published resources on how to do it. With a little experimentation, this is what I came up with:&lt;/p&gt;
&lt;p&gt;1) Fetch the Teradata OLEDB driver from teradata.com and install it on the SQL Server 2005 system.&lt;/p&gt;
&lt;p&gt;2) In SQL Management Studio (AKA Enterprise Manager) create a new Linked Server with the following configuration:&lt;br /&gt;
-Linked Server:  choose any name (ex: ENCORE)&lt;br /&gt;
-Provider:  OLE DB Provider for Teradata (select from dropdown list)&lt;br /&gt;
-Product Name:  Database name (ex: databasename)&lt;br /&gt;
-Data Source:  Server name (ex: server1.corp.domain.com)&lt;br /&gt;
-Provider String:  (leave blank)&lt;/p&gt;
&lt;p&gt;&lt;a href="http://img820.imageshack.us/i/1linksvrgen2k5.png/" target="_blank"&gt;&lt;img src="http://img820.imageshack.us/img820/3121/1linksvrgen2k5.png" alt="Free Image Hosting at www.ImageShack.us" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;/p&gt;
&lt;p dir="ltr"&gt; 3) Type in your Teradata username &amp;amp; password in the appropriate textboxes on the Security tab: &lt;/p&gt;
&lt;a target="_blank" href="http://img508.imageshack.us/i/2linksvrsec2k5.png/"&gt;&lt;img border="0" alt="Free Image Hosting at www.ImageShack.us" src="http://img508.imageshack.us/img508/7260/2linksvrsec2k5.png" /&gt;&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;p&gt;4) You can build a SQL query like this:&lt;/p&gt;
&lt;div style="BORDER-BOTTOM: gray 1px dashed; BORDER-LEFT: gray 1px dashed; BACKGROUND-COLOR: white; PADDING-LEFT: 10px; BORDER-TOP: gray 1px dashed; BORDER-RIGHT: gray 1px dashed"&gt;&lt;font color="#0000ff" size="2"&gt;&lt;br /&gt;
&lt;p style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none" class="MsoNormal"&gt;&lt;span style="FONT-FAMILY: &amp;quot;Courier New&amp;quot;; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes"&gt;SELECT&lt;/span&gt;&lt;span style="FONT-FAMILY: &amp;quot;Courier New&amp;quot;; FONT-SIZE: 10pt; mso-no-proof: yes"&gt;&lt;font color="#000000"&gt; &lt;br /&gt;
     field1&lt;br /&gt;
,    field2&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none" class="MsoNormal"&gt;&lt;span style="FONT-FAMILY: &amp;quot;Courier New&amp;quot;; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes"&gt;FROM&lt;/span&gt;&lt;span style="FONT-FAMILY: &amp;quot;Courier New&amp;quot;; FONT-SIZE: 10pt; mso-no-proof: yes"&gt;&lt;font color="#000000"&gt; &lt;o:p /&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p style="MARGIN: 0in 0in 0pt" class="MsoNormal"&gt;&lt;span style="FONT-FAMILY: &amp;quot;Courier New&amp;quot;; FONT-SIZE: 10pt; mso-no-proof: yes"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 1"&gt;      &lt;/span&gt;ENCORE&lt;/font&gt;&lt;span style="COLOR: gray"&gt;..&lt;/span&gt;&lt;font color="#000000"&gt;B8_PROD_VIEW&lt;/font&gt;&lt;span style="COLOR: gray"&gt;.&lt;/span&gt;&lt;font color="#000000"&gt;table_name&lt;br /&gt;
&lt;font color="#008000" size="2"&gt;--(notice the 4 part naming string with second element skipped)&lt;/font&gt;&lt;/font&gt;&lt;/span&gt;&lt;font color="#008000"&gt;&lt;span style="FONT-FAMILY: &amp;quot;Courier New&amp;quot;; FONT-SIZE: 10pt; mso-no-proof: yes"&gt;&lt;font color="#008000"&gt;&lt;br /&gt;
&lt;/font&gt;&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;
&lt;/font&gt;&lt;/div&gt;
&lt;p&gt;&lt;br /&gt;
&lt;font color="#333333"&gt;But using the OPENQUERY method will be much faster:&lt;/font&gt;&lt;/p&gt;
&lt;div style="BORDER-BOTTOM: gray 1px dashed; BORDER-LEFT: gray 1px dashed; BACKGROUND-COLOR: white; PADDING-LEFT: 10px; BORDER-TOP: gray 1px dashed; BORDER-RIGHT: gray 1px dashed"&gt;
&lt;p dir="ltr"&gt;&lt;span style="FONT-FAMILY: &amp;quot;Courier New&amp;quot;; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes"&gt;&lt;font color="#0000ff" size="2"&gt;SELECT &lt;/font&gt;&lt;font color="#808080" size="2"&gt;*&lt;br /&gt;
&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;FROM&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;OPENQUERY&lt;/font&gt;&lt;font color="#808080" size="2"&gt;(&lt;/font&gt;&lt;font color="#000000" size="2"&gt;ENCORE&lt;/font&gt;&lt;font color="#808080" size="2"&gt;,&lt;/font&gt;&lt;font color="#000000" size="2"&gt; &lt;/font&gt;&lt;font color="#ff0000" size="2"&gt;'SELECT field1 FROM B8_PROD_VIEW.table_name'&lt;/font&gt;&lt;/span&gt; &lt;/p&gt;
&lt;/div&gt;
&lt;br /&gt;
&lt;font color="#333333"&gt;Viola! you have a dataset from the remote Teradata store returned inside of SQL Server and ready to perform distributed queries like joining to local tables. &lt;/font&gt;
&lt;p style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none" dir="ltr" class="MsoNormal"&gt;&lt;font color="#333333"&gt; &lt;/font&gt;&lt;/p&gt;
&lt;p style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none" dir="ltr" class="MsoNormal"&gt;&lt;font color="#333333"&gt;Hope this helps!&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font color="#333333"&gt;-pj&lt;/font&gt;&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/8466.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil Streiff</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2005/11/30/linked-server-to-teradata-sql2005.aspx</guid>
            <pubDate>Thu, 01 Dec 2005 02:56:00 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2005/11/30/linked-server-to-teradata-sql2005.aspx#feedback</comments>
            <slash:comments>30</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/8466.aspx</wfw:commentRss>
        </item>
        <item>
            <title>SQL Server 2005: Top 10 New Features</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2005/08/17/sql-server-2005-top-10-new-features.aspx</link>
            <description>&lt;p&gt;&lt;font face="Arial"&gt;I ran across a article on Builder AU entitled: &lt;/font&gt;&lt;a target="_blank" href="http://www.builderau.com.au/architect/database/soa/SQL_Server_2005_secrets/0%2C39024547%2C39202720%2C00.htm"&gt;&lt;font face="Arial"&gt;SQL Server 2005 Secrets&lt;/font&gt;&lt;/a&gt;&lt;font face="Arial"&gt;, posted August 10, that should be more aptly titled “SQL Server 2005: Top 10 New Features”. Either way, its a good update on what to expect. &lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Arial"&gt;Here's another article entitled: &lt;/font&gt;&lt;a target="_blank" href="http://www.windowsitpro.com/SQLServer/Article/ArticleID/46463/46463.html"&gt;&lt;font face="Arial"&gt;SQL Server 2005: The BI Release&lt;/font&gt;&lt;/a&gt;&lt;font face="Arial"&gt; from the August issue of SQL Server Magazine.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Arial"&gt;I'm most excited about Integration Services, which is the successor to DTS. It's more of a totally new product than a simple upgrade. My first impression is that it appears to be an industrial strength ETL tool that will squeeze the major players in this market space. Along with Analysis Services and Reporting Services, these products comprise a toolset for developing enterprise BI solutions that will be hard to beat.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Arial"&gt;Anybody have thoughts or experience with the new Integration Services that they would like to share?&lt;/font&gt;&lt;/p&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/7553.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Phil Streiff</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2005/08/17/sql-server-2005-top-10-new-features.aspx</guid>
            <pubDate>Wed, 17 Aug 2005 15:42:00 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2005/08/17/sql-server-2005-top-10-new-features.aspx#feedback</comments>
            <slash:comments>8</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/7553.aspx</wfw:commentRss>
        </item>
        <item>
            <title>Performance Tuning Webcast</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2005/05/02/4847.aspx</link>
            <description>&lt;P&gt;I found a pretty good webcast by Kimberly Tripp on Performance Tuning:&lt;/P&gt;
&lt;P&gt;&lt;A href="http://msevents.microsoft.com/CUI/EventDetail.aspx?EventID=1032254503&amp;amp;Culture=en-US"&gt;MSDN Webcast: SQL Server 2000 Performance Tuning - Finding the Right Balance of Indexes &amp;#8211; Level 200&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;It's probably more detailed than what the average DBA needs but if you're really wanting to squeeze the last bit of performance out of your database, this could be the ticket.&lt;/P&gt;
&lt;P&gt;-pj&lt;/P&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/4847.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>pj</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2005/05/02/4847.aspx</guid>
            <pubDate>Tue, 03 May 2005 00:53:00 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2005/05/02/4847.aspx#feedback</comments>
            <slash:comments>2</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/4847.aspx</wfw:commentRss>
        </item>
        <item>
            <title>MCDBA - Here I come!</title>
            <link>http://weblogs.sqlteam.com/phils/archive/2005/04/30/4837.aspx</link>
            <description>&lt;P&gt;Well, I took the SQL Server Administration Exam (70-228) and passed with a score of 757 yesterday. It was&amp;nbsp;my first MS Exam so I was a little nervous. &lt;/P&gt;
&lt;P&gt;Next up: SQL Server Development (70-229), then&amp;nbsp;C# Web Applications (70-315) and&amp;nbsp;finally Windows 2000 Server Administration (70-215).&amp;nbsp;If all goes as planned, I'll get these completed within a couple of months.&lt;/P&gt;
&lt;P&gt;I'm more of a developer than administrator so I found the exam to be fairly difficult. I figured if I could survive my weakest subject on the first outing then it should be downhill after that. We'll see!&lt;/P&gt;
&lt;P&gt;It's been a long time since college,&amp;nbsp;but I&amp;nbsp;actually kind of enjoyed the studying and have learned a lot I hope to apply in my job. &lt;/P&gt;
&lt;P&gt;If&amp;nbsp;anybody has any words of wisdom for studying&amp;nbsp;or have&amp;nbsp;opinions about whether&amp;nbsp;I'm wasting my time, feel free to reply.&lt;/P&gt;
&lt;P&gt;-pj&lt;/P&gt;&lt;img src="http://weblogs.sqlteam.com/phils/aggbug/4837.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>pj</dc:creator>
            <guid>http://weblogs.sqlteam.com/phils/archive/2005/04/30/4837.aspx</guid>
            <pubDate>Sat, 30 Apr 2005 21:28:00 GMT</pubDate>
            <comments>http://weblogs.sqlteam.com/phils/archive/2005/04/30/4837.aspx#feedback</comments>
            <slash:comments>3</slash:comments>
            <wfw:commentRss>http://weblogs.sqlteam.com/phils/comments/commentRss/4837.aspx</wfw:commentRss>
        </item>
    </channel>
</rss>