How to search for a value, in all columns of a Microsoft SQL Server Database

If you want to search in for a specific value in all columns of a Microsoft SQL Server Database, you can use the following T-SQL stored procedure:

 

CREATE PROC SearchAllTables(  
@SearchStr nvarchar(100)  
) AS  
BEGIN  
CREATE TABLE #Results (ColumnName nvarchar(370), ColumnValue nvarchar(3630))  
SET NOCOUNT ON  
DECLARE @TableName nvarchar(256), @ColumnName nvarchar(128), @SearchStr2 nvarchar(110)  
SET  @TableName = ''  
SET @SearchStr2 = QUOTENAME('%' + @SearchStr + '%','''')  
WHILE @TableName IS NOT NULL  
BEGIN  
SET @ColumnName = ''  
SET @TableName =  
(  
SELECT MIN(QUOTENAME(TABLE_SCHEMA) + '.' + QUOTENAME(TABLE_NAME))  
FROM    INFORMATION_SCHEMA.TABLES  
WHERE           TABLE_TYPE = 'BASE TABLE'  
AND     QUOTENAME(TABLE_SCHEMA) + '.' + QUOTENAME(TABLE_NAME) > @TableName  
AND     OBJECTPROPERTY(  
OBJECT_ID(  
QUOTENAME(TABLE_SCHEMA) + '.' + QUOTENAME(TABLE_NAME)  
), 'IsMSShipped'  
) = 0  
)  
WHILE (@TableName IS NOT NULL) AND (@ColumnName IS NOT NULL)  
BEGIN  
SET @ColumnName =  
(  
SELECT MIN(QUOTENAME(COLUMN_NAME))  
FROM    INFORMATION_SCHEMA.COLUMNS  
WHERE           TABLE_SCHEMA    = PARSENAME(@TableName, 2)  
AND     TABLE_NAME      = PARSENAME(@TableName, 1)  
AND     DATA_TYPE IN ('char', 'varchar', 'nchar', 'nvarchar')  
AND     QUOTENAME(COLUMN_NAME) > @ColumnName  
)  
IF @ColumnName IS NOT NULL  
BEGIN  
INSERT INTO #Results  
EXEC  
(  
'SELECT ''' + @TableName + '.' + @ColumnName + ''', LEFT(' + @ColumnName + ', 3630)  
FROM ' + @TableName + ' (NOLOCK) ' +  
' WHERE ' + @ColumnName + ' LIKE ' + @SearchStr2  
)  
END  
END  
END  
SELECT ColumnName, ColumnValue FROM #Results  
drop table #Results
END  

Keyboard shortcut for Googles I’n feeling lucky button in IE

 

http://www.google.com/support/forum/p/Chrome/thread?tid=2202d70b8d5261cc&hl=en

1. Go to this site http://www.ieaddons.com/en/createsearch.aspx
2. Where it asks for an URL paste http://www.google.com/search?ie=UTF-8&oe=UTF-8&sourceid=navclient&gfns=1&q=TEST
3. Where it asks for a name type Google – I’m Feeling Lucky!
4. Click the Install Search Provider button.
5. Check the box that says Make this my default search provider.
6. Click the Add button.
7. Press CTRL + E to enter the Searchbox and type in keywords in the search box that describe the site you want like ADA ICT for http://www.ada-ict.nl/

8. After pressing enter the site http://www.ada-ict.nl will be opened in the current tab

How to solve “The configured proxy server is not responding” when using VPN

 

When I used a VPN connection I did not have internet connection, when I disconnected the VPN connection I had internet access again. I used the Microsoft Windows 7 Network Diagnostics tool to see what the problem could be.

It responded with the error message: “The configured proxy server is not responding”. Well normally you would go to:

Start > Control Panel > Internet Options > Connections > LAN Settings

image

 

Uncheck the “Use a proxy server for you LAN (These settings will not apply to dial-up or VPN connections).”

image

 

But that this not fix my problem, then I red the checkbox text again:

Use a proxy server for you LAN (These settings will not apply to dial-up or VPN connections).”

 

I was using a VPN connection, so there had to be another way to set the proxy settings for a VPN connection and there is, go to:

Start > Control Panel > Internet Options > Connections > Select you’re VPN connection and click on [Settings]

image

 

Uncheck the “Use a proxy server for this connection (These settings will not apply to other connections)”

 

image

 

After unchecking this box I was able to get internet access, when using the VPN connection

 

 

Error in the Microsoft Windows 7 Network Diagnostics dialog

 

image

 

 

Error in Google Chrome

Unable to connect to the proxy server.

A proxy server is a server that acts as an intermediary between your computer and other servers. Right now, your system is configured to use a proxy, but Google Chrome can’t connect to it.
If you use a proxy server, check your proxy settings or check with your network administrator to make sure the proxy server is working.
If you don’t believe you should be using a proxy server, try the following steps:
Go to the Wrench menu > Options > Under the Hood > Change proxy settings > LAN Settings and uncheck "Use a proxy server for your LAN.