Dsy Network www | forum | my | didattica | howto | wiki | el goog | stats | blog | dona | rappresentanti
Homepage
 Register   Calendar   Members  Faq   Search  Logout 
.dsy:it. : Powered by vBulletin version 2.3.1 .dsy:it. > Didattica > Corsi A - F > Basi di dati ~ informatica triennale > [Progetto] "Blog" Thread Rating: 1 votes, 4.00 average.
Pages (33): « First ... « 8 9 10 11 [12] 13 14 15 16 » ... Last »   Last Thread   Next Thread
Author
Thread    Expand all | Contract all    Post New Thread    Post A Reply
Collapse
Gehur
.grande:maestro.

User info:
Registered: Apr 2006
Posts: 519 (0.07 al dì)
Location: Milano
Corso: Informatica
Anno:
Time Online: 3 Days, 0:41:42 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

cavoli è vero adesso provo

ora funziona correttamente ;)

Last edited by Gehur on 18-03-2007 at 12:14

18-03-2007 11:36
Click Here to See the Profile for Gehur Click here to Send Gehur a Private Message Find more posts by Gehur Add Gehur to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
Gehur
.grande:maestro.

User info:
Registered: Apr 2006
Posts: 519 (0.07 al dì)
Location: Milano
Corso: Informatica
Anno:
Time Online: 3 Days, 0:41:42 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

ma come funzionano le checkbox??

per la cancellazione degli argomenti volevo visualizzatre tutti gli argopmenti presenti e poterli selezionare con la checkbox ma ho problemi, non ci riesco

come faccio ad assegnare il valore dell'id delll'argomento da cancellare alla check??


questo progetto mi sta seccando parecchio:swear:

Last edited by Gehur on 19-03-2007 at 10:44

19-03-2007 10:37
Click Here to See the Profile for Gehur Click here to Send Gehur a Private Message Find more posts by Gehur Add Gehur to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
zonker
.illuminato.

User info:
Registered: Mar 2003
Posts: 200 (0.02 al dì)
Location:
Corso:
Anno:
Time Online: 2 Days, 6:24:53 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

Le checkbox funzionano cha hanno un nome (eventualmente un array) e un valore.
Se sono spuntate all'action form viene ritornata la coppia nome/valore, se non sono spuntate non viene mandato nulla.

19-03-2007 10:47
Click Here to See the Profile for zonker Click here to Send zonker a Private Message Find more posts by zonker Add zonker to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
khelidan
.grande:maestro.

