I am trying to convert a vb6 program to vb.net. I don't think I fully understand the whole dataset/binding.
So my sql code is this:
Data from this was used to populate a combobox.
So in visual studio 2010, in my project i went to add new data source, followed the wizard and added the tables used in the above sql to create the data set. So in the designer I have the 5 tables. how do I make the dataset equal to the above? What am I missing?
Thanks
So my sql code is this:
VB.NET:
SELECT CASE
WHEN e.empl_middle_init != ' '
THEN e.empl_last_name||', '||e.empl_first_name||' '||e.empl_middle_init||'.'
ELSE e.empl_last_name||', '||e.empl_first_name
END Employee,e.empl_id,e.empl_empl_id,p.ppcd_cd TYPE,c.clas_desc ORG,
o.orgn_cd ORGN,e.empl_pacc_id Prim,e.empl_cctr_id BC,e.empl_entity Entity,
e.empl_sep_dt SepDT,e.empl_type_id,e.empl_oref,e.empl_sect,e.empl_ppcd,
NVL(h.min_pp,0) min_pp,NVL(h.max_pp,0) max_pp,e.empl_job_cd JobCode
FROM
fset.tfsetempl e LEFT JOIN fset.tfsetorgn o ON o.orgn_oref = e.empl_oref
INNER JOIN
fset.tfsetppcd p ON e.empl_ppcd=p.ppcd_pref
LEFT JOIN
fset.tfsetclas c ON o.orgn_clas = c.clas_cref
LEFT JOIN
(SELECT a.hist_empl_id empl_id,MIN(hist_pp) min_pp,MAX(hist_pp) max_pp FROM fset.tfsethist a WHERE a.hist_yr = 2013 GROUP BY a.hist_empl_id) h ON e.empl_id=h.empl_id
where (e.empl_sep_dt is null or e.empl_sep_dt > to_date('12/31/2012','mm/dd/yyyy'))
ORDER BY 1 ASC
Data from this was used to populate a combobox.
So in visual studio 2010, in my project i went to add new data source, followed the wizard and added the tables used in the above sql to create the data set. So in the designer I have the 5 tables. how do I make the dataset equal to the above? What am I missing?
Thanks