Overclock.net - An Overclocking Community - View Single Post - How to optimize this SQL query

View Single Post
post #3 of (permalink) Old 12-03-2018, 05:04 AM
Streetdragon
Manual breath enabled
 
Streetdragon's Avatar
 
Join Date: Apr 2013
Location: In my celler
Posts: 1,194
Rep: 26 (Unique: 22)
this is SQL? ok new form for me.

where is the select, or do you need all data?
headdata = db.Assets or so
metadata = main table i think nothing new for you

Select count(headdata.id) AS counter,headdata.id,metadata.a,metadata.b
FROM metadatta
left outer join headdata on headdata.id = metadata.id
group by headdata.id,metadata.a,metadata.b


edit: where metadatta.year = 2018
and if you need: and headdata.id is not null
something like that

Gameingcube
(18 items)
CPU
Ryzen 3900X
Motherboard
Aorus X570 Master
GPU
1080 TI Founders Edition
GPU
1080 TI Founders Edition
RAM
F4-3600C16Q-32GTZR
Hard Drive
2000GB Seagate Barracuda Compute ST2000DM008 256MB
Hard Drive
2000GB Seagate Barracuda Compute ST2000DM008 256MB
Hard Drive
samsung m2 970 evo
Power Supply
Leadex 80 Plus Platinum Netzteil, schwarz - 1200 Watt
Cooling
heatkiller IV pro
Cooling
EK-FC1080 GTX Ti - Nickel
Cooling
EK-FC1080 GTX Ti - Nickel
Cooling
Alphacool Eisbecher D5 250mm Plexi
Cooling
Alphacool NexXxoS XT45 Full Copper 480mm
Cooling
XSPC Multiport Radiator EX240
Cooling
Scythe Grand Flex 4Pin PWM
Case
thermaltake core x9
Operating System
Windows 10
▲ hide details ▲
Streetdragon is offline