MS Brackets

This commit is contained in:
2020-10-28 15:45:44 +01:00
parent d38efc1cbe
commit dc7e3e2785
38 changed files with 332 additions and 341 deletions

View File

@@ -178,7 +178,7 @@ Namespace SyncUsers
Try
Dim oUserId As Integer = GetUserId(User.samAccountName)
If oUserId = 0 Then
Dim oSQL As String = $"INSERT INTO TBDD_USER (PRENAME, NAME, USERNAME, EMAIL, ADDED_WHO) VALUES ('{User.GivenName}', '{User.Surname}', UPPER('{User.samAccountName}'), '{User.Email}', '{ADDED_WHO}')"
Dim oSQL As String = $"INSERT INTO TBDD_USER (PRENAME, NAME, USERNAME, EMAIL, ADDED_WHO) VALUES ('{User.GivenName}', '{User.Surname.Replace("'", "''")}', UPPER('{User.samAccountName.Replace("'", "''")}'), '{User.Email.Replace("'", "''")}', '{ADDED_WHO}')"
Dim oResult = _mssql.ExecuteNonQuery(oSQL)
If oResult = True Then
@@ -201,7 +201,7 @@ Namespace SyncUsers
Try
Dim oUserId As Integer = GetUserId(User.samAccountName)
If oUserId > 0 Then
Dim oSQL As String = $"UPDATE TBDD_USER SET PRENAME = '{User.GivenName}', NAME = '{User.Surname}', EMAIL = '{User.Email}', CHANGED_WHO = '{ADDED_WHO}' WHERE GUID = {oUserId}"
Dim oSQL As String = $"UPDATE TBDD_USER SET PRENAME = '{User.GivenName}', NAME = '{User.Surname.Replace("'", "''")}', EMAIL = '{User.Email.Replace("'", "''")}', CHANGED_WHO = '{ADDED_WHO}' WHERE GUID = {oUserId}"
Dim oResult = _mssql.ExecuteNonQuery(oSQL)
If oResult = True Then

View File

@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' übernehmen, indem Sie "*" eingeben:
' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("1.4.0.0")>
<Assembly: AssemblyFileVersion("1.4.0.0")>
<Assembly: AssemblyVersion("1.5.0.0")>
<Assembly: AssemblyFileVersion("1.5.0.0")>