korasoglu Posted July 8, 2014 Share Posted July 8, 2014 Arkadaşlar tablomdaki aynı olan veriler kaçtane olursa olsun tek olanlardan bir birden fazla olanlardan yine bir tane yüklemek istiyorum sgl sorgusu nasıl olmalı Teşekkür ederim. Quote Link to comment Share on other sites More sharing options...
Cyph3r Posted July 8, 2014 Share Posted July 8, 2014 Tablonun belirli bir sütununda mı bunu yapmak istiyorsun yoksa tümünde mi bilmiyorum ama tek sütun için şöyle bişey kullanmıştım.. SELECT SutunAdi from TabloAdi GROUP BY SutunAdi bu şekilde SutunAdi kısmına yazacağınız sütundaki veriler sadece birer kez yüklenir... Quote Link to comment Share on other sites More sharing options...
weyso Posted July 8, 2014 Share Posted July 8, 2014 SELECT DISTINCT SEHIR FROM Tbl_Kullanicilar DISTINCT ile de olur. yada böyle bi video var orda anlatıyor. http://www.prototurk.com/video/sql-having-kullanimi/127 Quote Link to comment Share on other sites More sharing options...
korasoglu Posted July 8, 2014 Author Share Posted July 8, 2014 (edited) Ben şöyle çözdüm sizinkinide bir deniyeyim. SELECT * FROM tabloadi WHERE tabloadi.id = ( SELECT MAX(tabloadi.id) WHERE tabloadi.sutunadi = tabloadi.sutunadi)GROUP BY sutunadi ORDER BY sutunadi ASC SELECT DISTINCT klise_liste FROM firma bu iş görmedi Arkadaşlar evet bu tek sutunda işe yarıyor SELECT firma from klise_liste GROUP BY firma Edited July 8, 2014 by korasoglu Quote Link to comment Share on other sites More sharing options...
korasoglu Posted July 18, 2014 Author Share Posted July 18, 2014 Arkadaşlar sql de 20 sutun ve 1500 satır ekledim bul dediğin zaman inputun canı çıkıyor yüklemede sıkıntı yaşıyor kasılıyor. Bunun en klay ve ideali nasıldır. ben ınputun onkeyine uyguladim aa = Input.GetText("ara") avci.baglan() SQLite3Connection, err = SQLite3Connection:execute("SELECT * FROM kisiler WHERE adi LIKE '%" .. aa .. "%' OR soyadi LIKE '%" .. aa .. "%' OR gorevi LIKE '%" .. aa .. "%' OR gorevyeri LIKE '%" .. aa .. "%' OR tahsil LIKE '%" .. aa .. "%'"); dd = SQLite3Connection:fetch({}, "a") if dd ~= nil then while dd do TreeList.AddRow("Plugin1", dd.adi .. "|" .. dd.soyadi.. "|" .. dd.tel ... dd = SQLite3Connection:fetch({}, "a") end end avci.kapat() Quote Link to comment Share on other sites More sharing options...
KintaRo Posted July 20, 2014 Share Posted July 20, 2014 kodları if e_Key == 13 then end bloğu içine alırsan, enter tuşuna basınca arama yapar. senin yaptığın şeklinde he rtuşa basınca sorgu çalışır. bu sistem seninkine nazaran daha az kasar. Quote Link to comment Share on other sites More sharing options...
korasoglu Posted July 21, 2014 Author Share Posted July 21, 2014 hocam şöylede oluyor. SELECT * FROM xxxx WHERE yyy LIKE '" .. aa .. "%' Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.