Author Posts

August 17, 2017 at 9:56 am

Hi Guys,

I would like to put some information in a collum of a sql databases. The following information i got:

Sqlserver 2012SQL1
Databasename DB1
Table DBO.User

In the DBO.user is a field where i want to add some numbers. I would like to find an emailadress and then add text to a different collum lets say the the name of that is numbers.

Could you help where to start please?

King Regards

August 17, 2017 at 1:08 pm

I can show you the code for executing a SQL query – it's also in our free book on making trend and historical reports. The actual .NET Framework code is pretty simple, and if you have the SQL Server module it's even easier – just run Invoke-SQL.

You'll need to know how to write a T-SQL query, but that's not really a PowerShell question at that point. The aforementioned book does have some query language examples. There are also tons of online references for SQL queries.

August 18, 2017 at 1:13 pm

Thanks Don, will look into the documentation.