עבור לתוכן
View in the app

A better way to browse. Learn more.

HWzone

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.

מנסה להציג את השם והתעודת זהות בשאילתה

Featured Replies

פורסם


select MAX(salary) from Employes
inner join Terms
on Employes.Id=Terms.ID
where Terms.Extra is not null

יש לי 2 טבלאות, כאשר בטבלה terms יש לי נתונים נוספים על עובד, ובטבלה employes יש לי נתונים רגילים של עובד, תעודת זהות שם משכורת וכאלה

אני רוצה להראות את העובד שמקבל משכורת מקסימום מהטבלה של הemployees אבל שהוא מקבל משכורת אקסטרה

השאילתה עובדת כמו שצריך

זה באמת מראה לי את המשכורת הכי גבוהה מאלה שמקבלים משכורת אקסטרה

הבעיה שאני רוצה להראות חוץ מהמשכורת של אותו אדם גם את השם והתעודת זיהות

אבל שאני מוסיף id וגם name

אני מקבל שגיאת קומפילציה

Msg 8120, Level 16, State 1, Line 15

Column 'Employes.Id' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause.

איך אני פותר את זה ? אני רוצה להוסיף סככל את השם והתעודת זהות של אותו אדם עם המשכורת המקסימלית..

פורסם

נסה להשתמש ב subquery. תראה קצת דוגמאות באינטרנט....

ארכיון

דיון זה הועבר לארכיון ולא ניתן להוסיף בו תגובות חדשות.

דיונים חדשים

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.