User info:
Registered: Jun 2003
Posts: 1196 (0.14 al dì)
Location: Milano
Corso: Informatica
Anno: Finito....
Time Online: 13 Days, 12:08:03: [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

Ragazzi chi mi aiuta a fare il trigger per gli update?

Ho messo giu sta roba:

code:
CREATE TRIGGER up AFTER UPDATE ON contenuti FOR EACH ROW IF NEW.accessi=OLD.accessi THEN SET modifiche=modifiche+1;END IF


a parte che mi da un errore di sintassi ma è la via giusta per procedere?

In questo caso mi sommerebbe 1 a tutte le righe o solo a quella aggiornata?

__________________
Khelidan

19-03-2007 12:52
Click Here to See the Profile for khelidan Click here to Send khelidan a Private Message Find more posts by khelidan Add khelidan to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
zonker
.illuminato.

User info:
Registered: Mar 2003
Posts: 200 (0.02 al dì)
Location:
Corso:
Anno:
Time Online: 2 Days, 6:24:53 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

a parte la sintassi completamente "strampalata" il concetto è giusto, a meno del fatto che devi fare new.modifiche = new.modifiche + 1
In realtà dovresti crearti una funzione che restituisce un trigger e poi associare la funzione al trigger.
Ad esempio:
CREATE or replace FUNCTION updatechanges() RETURNS trigger AS $updatechanges$
BEGIN
....
END;
$updatechanges$ LANGUAGE plpgsql;

e poi
CREATE TRIGGER updatechange
BEFORE UPDATE ON CONTENUTI
FOR EACH ROW EXECUTE PROCEDURE updatechanges();

19-03-2007 13:32
Click Here to See the Profile for zonker Click here to Send zonker a Private Message Find more posts by zonker Add zonker to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
khelidan
.grande:maestro.

User info:
Registered: Jun 2003
Posts: 1196 (0.14 al dì)
Location: Milano
Corso: Informatica
Anno: Finito....
Time Online: 13 Days, 12:08:03: [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

ok ora mi torna devo fare la funzione e poi richiamarla dal trigger,ma poi come faccio ad inserire il controllo su accessi,ho fatto pure io una funzione che fa un update su una colonna della tabella ogni volta che faccio la select,quindi devo toglierla dal trigger,se no ogni visualizzazione viene considerata una modifica,va bene così:

CREATE TRIGGER updatechange
BEFORE UPDATE ON CONTENUTI
FOR EACH ROW IF OLD.accessi=NEW.accessi EXECUTE PROCEDURE updatechanges();

__________________
Khelidan

19-03-2007 13:42
Click Here to See the Profile for khelidan Click here to Send khelidan a Private Message Find more posts by khelidan Add khelidan to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
zonker
.illuminato.

User info:
Registered: Mar 2003
Posts: 200 (0.02 al dì)
Location:
Corso:
Anno:
Time Online: 2 Days, 6:24:53 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

La if devi metterla nella funzione, non nel trigger.
In pratica la funzione viene scatenata ogni volta che c'è un update ma se old.accessi = new.accessi non fa assolutamente nulla.

19-03-2007 13:48
Click Here to See the Profile for zonker Click here to Send zonker a Private Message Find more posts by zonker Add zonker to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
bledar
.arcimaestro.

User info:
Registered: Oct 2003
Posts: 256 (0.03 al dì)
Location:
Corso:
Anno:
Time Online: 6 Days, 3:07:56 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

ciao ragazzi
volevo chiedere , ma per ogni associazione del tipo articolo-foto , articolo-sezione , contnuto - argomento etc avete fato une tabella a parte nel db? poi volevo chiedere se avete usato una tabella per tutti i contenuti o una tabella per ogni tipo di contenuto? grazie

19-03-2007 14:40
Click Here to See the Profile for bledar Click here to Send bledar a Private Message Find more posts by bledar Add bledar to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
zonker
.illuminato.

User info:
Registered: Mar 2003
Posts: 200 (0.02 al dì)
Location:
Corso:
Anno:
Time Online: 2 Days, 6:24:53 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

Ovviamente ogni soluzione è possibile, io ho fatto una sola tabella per tutti i contenuti e una tabella per ogni tipo di "link" articolo-foto, news-news, etc.

19-03-2007 14:49
Click Here to See the Profile for zonker Click here to Send zonker a Private Message Find more posts by zonker Add zonker to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
bledar
.arcimaestro.

User info:
Registered: Oct 2003
Posts: 256 (0.03 al dì)
Location:
Corso:
Anno:
Time Online: 6 Days, 3:07:56 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

cosi avevo pensato anche io di fare :)

19-03-2007 15:02
Click Here to See the Profile for bledar Click here to Send bledar a Private Message Find more posts by bledar Add bledar to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
bledar
.arcimaestro.

User info:
Registered: Oct 2003
Posts: 256 (0.03 al dì)
Location:
Corso:
Anno:
Time Online: 6 Days, 3:07:56 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

per il fatto che si puo dare il premesso a un altro utente io ho fatto una tabella contenente USER1 USER2 CONTENID dove user 1 e colui che da il permesso , e da questa tabella posso vedere se un contenuto ha piu autori , come avete fatto voi?

19-03-2007 15:05
Click Here to See the Profile for bledar Click here to Send bledar a Private Message Find more posts by bledar Add bledar to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
zonker
.illuminato.

User info:
Registered: Mar 2003
Posts: 200 (0.02 al dì)
Location:
Corso:
Anno:
Time Online: 2 Days, 6:24:53 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

Io, come discusso molto prima in questo thread, ho disgiunto il discorso autori da quello permessi.
Ossia gli autori sono gli autori e in quanto tali hanno i permessi, poi ci sono gli utenti non autori che hanno i permessi in quanto autorizzati da utenti con permesso.
Non ho poi (visto che non è richiesto perchè complicarsi la vita?) tenuto traccia di quale utente abbia assegnato i permessi.

19-03-2007 15:07
Click Here to See the Profile for zonker Click here to Send zonker a Private Message Find more posts by zonker Add zonker to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
bledar
.arcimaestro.

User info:
Registered: Oct 2003
Posts: 256 (0.03 al dì)
Location:
Corso:
Anno:
Time Online: 6 Days, 3:07:56 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

hmm , ma come fai allora , quando vai a inserire il contenuto inserisci + di un autore??Io ho pensato che visto che un utente modifica il contenuto , diventa cooautore del contenuto .

19-03-2007 15:09
Click Here to See the Profile for bledar Click here to Send bledar a Private Message Find more posts by bledar Add bledar to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
bledar
.arcimaestro.

User info:
Registered: Oct 2003
Posts: 256 (0.03 al dì)
Location:
Corso:
Anno:
Time Online: 6 Days, 3:07:56 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

un altra cosa , come rapresenti nel db if fatto che un contenuto ha piu di un autore?

19-03-2007 15:14
Click Here to See the Profile for bledar Click here to Send bledar a Private Message Find more posts by bledar Add bledar to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
Collapse
zonker
.illuminato.

User info:
Registered: Mar 2003
Posts: 200 (0.02 al dì)
Location:
Corso:
Anno:
Time Online: 2 Days, 6:24:53 [...]
Status: Offline

Post actions:

Edit | Report | IP: Logged

Nella mia applicazione all'atto dell'inserimento di un contenuto è possibile scegliere i co-autori. Dopo l'inserimento gli utenti con permessi di modifica possono aggiungere o togliere autori dal contenuto, ovviamente non si può eliminare l'autore quando questo sia l'unico autore rimasto.
Come puoi leggere dai vecchi messaggi anche altri qui hanno dato lo stesso significato a co-autore e utente con permessi di modifica. Per me sono cose diverse e per cui le gestisco separatamente.

19-03-2007 15:16
Click Here to See the Profile for zonker Click here to Send zonker a Private Message Find more posts by zonker Add zonker to your buddy list Printer Friendly version Email this Article to a friend Reply w/Quote
All times are GMT. The time now is 23:41.    Post New Thread    Post A Reply
Pages (33): « First ... « 8 9 10 11 [12] 13 14 15 16 » ... Last »   Last Thread   Next Thread
Show Printable Version | Email this Page | Subscribe to this Thread | Add to Bookmarks

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is ON
 

Powered by: vBulletin v2.3.1 - Copyright ©2000 - 2002, Jelsoft Enterprises Limited
Mantained by dsy crew (email) | Collabora con noi | Segnalaci un bug | Archive | Regolamento | Licenze | Thanks | Syndacate
Pagina generata in 0.130 seconds (60.10% PHP - 39.90% MySQL) con 24 query.