lt; th gt; ІПН lt;/th gt;
lt; th gt; Код соц. страхування lt;/th gt;
lt; th gt; Телефонний номер lt;/th gt; lt;/tr gt; lt;/thead gt;
lt; tbody gt;foreach (var row in db.Query (selectQueryString))
{ lt; tr gt; lt; td gt; @ row.ID lt;/td gt;
lt; td gt; @ row.TN lt;/td gt;
lt; td gt; @ row.FN lt;/td gt;
lt; td gt; @ row.MN lt;/td gt;
lt; td gt; @ row.LN lt;/td gt;
lt; td gt; @ row.GN lt;/td gt;
lt; td gt; @ row.date lt;/td gt;
lt; td gt; @ row.series lt;/td gt;
lt; td gt; @ row.pasnumber lt;/td gt;
lt; td gt; @ row.INN lt;/td gt;
lt; td gt; @ row.INNsafe lt;/td gt;
lt; td gt; @ row.phoneNumber lt;/td gt; lt;/tr gt;}
lt;/tbody gt;
lt;/table gt;
lt;/body gt;
lt;/html gt;
Лістинг 3
@ {db=Database.Open ( Worker ); tn= +8508 raquo ;; selectQueryString= SELECT id_worker, tableNumber, FirstName, MiddleName, LastName, +
tb_worker.id_passport IDPAS, series, pasnumber, CONVERT (char (10), date_of_birth, 102) as date1, tb_gender.value GV, TBPD.Name IDPD, tb_country.value IDCN, +
tb_region.value IDRN, tb_city.value IDCCN, CONVERT (char (10), date, 102) as date2 FROM tb_worker +
JOIN tb_passport ON tb_worker.id_passport=tb_passport.id_passport +
JOIN tb_pas_department AS TBPD ON tb_passport.id_pas_department=TBPD.id_pas_department +
JOIN tb_country ON tb_country.id_country=TBPD.id_country +
JOIN tb_region ON tb_region.id_region=TBPD.id_region +
JOIN tb_city ON tb_city.id_city=TBPD.id_city +
JOIN tb_gender ON tb_passport.id_gender=tb_gender.id_gender +
WHERE tableNumber= + Tn; selectQueryString2= SELECT phoneNumber, tb_country.value TBCV, tb_region.value TBRV, tb_city.value TBCCV, +
tb_district.value TBDV, zipCode, street, house_number, flat_number FROM tb_worker +
JOIN tb_passport ON tb_worker.id_passport=tb_passport.id_passport +
JOIN tb_country ON tb_country.id_country=tb_passport.id_country +
JOIN tb_region ON tb_region.id_region=tb_passport.id_region +
JOIN tb_city ON tb_city.id_city=tb_passport.id_city +
JOIN tb_district ON tb_district.id_district=tb_passport.id_district +
WHERE tableNumber= + Tn; selectQueryString3= SELECT tableNumber, tb_priznak.Value TBV, +
tb_occupation.Name TOPO, CONVERT (char (10), date_dvizeniya, 102) as date, +
tb_uchastok.Name NU, tb_podrazdeleniye.Name NP FROM tb_worker +
RIGHT JOIN tb_dvizeniye ON tb_dvizeniye.id_worker=tb_worker.id_worker +
JOIN tb_priznak ON tb_priznak.id_priznak=tb_dvizeniye.id_priznak +
JOIN tb_occupation ON tb_occupation.id_profession=tb_dvizeniye.id_profession +
JOIN tb_uchastok ON tb_uchastok.id_uchastok=tb_occupation.id_uchastok +
JOIN tb_podrazdeleniye ON tb_podrazdeleniye.id_podrazdeleniye=tb_uchastok.id_podrazdeleniye +
WHERE tableNumber= + Tn;
}
lt;! DOCTYPE html gt;
lt; html lang= en gt;
lt; head gt;
lt; meta charset= utf - 8 / gt;
lt; title gt; Worker info lt;/title gt;
lt; style gt ;, th, td {: solid 1px #bbbbbb; collapse: collapse ;: 2px;
}
lt;/style gt;
lt;/head gt;
lt; body gt;
lt; h1 gt; Worker info lt;/h1 gt;
lt; h2 gt; Працівник lt;/h2 gt;
lt; table gt;
lt; thead gt;
lt; tr gt;
lt; th gt; ID lt;/th gt;
lt; th gt; TN lt;/th gt;
lt; th gt; Прізвище lt;/th gt;
lt; th...