|
|||||
|
Index Topics:
“Super SQL Server Systems” Errata List (Last Updated 18 November 2006) Table of Contents: • Visual C++ - WIN32 DLL” • “Microsoft Visual C++ - WIN32 MFC DLL xp_hellomfc” should read“Microsoft Visual C++ - WIN32 MFC DLL” • “CodeWarrior xp_hellocw” should read “CodeWarrior”• “Borland C++ xp_hellobcc” should read “Borland C++”• “Dev-C++ xp_hellodevc” should read “Dev-C++”• “MINGW xp_hellomw” should read “MINGW”• “Switches” should not appear in the TOC• “Testing the XP” should not appear in the TOC• “Support for __GetXpVersion....105” should not be indented and should read“Support for __GetXpVersion....105” • “Applications of xp_netsend” should not be indented and should read “Applicationsof xp_netsend” • “Applications of xp_smtpsendmail” should not be indented and should read“Applications of xp_smtpsendmail” • “Applications of xp_ntlog” should read “Applications of xp_ntlog”• “Applications of xp_notify” should read “Applications of xp_notify”• “Choice of Cryptography Library” to CRC32 Checksum Algorithm” should beindented by one level. • “RC2 Block Cipher” to “TEA Block Cipher” should be indented by one level• “MS CryptoAPI-based HMAC implementations” should be indented by onelevel • “RSA” to “MS CryptoAPI-based Public Key Implementations” should indentedby one level • “RSA Signing/Verification” to “MS CryptoAPI-based Signing/VerificationImplementations” should be indented by one level • “Applications of xp_rand” should read “Applications of xp_rand”• “E-commerce search based on xp_regexp” should read “E-commerce search onxp_regexp” • “The xpserver Object” should read “The XPServer Object”• “Extending to Support Visual Basic etc” should read “Extending to supportVisual Basic etc” • “TEA Encryption with xp_cryptoapi” should read “TEA Encryption withxp_cryptoapi” • “binary” to “variant Data Type” should be indented by one level• “Decimal and numeric” should read “decimal and numeric”• “variant Data Type” should read “variant Data Type”• “Entity Integrity” to “Business Rules” should be indented by one level• “Primary Key” and Foreign Key” topics should appear after “ReferentialIntegrity” • “CHECK constraints” to “Table-level” Constraint” should be indented by onelevel. • “NOT NULL” to UNIQUE” should be indented by one level• “With Check Option” should be indented by one level• “Aggregate Functions” should appear after “User Defined Data Types”• “Additional Information” should be indented by one level• “Inner Join” to “ Self Join” should be indented by one level• “Correlated Subqueries” and “Non-correlated Subqueries” should be indented byone level • “Clustered Indexes” and “Non-Clustered” Indexes” should be indented by onelevel • “AFTER Triggers” to “Using Views for Input and Output” should be indentedby one level • “SP’S Returning Rows from an XP” and “SP’s Returning Rows from a CraftedSELECT Statement” should not be implemented by one level • “Documented System XP’s” should not be indented by one levelNeed More Horsepower? • “This is a popular SQL Server 10g migration service …” should read “This is apopular SQL Server migration service …” • "These one-time SQL Server consulting services commonly include:" sentenceshould not be present. Acknowledgements • Page 5: “to the final produce you now have in your hands” should read “to thefinal product you now have in your hands”. Chapter 1: Introduction to Extended Stored Procedures • Page 8: “In this way, the application using the existing DLL to handle runtimeerrors...” should read “In this way, the application using the existing DLL can handle runtime errors...” • Page 9: “extern “C” SRVRETCODE NameOFXP(SRV_PROC* srvproc) shouldread “extern “C” SRVRETCODE NameOfXP(SRV_PROV* srvproc) • Page 9: “A C #define preprocessor directive allows to define...” should read “AC #define preprocessor directive allows you to define...” • Page 12: “On The Master database, SQL Server must be informed about theextended stored procedure using query analyzer or other tool:” should read “On The Master database, SQL Server must be informed about the extended stored procedure using query analyzer:” • Page 13: “where production quality ready to run XP’s is developed” should read“where production quality ready to run XP’s are developed” • Page 15: “http://msdn.microsoft.com/” should appear without underlines• Page 16: “Normally, when the XP has only a few parameters, they would then bepassed by and there...” should read “Normally, when the XP has only a few parameters, they would be passed by position and there...” • Page 16: “... and whether it is a NULL flag.” should read “... and whether it is adatabase NULL value.” • Page 18: “One can think of this as using the following analogy:” should read“One can think of this using the following analogy:” • Page 32 “11. Click on Build -> Set Active Configuration” has an unnecessaryspace after 11. • Page 33: “Obviously, NOT NULL returns FALSE if a variable or expression areNULL” should read “Obviously, NOT NULL returns FALSE if a variable or expression is NULL” • Page 54: “The following table shows the equivalent data types for ODS, ADO,C++, SQLDMO, ODBC and XP++:” should read “The following table shows the equivalent data types for ODS, ADO, C++, SQLDMO, ODBC and XP++ (which is discussed in Chapter 3):” • Page 55: The entry for datetime should read “datetime 8-byte datetime datatypeSRVDATETIME DBDATETIME DBDATETIME struct” in Table 1.2. • Page 55: The entry for smalldatetime should read “smalldatetime 4-byte datetimedatatype SRVDATETIM4 DBDATETIM4 DBDATETIM4 struct” in Table 1.2. • Page 56: There are duplicate entries for XP_PT_BIT, XP_PT_DECIMAL andXP_PT_NUMERIC in Table 1.2 • Page 63: “The Extended ASCII Character Set use the bit seven;” should read“The Extended ASCII Character Set uses bit seven;” • Page 64: “The rendered version of the character is called glyph and one glyph ormore glyphs” should read “The rendered version of the character is called a glyph and one or more glyphs” Chapter 2: Misc Compilers and Languages • Page 69: “; followed by Win43 Dynamic Link Library” should read “; followed byWin32 Dynamic Link Library” • Page 72: “… Include Also, Library Files should have...” should read “Include, AlsoLibrary Files should have...” • Page 72: “Select Project -> Settings under the tab link check Project Options.Make sure that opends60.lib is present” should read “Select Project -> Settings andunder the link tab, select the input category and make sure that opends60.lib is present in the Object/library modules edit box.” • Page 73: “3. Define the extended stored procedure name as xp_hellomfc as aRegular DLL using shared MRC DLL.” should read “3. Define the extended stored procedure name as xp_hellomfc as a Regular DLL using shared MFC DLL.” • Page 74: “9. Select Project -> Settings under the tab link check Project Options.Make sure that opends60.lib is present” should read “Select Project -> Settings andunder the link tab, select the input category and make sure that opends60.lib is present in the Object/library modules edit box.” • Page 82: “Also turn off the Output setting...” should read “Turn off the outputsetting...” • Page 83: “Attempting the DLL from the code...” should read “Attempting to runthe DLL from the code...” • Page 89: “The first step is to install the binaries to folder such as ...” should read“The first step is to install the binaries to a folder such as ...” • Page 99: “An XP is basically a regular DLL, but it is not called directly.” Shouldread “An XP is basically a regular DLL meaning it cannot run by itself.” • Page 100: “Selecting YES should cause a message appear in the console...”should read “Selecting YES should cause a message to appear in the console...” • Page 101: “The following errors occur when trying to use the XP.” should read“The following errors can occur when trying to use an XP.” Chapter 3: A C++ Class Framework for XP’s (XP++) • Page 106: “RUN is the method...” should read “Run is the method...”• Page 108: “xp_input_or_output_parameter_precision_scale: ... variables set to userdefinedvalues..” should read “ xp_input_or_output_parameter_precision_scale: ...variables set to user-defined values.” • Page 109: “As an example, following would be ...” should read “As an examplethe following would be ...” • Page 111: “The CExtendedStoredProcedure also...” should read “TheCExtendedStoredProcedure class also...”• Page 112: “...which is the file name to be in a format is needed so that the user...”should read “...which is the file name has to be in a format so that the user...” • Page 115: “In the Run method, the xp_ttext macro to get...” should read “In theRun method, the xp_ttext macro is used to get...”• Page 117: “... also known as a return, parameter.” should read “... also known as areturn parameter.” • Page 121: “should override the DisplayUsage and RUN methods...” should read“should override the DisplayUsage and Run methods...”Chapter 4: Network Messaging (xp_netsend) • Page 124: “…to achieving this functionality is to use xp_cmdshell XP,” should read“…to achieving this functionality is to use the xp_cmdshell XP,”• Page 126: “…as a UNICODE string prior to using it in the call toNetMessageNameDel :” should read “…as a UNICODE string prior to using it inthe call to NetMessageNameAdd:”• Page 126: “The underlying SDK function used in this XP is NetMessageNameAdd”should read “The underlying SDK function used in this XP is NetMessageNameDel ”Chapter 5: SMTP Mailing (xp_smtpsendmail) • Page 130: “… through the following SQL Mail stored procedures: xp_startmail,sp_stopmail, xp_findnextmsg, xp_readmail, xp_delete-mail, xp_sendmail ands p_processmail” should read “… through the following SQL Mail storedprocedures: xp_startmail, sp_stopmail, xp_findnextmsg, xp_readmail, xp_deletemail,xp_sendmail and xp_processmail”• Page 131: “It only compatible with MS Exchange Server; …” should read “It isonly compatible with MS Exchange Server; …” • Page 136: “To specify multiple files, individual files cane be separated…” shouldread “To specify multiple files, individual files can be separated…” • Page 139: “They could be taken from the table itself or from other source.”should read “They could be taken from the table itself or from some other source.” Chapter 6: NT Event Log (xp_ntlog) • Page 140: “In this chapter, a DLL called xp_ntlog will be used.” should read “Inthis chapter, a DLL called xp_ntlog will be created.”• Page 142: “IMPLEMENT_XP(xp_ntlog_ERROR,CNTLogErrorExtendedStoredProcedure) IMPLEMENT_XP(xp_ntlog_WARNING, CNTLogWarningExtendedStoredProcedure) IMPLEMENT_XP(xp_ntlog_INFORMATIONAL, CNTLogInformationalExtendedStoredProcedure) IMPLEMENT_XP(xp_ntlog_INSTALL, CNTLogInstallExtendedStoredProcedure) IMPLEMENT_XP(xp_ntlog_uninstall, CNTLogUninstallExtendedStoredProcedure)” should read “IMPLEMENT_XP(XP_NTLOG_ERROR, CNTLogErrorExtendedStoredProcedure) IMPLEMENT_XP(XP_NTLOG _WARNING, CNTLogWarningExtendedStoredProcedure) IMPLEMENT_XP(XP_NTLOG _INFORMATIONAL, CNTLogInformationalExtendedStoredProcedure) IMPLEMENT_XP(XP_NTLOG_INSTALL, CNTLogInstallExtendedStoredProcedure) IMPLEMENT_XP(XP_NTLOG_uninstall, CNTLogUninstallExtendedStoredProcedure)” • Page 145: “EXEC sp_addextendedproc 'xp_ntlog_install', 'xp_ntlog.dll'EXEC sp_addextendedproc 'xp_ntlog_uninstall', 'xp_ntlog.dll' EXEC sp_addextendedproc 'xp_ntlog_error', 'xp_ntlog.dll' EXEC sp_addextendedproc 'xp_ntlog_warning', 'xp_ntlog.dll' EXEC sp_addextendedproc 'xp_ntlog_informational', 'xp_ntlog.dll'” should read “EXEC sp_addextendedproc 'XP_NTLOG_INSTALL', 'xp_ntlog.dll' EXEC sp_addextendedproc 'XP_NTLOG_UNINSTALL', 'xp_ntlog.dll' EXEC sp_addextendedproc 'XP_NTLOG_ERROR', 'xp_ntlog.dll' EXEC sp_addextendedproc 'XP_NTLOG_WARNING', 'xp_ntlog.dll' EXEC sp_addextendedproc 'XP_NTLOG_INFORMATIONAL', 'xp_ntlog.dll'” • Page 146: “EXEC master..xp_ntlog_INSTALL ‘xp_ntlog Example’” should read“EXEC master..XP_NTLOG_INSTALL ‘XP_NTLOG Example’” • Page 146: “EXEC master..xp_ntlog_INFORMATIONAL ‘xp_ntlog Example’‘Hello World'” should read “EXEC master..XP_NTLOG_INFORMATIONAL ‘XP_NTLOG Example’ ‘Hello World'” • Page 147: “EXEC master..xp_ntlog_WARNING 'Server TKF3-Backup','Successful backup warning:tape not removed yet' EXEC master..xp_ntlog_INFORMATIONAL 'Server TKF3-Backup', 'Successful backup date:5/7/2004'” should read “EXEC master..XP_NTLOG_WARNING 'Server TKF3-Backup', 'Successful backup warning:tape not removed yet' EXEC master..XP_NTLOG_INFORMATIONAL 'Server TKF3-Backup', 'Successful backup date:5/7/2004'” Chapter 7: Disk Logging (xp_disklog) • Page 151: “…from the SDK function GetDateFormat using the flag date_shortdate”should read “…from the SDK function GetDateFormat using the flagDATE_SHORTDATE ”• Page 152: “…from the SDK function GetDateFormat using the flag date_longdate”should read “…from the SDK function GetDateFormat using the flagDATE_LONGDATE ”• Page 156: “EXEC sp_addextendedproc 'xp_disklog', 'xp_disklog.dll'” shouldread “EXEC sp_addextendedproc 'XP_DISKLOG', 'xp_disklog.dll'” • Page 156: “EXEC master..xp_disklog ‘c:\XP_LOG.log’, ‘Hello World’” shouldread “EXEC master..XP_DISKLOG ‘c:\XP_LOG.log’, ‘Hello World’ • Page 157: “EXEC master..xp_disklog ‘c:\XPLOG_%Y_%m_%d.log’,‘%h:%i:%s Hello World’” should read “EXEC master..XP_DISKLOG ‘c:\XPLOG_%Y_%m_%d.log’, ‘%h:%i:%s Hello World’” Chapter 8: Audio Notification (xp_notify) • Page 164: “… where displaying a popup on the<EOL><INDENT>server ...”should read “… where displaying a popup on the<EOL>server ...” • Page 168: “In JScript, a message box is created with the ALERT command.”should read “In JScript, a message box is created with the Alert command.” Chapter 10: Cryptography (xp_cryptoapi) • Page 176: “… for use with the Digital Signal Standard (DSS)… ” should read“… for use with the Digital Signature Standard (DSS) …” • Page 176: “To initialize MS Crypto API, a Cryptography Service Provider(CSP)must …” should read “To initialize the MS Crypto API, a Cryptography Service Provider (CSP) must… ” • Page 178: “…, and the data_to_hash_index is a simple define to make…” shouldread “…, and the DATA_TO_HASH_INDEX is a simple define to make…”• Page 184: “The case may be that it is only available on Windows CE …” shouldread “It may be the case that it is only available on Windows CE …” • Page 186: “www.spyrus.com” should appear without underlines• Page 187: “www.naughter.com” should appear without underlines• Page 188: “If the MS CryptoAPI were in use, these steps would not be done bythe sample code, …” should read “If the MS CryptoAPI were in use, these steps would not need be done by the sample code, …” • Page 189: “The HMACimplementation is quite similar to the ...” should read“The HMAC implementation is quite similar to the …” Chapter 11: Random Data (xp_rand) • Page 204: “It uses the trick of getting a value from a view with rand() in acalculated column” should read “It uses the trick of getting a value from a view with RAND() in a calculated column”• Page 205: “rand() is a wrapper for the C runtime function …” should read“ RAND() is a wrapper for the C runtime function …”• Page 205: “rand() will return a float, which is 8 bytes, …” should read “RAND()will return a float, which is 8 bytes …” • Page 205: “For example, casting rand() to a bigint …” should read “For example,casting RAND() to a bigint …”• Page 205: “… will require many calls to the function rand() while xp_rand wouldneed only one.” should read ”… will require many calls to the function RAND()while xp_rand would need only one.” • Page 205: “… does the same as UDFRandom but using xp_rand instead of rand():”should read “… does the same as UDFRandom but using xp_rand instead ofRAND() :”• Page 206: “Using xp_rand is twice as slow as rand() for single integers; …” shouldread “Using xp_rand is twice as slow as RAND() for single integers; …”• Page 206: “First, implement this function using rand().” should read “First,implement this function using RAND().”• Page 206: “The UDF has a loop with a number of calls to rand().” should read“The UDF has a loop with a number of calls to RAND().”• Page 207: “… such as the one shipped with the C compiler or TSQL’s rand()function.” should read “… such as the one shipped with the C compiler or TSQL’s RAND() function.”Chapter 14: Retrieving CPU Usage: (xp_cpuusage) • Page 226: “Schedule name Check CPU sched” should read “Schedule name CheckCPU sched” • Page 229: “… and the tenth more recent record” should read “… and the tenthmost recent record.” • Page 229: “If the most recent record and tenth more recent one are …” shouldread “If the most recent record and tenth most recent one are …” Chapter 15: Raw Sockets Sample: (xp_rawip) • Page 233: “… still detects old threats or that is effective against new ones.”Should read “… still detects old threats or is effective against new ones.” • Page 233: “The next chapter will focus more attention to GeographicalInformation Systems (GIS) …” should read “The next chapter will look at Geographical Information Systems (GIS) …” Chapter 16: Geographical Information Systems: (xp_gis) • Page 240: “The satellites value is the number of measurements…” should read“The Satellites value is the number of measurements…”• Page 240: “http://www.colorado.edu...” should appear without underlines• Page 241: “http://home.hiwaay.net...” should appear without underlines• Page 241: “http://www.colorado.edu...” should appear without underlines• Page 242: “http://www.gpsy.com...” should appear without underlinesChapter 17: Regular Expressions (xp_regexp) • Page 247: “http://sqlteam.com...” should appear without underlinesChapter 19: Computational Astronomy (xp_astro) • Page 269: “The complete datetime data type is presented to an XP as adbdatetime structure,…” should read “The complete datetime data type is presented to an XP as a DBDATETIME structure,…” • Page 270, 271, 273: All occurrences of “xp_astro_date2julian” should read“XP_ASTRO_DATE2JULIAN” • Page 270, 271: All occurrences of “xp_astro_julian2date” should read“XP_ASTRO_JULIAN2DATE” • Page 272, 273, 275: All occurrences of “xp_astro_deltat” should read“XP_ASTRO_DELTAT” • Page 274: “This value is used by the AA+ class framework functions, the publicmethods …” should read “This value is used by the AA+ class framework functions, namely the public methods …” • Page 276: All occurrences of “xp_astro_moonphasek” should read“XP_ASTRO_MOONPHASEK” • Page 276: All occurrences of “xp_astro_moonphase” should read“XP_ASTRO_MOONPHASE” Chapter 20: IP Configuration (xp_ipconfig) • Page 282: “char* pszHostName = “”;” should read “char*pszHostName = "Host Name"; ”Chapter 21: Beyond C/C++ (xp_runscript) • Page 289: “The xpserver Object” heading should read “The XPServerObject” • Page 290: “SendDone*” in Table 21.1 should read “SendDone”• Page 293: “, the result would have the same number of items in …” should read“, we will have the same number of items in …” • Page 294: “, the JScript code is allowed to look like:” should read “, JScript codewhich returns a sample recordset is allowed to look like:” • Page 303: ”… is used when any script requests the parameters property …” shouldread ”… is used when any script requests the P arameters property …”• Page 311: “… to cover scripting languages such as JScript, VBScript, as well …”should read “… to cover scripting languages such as JScript and VBScript, as well …” Chapter 23: Managed code in SQL Server 2005 • Page 320: “Alternatively, using xp_runscript might be an option when there is a lot of codein TSQL which is calling into the COM object to use .” should read “Alternatively, usingxp_runscript might be an option when there is a lot of code in TSQL which iscalling into the COM object to use.” Chapter 24: Security in SQL Server 2000 • Page 335: “If the application using SQL Server is running in the same box,”should read “If the application using SQL Server is running on the same box,” • Page 335: “the best solution is to remove all protocols, netlibs in the ServerNetwork Utility.” should read “the best solution is to remove all protocols in the Server Network Utility.” • Page 335: “The client should have set enabled shared memory protocol.” Shouldread “In the client Network Utility you should make sure the “Enable shared memory protocol” option is checked” • Page 335: “To enumerate a list of SQL Servers in a network can be accomplishedby either running Osql –L or sending a broadcast UDP packet to port 1434.”should read “To enumerate a list of SQL Servers in a network you can use Osql -L which ends up sending a broadcast UDP packet to port 1434” • Page 235: “ChipAndrews, Rajiv Delwadia and …” should read “Chip Andrews,Rajiv Delwadia and …” • Page 337: “…, which is the TCP access to the database, usually remote.” shouldread “…, which is the TCP port used to access the database, usually from a remote machine.” • Page 337: “However, 1434, the UDP used to access …” should read “However,port 1434 which is the UDP port used to access …” • Page 337: “…, SQL Server will take this port and used it thereafter.” should read“…, SQL Server will take this port and use it thereafter.” • Page 347: “SELECT username from Table_users WHERElogname=’mike’ AND userpassword=’a1234’ ” should read |