FORUM PER UTENTI MILLEWIN
Attenzione !
Per intervenire sul forum è necessario essere registrati e connessi.

L'Amministratore

****************************************************
“Se tu hai una mela ed io ho una mela, e ce la scambiamo, alla fine tu ed io avremo sempre una mela ciascuno.
Ma se tu hai un’idea ed io ho un’idea, e ce la scambiamo, allora avremo entrambi due idee”.

George Bernard Shaw
****************************************************

Unisciti al forum, è facile e veloce

FORUM PER UTENTI MILLEWIN
Attenzione !
Per intervenire sul forum è necessario essere registrati e connessi.

L'Amministratore

****************************************************
“Se tu hai una mela ed io ho una mela, e ce la scambiamo, alla fine tu ed io avremo sempre una mela ciascuno.
Ma se tu hai un’idea ed io ho un’idea, e ce la scambiamo, allora avremo entrambi due idee”.

George Bernard Shaw
****************************************************
FORUM PER UTENTI MILLEWIN
Vuoi reagire a questo messaggio? Crea un account in pochi click o accedi per continuare.

ASA Vs Neoplasie

5 partecipanti

Andare in basso

ASA Vs Neoplasie Empty ASA Vs Neoplasie

Messaggio  drtulino Dom 4 Mag 2014 - 23:04

Come gruppo SIMG della mia provincia, in virtù delle evidenze scientifiche internazionali che parlano di una riduzione del 10% di rischio di contrarre una neoplasia (anche con metastasi) dopo assunzione di ASA per un periodo di 10 anni o più, vorremmo verificare questi dati nei Nostri archivi.
Non so se è possibile ricavare una query con le seguenti impostazioni:
- Tre gruppi di pazienti:
o Pazienti senza trattamento con ASA (ATC: B01AC06) ;
o Pazienti con trattamento di ASA da meno di 10 anni;
o Pazienti con trattamento di ASA da 10 o più anni.
- Ognuno di questi gruppi di pazienti dovrebbe essere diviso per le seguenti fasce di età: 30-39, 40-49, 50-59, 60-
69, > 70
- Per ognuno di questi gruppi e per ogni fascia di età selezionare i soggetti:
1. numero dei Ca colon-retto
2. numero dei Ca polmone
3. numero dei Ca Mammella
4. altri
Se fosse possibile i dati dovrebbero essere raccolti per righe (orizzontale) e non per colonna (verticale).
Chiedo agli Esperti di Sql se mi possono dare una mano a fare le suddette estrazioni dagli archivi dei Colleghi che vorranno partecipare.
Ringrazio anticipatamente.
drtulino
drtulino
Moderatore
Moderatore

Messaggi : 1856
Punti : 7051
Voti per importanza dei messaggi : 91
Data d'iscrizione : 20.02.11
Età : 60
Località : Monte Argentario (GR)

https://www.facebook.com/groups/utentimillewin/

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  Admin Lun 5 Mag 2014 - 19:17

Caro Renato,
ti allego le estrazioni che più o meno rispondono ai requisiti che avevi chiesto. Si tratta di due estrazioni perché millewin oltre un certo numero di subquery non fa andare per cui la seconda completa la precedente.
Di meglio non sono riuscito a fare perché abbastanza complicato, più di quanto si potrebbe pensare perché i dati da considerare sono parecchi.
La maggiore difficoltà riguarda l'uso dell'ASA da più o meno di 10 anni. Ho scelto di considerare le date delle prescrizioni se iniziate nel corso degli ultimi 10 anni o prima. Non è l'ideale ma la cosa più semplice e comunque indicativa del risultato voluto.
Altra cosa che ti dico è che per ogni gruppo di età ho inserito il numero totale dei pazienti rientranti nel gruppo escludendo morti e revocati, invece, a seguire, per ogni fascia di età ho inserito una colonna per coloro che non hanno fatto uso di ASA, poi una con l'uso iniziato nel corso dell'ultimo anno ed infine una in cui l'uso è iniziato oltre 10 anni or sono; per tutte queste fasce sono inclusi morti e revocati perché altrimenti non avrebbe avuto senso escludere chi magari è morto per una neoplasia. In queste subquery i comandi in realtà ci sono, ma sono inattivati dal segno /* all'inizio e */ alla fine. Nel caso puoi variarli come preferisci.
Infine in ogni subquery ho inserito la vista V_Pazienti per cercare di considerare solo i pazienti del medico titolare in caso di medicine di gruppo, ma per questo devi fare delle prove perché se non funziona è un grosso problema in quanto in ogni subquery si dovrebbe inserire il codice di ciascun medico e la cosa sarebbe estremamente complicata se non proibitiva.
Comunque lo studio mi sembra molto interessante per cui inviterei altri colleghi più esperti di me a dare un loro contributo.
Al riguardo ti dico che valutando la query sul mio database, sono rimasto sorpreso da un risultato strabiliante ed inequivocabile, ben oltre ogni aspettativa. Ti dico solo che su un totale di 1029 pazienti attivi, tra quelli che hanno avuto una qualunque neoplasia, 75 non hanno mai fatto uso di ASA, 25 hanno iniziato da meno di 10 anni e solo 8 sono tra quelli che hanno iniziato la terapia da oltre 10 anni.
Prima selezione:

