Restart Host cmd script

After deploying BizTalk solutions it is best to recycle the host instances. Normally these are recycled serial. This script will recycle them in parallel by executing them in separate cmd’s.

start net stop btssvc$biztalkserverapplication 
start net stop BTSSvc$BizTalkServerApplicationBulk 
start net stop BTSSvc$BizTalkServerMSMQ 
start net stop BTSSvc$BiztalkServerReceive
start net stop BTSSvc$BizTalkServerReceiveBulk 
start net stop BTSSvc$BizTalkServerReceiveSingleServer
start net stop BTSSvc$BizTalkServerSend
start net stop BTSSvc$BizTalkServerSend32
start net stop BTSSvc$BizTalkServerSendBulk
start net stop BTSSvc$BizTalkServerSendSingleServer
start net stop BTSSvc$BizTalkServerTracking 

timeout /t 10

start net start btssvc$biztalkserverapplication 
start net start BTSSvc$BizTalkServerApplicationBulk 
start net start BTSSvc$BizTalkServerMSMQ 
start net start BTSSvc$BiztalkServerReceive
start net start BTSSvc$BizTalkServerReceiveBulk 
start net start BTSSvc$BizTalkServerReceiveSingleServer
start net start BTSSvc$BizTalkServerSend
start net start BTSSvc$BizTalkServerSend32
start net start BTSSvc$BizTalkServerSendBulk
start net start BTSSvc$BizTalkServerSendSingleServer
start net start BTSSvc$BizTalkServerTracking

Check the naming of the services en restart!

Get size of all tables in database

Copied this script from here. Need this too often.

SELECT
t.NAME AS TableName,
s.Name AS SchemaName,
p.rows AS RowCounts,
SUM(a.total_pages) * 8 AS TotalSpaceKB,
CAST(ROUND(((SUM(a.total_pages) * 8) / 1024.00), 2) AS NUMERIC(36, 2)) AS TotalSpaceMB,
SUM(a.used_pages) * 8 AS UsedSpaceKB,
CAST(ROUND(((SUM(a.used_pages) * 8) / 1024.00), 2) AS NUMERIC(36, 2)) AS UsedSpaceMB,
(SUM(a.total_pages) - SUM(a.used_pages)) * 8 AS UnusedSpaceKB,
CAST(ROUND(((SUM(a.total_pages) - SUM(a.used_pages)) * 8) / 1024.00, 2) AS NUMERIC(36, 2)) AS UnusedSpaceMB
FROM
sys.tables t
INNER JOIN
sys.indexes i ON t.OBJECT_ID = i.object_id
INNER JOIN
sys.partitions p ON i.object_id = p.OBJECT_ID AND i.index_id = p.index_id
INNER JOIN
sys.allocation_units a ON p.partition_id = a.container_id
LEFT OUTER JOIN
sys.schemas s ON t.schema_id = s.schema_id
WHERE
t.NAME NOT LIKE 'dt%'
AND t.is_ms_shipped = 0
AND i.OBJECT_ID > 255
GROUP BY
t.Name, s.Name, p.Rows
ORDER BY
t.Name

Subtype: ‘{EF7E3281-CD33-11D4-8326-00C04FA0CE8D}’ is unsupported by this installation.

When you get this message:


---------------------------
<a href="http://venneker.net/2011/09/12/microsoft-without-borders/">Microsoft Visual Studio</a>
---------------------------
The project file 'C:\**\AppData\Local\Temp\2\r3trklcs.34z\Temp\BizTalk Server Project3.btproj' cannot be opened.

There is a missing project subtype.
Subtype: '{EF7E3281-CD33-11D4-8326-00C04FA0CE8D}' is unsupported by this installation.
---------------------------
OK Help
---------------------------

Repair your BizTalk installation. You will need the biztalk installation disc.

SAP Adapter error

My integration was not working with only this error in the eventlog:

Microsoft.ServiceModel.Channels.Common.XmlReaderGenerationException: An error occurred when trying to convert the byte array [30-00-30-00-30-00-30-00-30-00-30-00-30-00-30-00] of RFCTYPE RFCTYPE_DATE with length 8 and decimals 0 to XML format. Parameter/field name: REF_DATE   Error message: Year, Month, and Day parameters describe an un-representable DateTime. —> System.ArgumentOutOfRangeException: Year, Month, and Day parameters describe an un-representable DateTime. 

Generating new xsd schemas from the adapter with the option enable safetyping was not helping. Then I changed the document type to rfc:

This worked, the message was received by BIzTalk, but a complete other schema! The setting was set in SAP to put out a Typed document.

You do not see anything happening in BizTalk when this happens only in the evenlog. I was changing the settings of the SAP adapter and every time the SAP guy needed to send the document again. Hope this saves some time for you.

 

Cheers.