I got the following error message, when I was trying to process an Analysis Services cube on my development machine:
Errors in the high-level relational engine. A connection could not be made to the data source with the DataSourceID of ‘xxx′, Name of ‘yyy′
The error message is not very meaningful. To resolve the issue you should check the impersonation settings of the datasource and specifiy an appropriate Windows account:
Today I had the problem that I needed to concatenate values of a column from multiple rows of a table. I was developing a report for SQL Server Reporting Services and the data source was a SQL Server Database. So I ended up using T-SQL with the special FOR XML PATH – Command. The FOR XML command is used with T-SQL to format the results of a query as XML.
The following table contains a list of some car manufacturers:
To get a comma separated list of manufacturers I can take the following T-SQL statement:
1: SELECT STUFF( (SELECT ',' + Manufacturer From CarManufacturer FOR XML PATH('') ), 1, 1, '') as 'Car Manufacturers'
The result looks like this:
To determine the size of a table inside SQL Server you can use the following SQL statement:
EXEC sp_spaceused '<tablename>'
If you want to do this for all tables simply use the undocumented procedure
EXEC sp_MSforeachtable @command1="EXEC sp_spaceused '?'"