Back to top

Autore Topic: creare sottogruppi (ACL) con phpmyadmin  (Letto 1274 volte)

Offline hrd

  • Nuovo arrivato
  • *
  • Post: 42
  • Sesso: Maschio
    • Mostra profilo
creare sottogruppi (ACL) con phpmyadmin
« il: 03 Gen 2009, 02:37:46 »
ciao,
in rete ho trovato il seguente script che dovrebbe creare sottogruppi facendo una query:

Codice: [Seleziona]
SET @parent_name = 'Registered';
SET @new_name = 'nome sottogruppo';
 
-- Select the parent node to insert after
SELECT @ins_id := id, @ins_lft := lft, @ins_rgt := rgt
FROM jos_core_acl_aro_groups
WHERE name = @parent_name;
 
SELECT @new_id := MAX(id) + 1 FROM jos_core_acl_aro_groups;
 
-- Make room for the new node
UPDATE jos_core_acl_aro_groups SET rgt=rgt+2 WHERE rgt>=@ins_rgt;
UPDATE jos_core_acl_aro_groups SET lft=lft+2 WHERE lft>@ins_rgt;
 
-- Insert the new node
INSERT INTO jos_core_acl_aro_groups (id,parent_id,name,lft,rgt)
VALUES (@new_id,@ins_id,@new_name,@ins_rgt,@ins_rgt+1);
7

...dove "nome sottogruppo" va sostituito con il nome del sottogruppo che si intente creare.

purtroppo mi viene restituito il seguente errore:

Codice: [Seleziona]
-- Select the parent node to insert after
SELECT @ins_id := id, @ins_lft := lft, @ins_rgt := rgt
FROM jos_core_acl_aro_groups
WHERE name = @parent_name ;

Messaggio di MySQL: Documentazione
#1267 - Illegal mix of collations (utf8_general_ci,IMPLICIT) and (utf8_unicode_ci,IMPLICIT) for operation '='

...suggerimenti?

 



Web Design Bolzano Kreatif