Select 'Nome Medico' ______Medico______,
(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S'
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL) Tot_30_39,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_colon_No_ASA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_colon_ASA_M10AA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_colon_ASA_P10AA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_polmone_No_ASA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_polmone_ASA_M10AA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_polmone_ASA_P10AA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_mammella_No_ASA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_mammella_ASA_M10AA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_mammella_ASA_P10AA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_tutti_No_ASA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_tutti_ASA_M10AA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 30 and 39
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_tutti_ASA_P10AA3039,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S'
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL) Tot_40_49,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_colon_No_ASA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_colon_ASA_M10AA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_colon_ASA_P10AA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_polmone_No_ASA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_polmone_ASA_M10AA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_polmone_ASA_P10AA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_mammella_No_ASA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_mammella_ASA_M10AA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_mammella_ASA_P10AA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_tutti_No_ASA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_tutti_ASA_M10AA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 40 and 49
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_tutti_ASA_P10AA4049,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S'
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL) Tot_50_59,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_colon_No_ASA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_colon_ASA_M10AA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_colon_ASA_P10AA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_polmone_No_ASA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_polmone_ASA_M10AA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_polmone_ASA_P10AA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_mammella_No_ASA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_mammella_ASA_M10AA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_mammella_ASA_P10AA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_tutti_No_ASA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_tutti_ASA_M10AA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 50 and 59
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_tutti_ASA_P10AA5059,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S'
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL) Tot_60_69,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_colon_No_ASA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_colon_ASA_M10AA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_colon_ASA_P10AA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_polmone_No_ASA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_polmone_ASA_M10AA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_polmone_ASA_P10AA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_mammella_No_ASA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_mammella_ASA_M10AA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_mammella_ASA_P10AA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_tutti_No_ASA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_tutti_ASA_M10AA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 60 and 69
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_tutti_ASA_P10AA6069,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S'
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL) Tot_70_110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_colon_No_ASA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_colon_ASA_M10AA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'153%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_colon_ASA_P10AA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_polmone_No_ASA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_polmone_ASA_M10AA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'162%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_polmone_ASA_P10AA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_mammella_No_ASA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_mammella_ASA_M10AA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code like'174%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_mammella_ASA_P10AA70110


Seconda selezione:

Select 'Nome Medico' ______Medico______,
(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110 And convenzion='S'
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL) Tot_70_110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110 And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_tutti_No_ASA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_tutti_ASA_M10AA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 70 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_tutti_ASA_P10AA70110,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 0 and 110 And convenzion='S'
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL) Tot_Pazienti,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 0 and 110 And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice NOT IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' )) k_tutti_No_ASATotPaz,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 0 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open > Today()-3650 )) k_tutti_ASA_M10AATotPaz,

