{sql:select * from her_project
WHERE her_project.rowid = @File number@
}
GAT Project Gazetteer {title}
{subtable:
SELECT her_core.prn,
ifnull(her_core.name,' ') as name,
her_core.form,
ifnull(her_core.summary,' ') as s1,
ifnull(her_core.desc_1,' ') as d1,
ifnull(geo_locations.community,'-')community,
ifnull(GROUP_CONCAT(DISTINCT concat(ifnull(her_core_site_type.period,''),', ',ifnull(her_core_site_type.type,''),', Sitetype ranking: ',ifnull(her_core_site_type.rank,'-')) SEPARATOR '[br] '),'') as t1,
ifnull(GROUP_CONCAT(DISTINCT concat('CONDITION: ',ifnull(her_condition.condition,'None recorded'),' CONDITION RATING: ',ifnull(her_condition.rating,'None recorded'),' DESCRIPTION: ',ifnull(her_condition.condesc,'None recorded'),' RELATED EVENT: ' ,ifnull(her_condition.eventprn,'None recorded'),' DATE OF ENTRY: ',ifnull(her_condition.compiledon,'None recorded')) SEPARATOR '[Br]'),'') as c1,
ifnull(GROUP_CONCAT(DISTINCT concat(ifnull(her_status.status,'None recorded '),' ',ifnull(her_status.reference,' '),' ',ifnull(her_status.grade,'')) SEPARATOR ', '),' ') as status1,
ifnull(GROUP_CONCAT(DISTINCT concat(ifnull(her_source2.author,' '),' ',ifnull(her_source2.organisation,' '),' ',ifnull(her_source2.year,' '),' ',ifnull(her_source2.artcl_titl,' '),', ',ifnull(her_source2.title,' '),', ',ifnull(her_source2.other,' '),' ',ifnull(her_source2.gw_bibref,' ')) SEPARATOR '[br]' ),'') as bib,
ifnull(GROUP_CONCAT(DISTINCT concat(ifnull(her_source1.srcetype,' '),': ',ifnull(her_source1.author,' '),' ',ifnull(her_source1.year,' '),', ',ifnull(her_source1.title,' '),', ',ifnull(her_source1.journal,' '),', ',ifnull(her_source1.volume,' '),', ',ifnull(her_source1.page,' '),', ',ifnull(her_source1.refno,' ')) SEPARATOR '[br]' ),'') as bib2,
ifnull(GROUP_CONCAT(DISTINCT concat(ifnull(geo_locations.ngr,'None recorded')) SEPARATOR ', '),'') as ngr
FROM her_core
JOIN her_project_link on her_core.watprn=her_project_link.watprn
LEFT JOIN geo_locations on geo_locations.watprn=her_core.watprn
LEFT JOIN her_core_site_type on her_core_site_type.watprn=her_core.watprn
LEFT JOIN her_condition on her_condition.watprn=her_core.watprn
LEFT JOIN her_status on her_status.watprn=her_core.watprn and her_status.status_typ not like "%area%"
LEFT JOIN her_core_event_link on her_core_event_link.watprn=her_core.watprn
LEFT JOIN her_event ON her_core_event_link.ewatprn = her_event.watprn
LEFT JOIN her_source2 on her_source2.watprn=her_core.watprn
LEFT JOIN her_source1_link on her_source1_link.watprn=her_core.watprn
LEFT JOIN her_source1 on her_source1.rowid=her_source1_link.source_id
WHERE her_project_link.fileno=[rowid]
group by her_core.prn;
title:[b][i]PRN[/i][/b] , prn,[br][b][i]NAME[/i][/b] , name ,[br][b][i]NGR[/i][/b] , ngr ,[br][b][i]COMMUNITY[/i][/b] , community,[br],[b][i]PERIOD AND TYPE[/i] [/b] , t1,[br][br],[b][i]DESCRIPTION[/i][/b] , d1, [br] [br],[b][i]SUMMARY[/i][/b] , s1, [br][br],[b][i]CONDITION[/i][/b][br],c1, [br][br],[b][i]STATUS[/i][/b] ,status1,[br][br] ,[b][i]SOURCES[/i][/b][br],bib, [br],bib2,[br]}
Key to Abbreviations and Terms
GAT: Gwynedd Archaeological Trust; PRN : Primary Reference Number, each site is given a unique PRN; NAME: The common name given to the site; NGR: Ordnance Survey National Grid Reference; COMMUNITY: The community council in which the site is located; PERIOD: The period to which the site belongs; TYPE: Describes the site type; SITE TYPE RANKING: Indicates the preferred site type interpretation, Rank 1 being the highest; SUMMARY: A short, unreferenced site summary written by HER staff; DESCRIPTION: Detailed site notes compiled from various sources; CONDITION INFORMATION: The condition of the site at the time of assessment; STATUS: The legal status of the site, e.g. Scheduled Ancient Monument; SOURCES: The bibliographic references relating to the site