Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

insert in mehrere tabellen

Empfohlene Antworten

Veröffentlicht

hallo

hab folgendes problem:

ich habe 2 tabellen.

tabelle 1:

- ID

- name

- status

tabelle 2:

- ID

- email

- ...

ich habe ein eingabeformular, in dem alle daten eingegeben werden können und diese sollen dann in die verschiedenen tabellen gespeichert werden.

wie muss der insert befehl lauten, wenn die ID in tabelle 1 'autoincrement' ist, damit ich beide tabelle füllen kann?

bis jetzt hab ich nur:

INSERT INTO tabelle 1 (name, status) VALUES ( x, y);

mfg

noah

Hallo,

so funktioniert es bei MySQL.

Andere Datenbanken habe ähnliche Mechanismen.

INSERT INTO tabelle1 VALUES (NULL, 'müller','neu');

INSERT INTO tabelle2 VALUES

(LAST_INSERT_ID(), 'mueller@web.de'),

(LAST_INSERT_ID(), 'mueller@gmx.de');

Gruß Jaraz

hallo,

danke. ich werd das mal probieren. auf mySQL und hab zugriff über PHP

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.