(Select distinct count (*) from V_pazienti p, nos_002 n where p.codice=n.codice  AND years(p.datanasc, Today()) between 0 and 110
And convenzion='S' /*
AND (n.pa_drevoca IS NULL or n.pa_drevoca >TODAY()) AND p.datadecess IS NULL */
and  p.codice IN (select distinct p.codice from cart_pazpbl b, V_pazienti p  where b.codice=p.codice and (cp_code between '140%'  AND '239%' ))
and  p.codice IN (select distinct p.codice from cart_terap t, V_pazienti p  where t.codice=p.codice and co_ATC like 'B01AC06' AND t.data_open < Today()-3650 )) k_tutti_ASA_P10AATotPaz
Admin
Admin
Admin
Admin

Messaggi : 537
Punti : 5495
Voti per importanza dei messaggi : 89
Data d'iscrizione : 20.02.11
Località : CASERTA

https://utentimillewin.forumattivo.it

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  drtulino Lun 5 Mag 2014 - 22:08

Grazie Giuseppe, la query, obiettivamente molto complessa, non dà errore nell'estrazione, ma soprattutto nella colonna "k_tutti_asa_m10aa" penso ci sia qualche impostazione che non torna. Perlomeno ho questa impressione per i numeri estratti.
A prima battuta anche a me sembra che ci siano cose molte interessanti estratte.
drtulino
drtulino
Moderatore
Moderatore

Messaggi : 1856
Punti : 7051
Voti per importanza dei messaggi : 91
Data d'iscrizione : 20.02.11
Età : 60
Località : Monte Argentario (GR)

https://www.facebook.com/groups/utentimillewin/

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  amico di Giuseppe Gio 8 Mag 2014 - 2:15

drtulino ha scritto:Grazie Giuseppe, la query, obiettivamente molto complessa, non dà errore nell'estrazione, ma soprattutto nella colonna "k_tutti_asa_m10aa" penso ci sia qualche impostazione che non torna. Perlomeno ho questa impressione per i numeri estratti.
A prima battuta anche a me sembra che ci siano cose molte interessanti estratte.

Caro Peppe,
grazie per l'immane lavoro che hai sostenuto per costruire questa query, ma penso che non possa essere utilizzata da molti in quanto l'ASA i pz la comprano direttamente per il basso costo e quindi la statistica è falsata poichè a molti paz. per lo meno io, non registro nelle terapie quello che acquistano direttamente.
Scusa per la precisazione e penso che questa sia la causa di quanto accade al collega Tulino.
Antonio Menna

amico di Giuseppe
Membro Junior
Membro Junior

Messaggi : 103
Punti : 4947
Voti per importanza dei messaggi : 3
Data d'iscrizione : 22.02.11
Età : 66
Località : SANTA MARIA CAPUA VETERE

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  Admin Gio 8 Mag 2014 - 10:33

amico di Giuseppe ha scritto:
drtulino ha scritto:Grazie Giuseppe, la query, obiettivamente molto complessa, non dà errore nell'estrazione, ma soprattutto nella colonna "k_tutti_asa_m10aa" penso ci sia qualche impostazione che non torna. Perlomeno ho questa impressione per i numeri estratti.
A prima battuta anche a me sembra che ci siano cose molte interessanti estratte.

Caro Peppe,
grazie per l'immane lavoro che hai sostenuto per costruire questa query, ma penso che non possa essere utilizzata da molti in quanto l'ASA i pz la comprano direttamente per il basso costo e quindi la statistica è falsata poichè a molti paz. per lo meno io, non registro nelle terapie quello che acquistano direttamente.
Scusa per la precisazione e penso che questa sia la causa di quanto accade al collega Tulino.
Antonio Menna

Caro Tonino,
ho considerato anche questo fatto, infatti la query tiene conto dell'inizio della terapia con ASA e non delle ultime prescrizioni. Naturalmente in ogni caso ci sono dei limiti, ma credo che sia comunque molto indicativo il risultato ottenuto. Ti invito a provarla e fare dei commenti post.
Naturalmente invito i colleghi più esperti di me a fare dei miglioramenti perché trovo lo studio molto interessante per i risultati che non ci saremmo mai aspettati. Immaginate se tutti i colleghi registrati a questo forum (oltre 1000), partecipassero allo studio quanto importante sarebbero i risultati.
Admin
Admin
Admin
Admin

