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.

sql abfrage fehler

Empfohlene Antworten

Veröffentlicht

hi, müsste zwei tabellen db1 db2 vergelichen , weil ein user mehrmals interntzugang haben kann, deshalb habe ich den distinct befehl gewählt. wo ist hier der syntaxfehler ? danke

select count(*) (

select distinct from db1 a, db2 b

where b.Internet = '1'

and d.indexnummer = b.mitarbeiter_nr

)

Original geschrieben von SySi2001

select distinct from db1 a, db2 b

Du hast da keine Felder angegeben, so weiß er ja nicht was er auslesen soll.

Original geschrieben von SySi2001

wo ist hier der syntaxfehler ? danke

select count(*) (

select distinct from db1 a, db2 b

where b.Internet = '1'

and d.indexnummer = b.mitarbeiter_nr

)

Nu gut. Was soll da bitte das Select Count(*) und danach auch noch ne Klammer?

Dein select count(*) ist ein Statement und das select distinct from... ein zweites, das hat also miteinander so wie das hier steht nichts zutun (ich kann aber jetzt nicht entscheiden, ob es sollte, oder nicht)

Das zweite koenntest mal so machen:

select distinct d.indexnummer from db1 a, db2 b
where b.Internet = '1'
and d.indexnummer = b.mitarbeiter_nr[/PHP]

Dein distinct alleine reicht da nicht, du musst schon nen Parameter selektieren.

Goos

thx

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.