-- Database schema
| langs : lid [ INTEGER ] primary_key , lang [ TEXT ] , locale [ TEXT ] , pages [ INTEGER ] , words [ INTEGER ] | pages : pid [ INTEGER ] primary_key , lid [ INTEGER ] pages.lid = langs.lid , page [ INTEGER ] , revision [ INTEGER ] , title [ TEXT ] , words [ INTEGER ] | words : wid [ INTEGER ] primary_key , word [ TEXT ] , occurrences [ INTEGER ] | langs_words : lid [ INTEGER ] langs_words.lid = langs.lid , wid [ INTEGER ] langs_words.wid = words.wid , occurrences [ INTEGER ] | pages_words : pid [ INTEGER ] pages_words.pid = pages.pid , wid [ INTEGER ] pages_words.wid = words.wid , occurrences [ INTEGER ] | biwords : lid [ INTEGER ] biwords.lid = langs.lid , w1st [ INTEGER ] biwords.w1st = words.wid , w2nd [ INTEGER ] biwords.w2nd = words.wid , occurrences [ INTEGER ] |
-- -- Calculate the average number of the word occurrences in which ‘system’ appeared as the first word in the pair.

SELECT AVG(T2.occurrences) FROM words AS T1 INNER JOIN biwords AS T2 ON T1.wid = T2.w1st WHERE T2.w1st = ( SELECT wid FROM words WHERE word = 'sistema' );