Messaggi : 537
Punti : 5495
Voti per importanza dei messaggi : 89
Data d'iscrizione : 20.02.11
Località : CASERTA

https://utentimillewin.forumattivo.it

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  drtulino Gio 8 Mag 2014 - 11:04

Admin ha scritto:
amico di Giuseppe ha scritto:
drtulino ha scritto:Grazie Giuseppe, la query, obiettivamente molto complessa, non dà errore nell'estrazione, ma soprattutto nella colonna "k_tutti_asa_m10aa" penso ci sia qualche impostazione che non torna. Perlomeno ho questa impressione per i numeri estratti.
A prima battuta anche a me sembra che ci siano cose molte interessanti estratte.

Caro Peppe,
grazie per l'immane lavoro che hai sostenuto per costruire questa query, ma penso che non possa essere utilizzata da molti in quanto l'ASA i pz la comprano direttamente per il basso costo e quindi la statistica è falsata poichè a molti paz. per lo meno io, non registro nelle terapie quello che acquistano direttamente.
Scusa per la precisazione e penso che questa sia la causa di quanto accade al collega Tulino.
Antonio Menna

Caro Tonino,
ho considerato anche questo fatto, infatti la query tiene conto dell'inizio della terapia con ASA e non delle ultime prescrizioni. Naturalmente in ogni caso ci sono dei limiti, ma credo che sia comunque molto indicativo il risultato ottenuto. Ti invito a provarla e fare dei commenti post.
Naturalmente invito i colleghi più esperti di me a fare dei miglioramenti perché trovo lo studio molto interessante per i risultati che non ci saremmo mai aspettati. Immaginate se tutti i colleghi registrati a questo forum (oltre 1000), partecipassero allo studio quanto importante sarebbero i risultati.
Condivido in toto quanto detto da Giuseppe. Abbiamo, comunque, bisogno di altri Colleghi esperti per perfezionare la query, anche dal punto di vista "concettuale".
drtulino
drtulino
Moderatore
Moderatore

Messaggi : 1856
Punti : 7051
Voti per importanza dei messaggi : 91
Data d'iscrizione : 20.02.11
Età : 60
Località : Monte Argentario (GR)

https://www.facebook.com/groups/utentimillewin/

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  Lucio Mignone Gio 8 Mag 2014 - 12:12

drtulino ha scritto:
Admin ha scritto:
amico di Giuseppe ha scritto:
drtulino ha scritto:Grazie Giuseppe, la query, obiettivamente molto complessa, non dà errore nell'estrazione, ma soprattutto nella colonna "k_tutti_asa_m10aa" penso ci sia qualche impostazione che non torna. Perlomeno ho questa impressione per i numeri estratti.
A prima battuta anche a me sembra che ci siano cose molte interessanti estratte.

Caro Peppe,
grazie per l'immane lavoro che hai sostenuto per costruire questa query, ma penso che non possa essere utilizzata da molti in quanto l'ASA i pz la comprano direttamente per il basso costo e quindi la statistica è falsata poichè a molti paz. per lo meno io, non registro nelle terapie quello che acquistano direttamente.
Scusa per la precisazione e penso che questa sia la causa di quanto accade al collega Tulino.
Antonio Menna

Caro Tonino,
ho considerato anche questo fatto, infatti la query tiene conto dell'inizio della terapia con ASA e non delle ultime prescrizioni. Naturalmente in ogni caso ci sono dei limiti, ma credo che sia comunque molto indicativo il risultato ottenuto. Ti invito a provarla e fare dei commenti post.
Naturalmente invito i colleghi più esperti di me a fare dei miglioramenti perché trovo lo studio molto interessante per i risultati che non ci saremmo mai aspettati. Immaginate se tutti i colleghi registrati a questo forum (oltre 1000), partecipassero allo studio quanto importante sarebbero i risultati.
Condivido in toto quanto detto da Giuseppe. Abbiamo, comunque, bisogno di altri Colleghi esperti per perfezionare la query, anche dal punto di vista "concettuale".
E' molto interessante, io ci sto a collaborare se si fa qualcosa per quanto riguarda la mia zona.
Lucio Mignone
Lucio Mignone
Membro Senior
Membro Senior

