Incorrect db script for MS SQL
Openfire 3.5 latest (downloaded yesterday), used the plugins section to download the Asterisk-IM plugin and the install failed.
SQL Server 2005, code from resources/asterisk-im_sqlserver.sql ...
phoneUser.userID is defined as an integer, phoneDevice.userID is a bigint, and the constraint linking the two fails because of this.
Redefining the phoneDevice.userID to be an integer allows the script to run.