diff --git a/Gremlin.sln b/Gremlin.sln
index 6bfef88..3920173 100644
--- a/Gremlin.sln
+++ b/Gremlin.sln
@@ -11,7 +11,9 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
.editorconfig.inferred = .editorconfig.inferred
EndProjectSection
EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Gremlin_Blazor", "Gremlin_Blazor\Gremlin_Blazor.csproj", "{FA6FA9E2-6874-4CE1-A7B9-D6B627E133AC}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Gremlin_Blazor", "Gremlin_Blazor\Gremlin_Blazor.csproj", "{FA6FA9E2-6874-4CE1-A7B9-D6B627E133AC}"
+EndProject
+Project("{888888A0-9F3D-457C-B088-3A5042F75D52}") = "Gremlin_Python", "Gremlin_Python\Gremlin_Python.pyproj", "{9E0CF057-C3D7-4F60-A4EC-93E712610B53}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -27,6 +29,8 @@ Global
{FA6FA9E2-6874-4CE1-A7B9-D6B627E133AC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{FA6FA9E2-6874-4CE1-A7B9-D6B627E133AC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{FA6FA9E2-6874-4CE1-A7B9-D6B627E133AC}.Release|Any CPU.Build.0 = Release|Any CPU
+ {9E0CF057-C3D7-4F60-A4EC-93E712610B53}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {9E0CF057-C3D7-4F60-A4EC-93E712610B53}.Release|Any CPU.ActiveCfg = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
diff --git a/Gremlin_Blazor/Pages/Index.razor b/Gremlin_Blazor/Pages/Index.razor
index cba3252..08bb37f 100644
--- a/Gremlin_Blazor/Pages/Index.razor
+++ b/Gremlin_Blazor/Pages/Index.razor
@@ -1,3 +1,3 @@
@page "/"
-
Hello, world!
+Willkommen zu Gremlin Blazor!
diff --git a/Gremlin_Blazor/Program.cs b/Gremlin_Blazor/Program.cs
index 56ce545..34e385d 100644
--- a/Gremlin_Blazor/Program.cs
+++ b/Gremlin_Blazor/Program.cs
@@ -1,11 +1,11 @@
using Microsoft.AspNetCore.Components;
using Microsoft.AspNetCore.Components.Web;
-var builder = WebApplication.CreateBuilder(args);
+WebApplicationBuilder builder = WebApplication.CreateBuilder(args);
builder.Services.AddRazorPages();
builder.Services.AddServerSideBlazor();
-var app = builder.Build();
+WebApplication app = builder.Build();
if (!app.Environment.IsDevelopment())
{
diff --git a/Gremlin_Blazor/appsettings.json b/Gremlin_Blazor/appsettings.json
index 10f68b8..5d8ba2e 100644
--- a/Gremlin_Blazor/appsettings.json
+++ b/Gremlin_Blazor/appsettings.json
@@ -1,9 +1,9 @@
{
+ "AllowedHosts": "*",
"Logging": {
"LogLevel": {
"Default": "Information",
"Microsoft.AspNetCore": "Warning"
}
- },
- "AllowedHosts": "*"
+ }
}
diff --git a/Gremlin_Python/.vscode/settings.json b/Gremlin_Python/.vscode/settings.json
new file mode 100644
index 0000000..d1ed07f
--- /dev/null
+++ b/Gremlin_Python/.vscode/settings.json
@@ -0,0 +1,5 @@
+{
+ "objectscript.conn": {
+ "active": true
+ }
+}
diff --git a/Gremlin_Python/Gremlin_Python.py b/Gremlin_Python/Gremlin_Python.py
new file mode 100644
index 0000000..9d679cb
--- /dev/null
+++ b/Gremlin_Python/Gremlin_Python.py
@@ -0,0 +1,38 @@
+import mysql.connector as database
+
+connection = database.connect(
+ host="woitschetzki.de",
+ port="3306",
+ user="sascha",
+ password="mgltoJtmmDnKJ86LltsGdw",
+ database="regulus")
+
+cursor = connection.cursor()
+
+
+def getContact(lastName):
+ try:
+ statement = "SELECT ContactId, AccountId, FirstName, LastName, Gender, Email FROM Contacts WHERE LastName LIKE %s"
+ data = (lastName,)
+ cursor.execute(statement, data)
+ rows = list(cursor)
+
+ print(f"Found {len(rows)} contacts with {lastName} in LastName:")
+ print("ContactId | AccountID | FirstName | LastName | Gender | Email")
+
+ for (contactId, AccountId, firstName, lastName, gender, email) in rows:
+ print(
+ f"{contactId} | {AccountId} | {firstName} | {lastName} | {gender} | {email}")
+
+ except database.Error as error:
+ print(f"Error retrieving entry from database: {error}")
+
+
+print("Willkommen bei Gremlin_Python!")
+
+while 2 > 1:
+ print("Nach welchem Kunden suchen Sie?: ")
+ contactSearch = input()
+ getContact(f"%{contactSearch}%")
+
+connection.close()
diff --git a/Gremlin_Python/Gremlin_Python.pyproj b/Gremlin_Python/Gremlin_Python.pyproj
new file mode 100644
index 0000000..186de83
--- /dev/null
+++ b/Gremlin_Python/Gremlin_Python.pyproj
@@ -0,0 +1,35 @@
+
+
+ Debug
+ 2.0
+ 9e0cf057-c3d7-4f60-a4ec-93e712610b53
+ .
+ Gremlin_Python.py
+
+
+ .
+ .
+ Gremlin_Python
+ Gremlin_Python
+
+
+ true
+ false
+
+
+ true
+ false
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file