Messaggi : 632
Punti : 5630
Voti per importanza dei messaggi : 37
Data d'iscrizione : 20.02.11
Età : 60
Località : CAVRIGLIA (AR)

http://comeva.altervista.org/

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  amico di Giuseppe Gio 8 Mag 2014 - 13:15

Admin ha scritto:
amico di Giuseppe ha scritto:
drtulino ha scritto:Grazie Giuseppe, la query, obiettivamente molto complessa, non dà errore nell'estrazione, ma soprattutto nella colonna "k_tutti_asa_m10aa" penso ci sia qualche impostazione che non torna. Perlomeno ho questa impressione per i numeri estratti.
A prima battuta anche a me sembra che ci siano cose molte interessanti estratte.

Caro Peppe,
grazie per l'immane lavoro che hai sostenuto per costruire questa query, ma penso che non possa essere utilizzata da molti in quanto l'ASA i pz la comprano direttamente per il basso costo e quindi la statistica è falsata poichè a molti paz. per lo meno io, non registro nelle terapie quello che acquistano direttamente.
Scusa per la precisazione e penso che questa sia la causa di quanto accade al collega Tulino.
Antonio Menna

Caro Tonino,
ho considerato anche questo fatto, infatti la query tiene conto dell'inizio della terapia con ASA e non delle ultime prescrizioni. Naturalmente in ogni caso ci sono dei limiti, ma credo che sia comunque molto indicativo il risultato ottenuto. Ti invito a provarla e fare dei commenti post.
Naturalmente invito i colleghi più esperti di me a fare dei miglioramenti perché trovo lo studio molto interessante per i risultati che non ci saremmo mai aspettati. Immaginate se tutti i colleghi registrati a questo forum (oltre 1000), partecipassero allo studio quanto importante sarebbero i risultati.

Caro Peppe,
scusami se l'hai interpretata come una critica nei tuoi confronti ma invece era un encomio per il lavoro che hai svolto e per il tempo che ci (a noi) hai dedicato!!!
Con stima ed affetto Tonino Menna

amico di Giuseppe
Membro Junior
Membro Junior

Messaggi : 103
Punti : 4947
Voti per importanza dei messaggi : 3
Data d'iscrizione : 22.02.11
Età : 66
Località : SANTA MARIA CAPUA VETERE

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  Admin Gio 8 Mag 2014 - 13:32

amico di Giuseppe ha scritto:
Admin ha scritto:
amico di Giuseppe ha scritto:
drtulino ha scritto:Grazie Giuseppe, la query, obiettivamente molto complessa, non dà errore nell'estrazione, ma soprattutto nella colonna "k_tutti_asa_m10aa" penso ci sia qualche impostazione che non torna. Perlomeno ho questa impressione per i numeri estratti.
A prima battuta anche a me sembra che ci siano cose molte interessanti estratte.

Caro Peppe,
grazie per l'immane lavoro che hai sostenuto per costruire questa query, ma penso che non possa essere utilizzata da molti in quanto l'ASA i pz la comprano direttamente per il basso costo e quindi la statistica è falsata poichè a molti paz. per lo meno io, non registro nelle terapie quello che acquistano direttamente.
Scusa per la precisazione e penso che questa sia la causa di quanto accade al collega Tulino.
Antonio Menna

Caro Tonino,
ho considerato anche questo fatto, infatti la query tiene conto dell'inizio della terapia con ASA e non delle ultime prescrizioni. Naturalmente in ogni caso ci sono dei limiti, ma credo che sia comunque molto indicativo il risultato ottenuto. Ti invito a provarla e fare dei commenti post.
Naturalmente invito i colleghi più esperti di me a fare dei miglioramenti perché trovo lo studio molto interessante per i risultati che non ci saremmo mai aspettati. Immaginate se tutti i colleghi registrati a questo forum (oltre 1000), partecipassero allo studio quanto importante sarebbero i risultati.

Caro Peppe,
scusami se l'hai interpretata come una critica nei tuoi confronti ma invece era un encomio per il lavoro che hai svolto e per il tempo che ci (a noi) hai dedicato!!!
Con stima ed affetto Tonino Menna

Amico mio, non l'ho interpretata come critica, il mio era semplicemente un invito a collaborare  Very Happy  Very Happy
Admin
Admin
Admin
Admin

Messaggi : 537
Punti : 5495
Voti per importanza dei messaggi : 89
Data d'iscrizione : 20.02.11
Località : CASERTA

https://utentimillewin.forumattivo.it

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  drtulino Gio 8 Mag 2014 - 17:25

Lucio Mignone ha scritto:
drtulino ha scritto:
Admin ha scritto:
amico di Giuseppe ha scritto:
drtulino ha scritto:Grazie Giuseppe, la query, obiettivamente molto complessa, non dà errore nell'estrazione, ma soprattutto nella colonna "k_tutti_asa_m10aa" penso ci sia qualche impostazione che non torna. Perlomeno ho questa impressione per i numeri estratti.
A prima battuta anche a me sembra che ci siano cose molte interessanti estratte.

Caro Peppe,
grazie per l'immane lavoro che hai sostenuto per costruire questa query, ma penso che non possa essere utilizzata da molti in quanto l'ASA i pz la comprano direttamente per il basso costo e quindi la statistica è falsata poichè a molti paz. per lo meno io, non registro nelle terapie quello che acquistano direttamente.
Scusa per la precisazione e penso che questa sia la causa di quanto accade al collega Tulino.
Antonio Menna

Caro Tonino,
ho considerato anche questo fatto, infatti la query tiene conto dell'inizio della terapia con ASA e non delle ultime prescrizioni. Naturalmente in ogni caso ci sono dei limiti, ma credo che sia comunque molto indicativo il risultato ottenuto. Ti invito a provarla e fare dei commenti post.
Naturalmente invito i colleghi più esperti di me a fare dei miglioramenti perché trovo lo studio molto interessante per i risultati che non ci saremmo mai aspettati. Immaginate se tutti i colleghi registrati a questo forum (oltre 1000), partecipassero allo studio quanto importante sarebbero i risultati.
Condivido in toto quanto detto da Giuseppe. Abbiamo, comunque, bisogno di altri Colleghi esperti per perfezionare la query, anche dal punto di vista "concettuale".
E' molto interessante, io ci sto a collaborare se si fa qualcosa per quanto riguarda la mia zona.
Caro Lucio,
   il fatto di fare qualche cosa per la Tua zona, dipende da Te. Da qualche tempo, ormai, sto cercando con alcuni Colleghi della mia ASL, con l'appoggio della SIMG Provinciale e coinvolgendo giovani Colleghi a fare degli Audit sui dati estrapolati su alcuni di Noi MMG. La fatica è tanta, ovviamente (anche perché molti Colleghi non sanno applicare le query e quindi i giovani Colleghi devono andare studio per studio per farlo materialmente), ma c'è molta curiosità e si trovano anche degli sponsor per poter fare incontri interessanti e, soprattutto, nuovi dal punto di vista della formazione.
drtulino
drtulino
Moderatore
Moderatore

Messaggi : 1856
Punti : 7051
Voti per importanza dei messaggi : 91
Data d'iscrizione : 20.02.11
Età : 60
Località : Monte Argentario (GR)

https://www.facebook.com/groups/utentimillewin/

Torna in alto Andare in basso

ASA Vs Neoplasie Empty ASA Vs neoplasie

Messaggio  nanci giacinto Gio 8 Mag 2014 - 22:33

salve l'applicazione della query a me da questo risultato: "errore Sql: Empty string is not a valid select". Cosa significa?.
nanci giacinto
nanci giacinto
Membro Junior
Membro Junior

Messaggi : 128
Punti : 5012
Voti per importanza dei messaggi : -1
Data d'iscrizione : 02.03.11

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  Admin Ven 9 Mag 2014 - 20:50

nanci giacinto ha scritto:salve l'applicazione della query a me da questo risultato: "errore Sql: Empty string is not a valid select". Cosa significa?.

Significa che l'estrazione è troppo lunga per cui non è supportata. E' necessario tagliarne una parte, cioè eliminare dei "Select ..." finali e facendo in modo che non finisca con una virgola.
E' questo il motivo che ho dovuto fare 2 estrazioni invece di una. La query va comunque perfezionata.
Admin
Admin
Admin
Admin

Messaggi : 537
Punti : 5495
Voti per importanza dei messaggi : 89
Data d'iscrizione : 20.02.11
Località : CASERTA

https://utentimillewin.forumattivo.it

Torna in alto Andare in basso

ASA Vs Neoplasie Empty asa e neoplasie

Messaggio  nanci giacinto Sab 17 Mag 2014 - 9:11

BUONGIORNO Con la doppia query funziona anche a me, però i dati estratti non sono facilmente interpretabili. ciao
nanci giacinto
nanci giacinto
Membro Junior
Membro Junior

Messaggi : 128
Punti : 5012
Voti per importanza dei messaggi : -1
Data d'iscrizione : 02.03.11

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  Admin Sab 17 Mag 2014 - 11:46

nanci giacinto ha scritto:BUONGIORNO Con la doppia query funziona anche a me, però i dati estratti non sono facilmente interpretabili. ciao

Per ogni fascia di età sono indicati in sequenza, il numero totale dei pazienti, quanti sono affetti da una certa neoplasia e non hanno mai fatto uso di ASA, quanti hanno iniziato un trattamento con ASA da meno di 10 anni e quanti da più di dieci anni. Dovendo usare delle sigle per ciascuna colonna, non è semplice trovarle.

Ad esempio per la fascia 30-39 anni con K colon:
Tot_30_39 (Numero totale di pazienti tra 30 e 39 anni)
k_colon_No_ASA3039 (età tra 30 e 39 aa con K colon e non uso di ASA)
k_colon_ASA_M10AA3039 (età tra 30 e 39 aa con K colon e uso di ASA da meno 10 anni)
k_colon_ASA_P10AA3039(età tra 30 e 39 aa con K colon e uso di ASA da più di 10 anni)

E così a seguire per il K polmonare, il K mammella ed infine per tutte le neoplasie.
Lo stesso si ripete per le altre fasce di età considerate.

Naturalmente il discorso diventa complicato per il gran numero di condizioni da considerare, non solo da un punto di vista "tecnico" (come impostare la query in modo da rispondere con precisione ai requisiti richiesti), ma anche da un punto di vista concettuale (come suddividere le fasce d'età, quali neoplasie considerare, come comportarsi con i revocati o i deceduti, ecc.). Per tutti questi motivi sarebbero interessanti i commenti di chi vuole partecipare a questo studio dicendo se i risultati sono credibili ed interessanti, come migliorarli con scelte più utili ed infine, per gli esperti, come usare il linguaggio Sql in modo da avere risultati univoci e corretti.
Admin
Admin
Admin
Admin

Messaggi : 537
Punti : 5495
Voti per importanza dei messaggi : 89
Data d'iscrizione : 20.02.11
Località : CASERTA

https://utentimillewin.forumattivo.it

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  drtulino Sab 17 Mag 2014 - 13:43

Condivido quanto detto da Giuseppe. Io e Lui abbiamo provato, ma abbiamo bisogno di nuove interpretazioni concettuali su come impostare anche la questione ASA meno e più di 10 anni, come calcolare questi pazienti (è corretto che quelli che fanno ASA da meno di dieci anni siano sommati, dalla query a quelli con più di 10 anni? e se no come fare a selezionarli con il linguaggio sql? Per i codici da inserire nell'estrazione per es. nel codice ICD9:239 ha anche al suo interno le neoformazioni che a mio parere non è corretto calcolare in toto tra le neoplasie.
drtulino
drtulino
Moderatore
Moderatore

Messaggi : 1856
Punti : 7051
Voti per importanza dei messaggi : 91
Data d'iscrizione : 20.02.11
Età : 60
Località : Monte Argentario (GR)

https://www.facebook.com/groups/utentimillewin/

Torna in alto Andare in basso

ASA Vs Neoplasie Empty Re: ASA Vs Neoplasie

Messaggio  Contenuto sponsorizzato


Contenuto sponsorizzato


Torna in alto Andare in basso

Torna in alto


 
Permessi in questa sezione del forum:
Non puoi rispondere agli argomenti in questo forum.