- Estás aquí:
- Inicio › Foro › Application Support › cBB Reactions
Cbb Reaction doubt
4 mensajes
• Página 1 de 1
- Leinad4Mind
- Mensajes: 213
- Registrado: Jue Oct 15, 2015 10:10 pm
Vie Abr 01, 2022 10:33 pm • a través de Web
Is it possible to migrate from BBreaction to cbb reaction?
EDIT: I would prefer if we could add multiple reactions as on Discord. But great work, looks amazing
EDIT: I would prefer if we could add multiple reactions as on Discord. But great work, looks amazing
- IvanPF
- Administrador
- Mensajes: 2010
- Registrado: Vie Jun 17, 2011 12:15 am
- Ubicación: España (Spain)
Sab Abr 02, 2022 9:15 am • a través de Web
Leinad4Mind escribió:Is it possible to migrate from BBreaction to cbb reaction?
I have to look at it, although I find it difficult. They are quite different extensions.
Leinad4Mind escribió:EDIT: I would prefer if we could add multiple reactions as on Discord. But great work, looks amazing
I will keep it in mind for future versions
- Leinad4Mind
- Mensajes: 213
- Registrado: Jue Oct 15, 2015 10:10 pm
Vie May 27, 2022 4:23 pm • a través de Web
I dont mind to get my hands dirty if needed to run some sql queries manually for the migration
- Leinad4Mind
- Mensajes: 213
- Registrado: Jue Oct 15, 2015 10:10 pm
Sab May 28, 2022 6:04 pm • a través de Web
For what I saw, and to help you out too:
BBReaction
cBBReaction
So...
reaction_id -> like_type
post_id -> post_id
user_id -> user_id
username -> Well need to grab from user table by the user_id
reaction_time -> like_time
like_id is the primary key and auto increment, so we can ignore it.
So maybe this would work (tested, it seems to work, but would be great if you could double check, since I may be forgetting something):
[s]I just dont know how I can map the like_type to the reaction_id. Let say I want to map like_type 1 to reaction_id 2? How can I create an sql with that kind of mapping?[/s]
EDIT: Ok, I'll first make the reactions table be exaclty as the bbreaction one, so then I'll not have any trouble about mapping. (Would be a pain in the ass to run sql queries to match each one lol)
BBReaction
cBBReaction
So...
reaction_id -> like_type
post_id -> post_id
user_id -> user_id
username -> Well need to grab from user table by the user_id
reaction_time -> like_time
like_id is the primary key and auto increment, so we can ignore it.
So maybe this would work (tested, it seems to work, but would be great if you could double check, since I may be forgetting something):
- Código: Seleccionar todo
INSERT INTO phpbb_reactions_data (reaction_id, post_id, user_id, username, reaction_time)
SELECT r.like_type, r.post_id, r.user_id, u.username, r.like_time
FROM phpbb_reward r, phpbb_users u, phpbb_posts p
WHERE r.user_id = u.user_id and r.post_id = p.post_id
[s]I just dont know how I can map the like_type to the reaction_id. Let say I want to map like_type 1 to reaction_id 2? How can I create an sql with that kind of mapping?[/s]
EDIT: Ok, I'll first make the reactions table be exaclty as the bbreaction one, so then I'll not have any trouble about mapping. (Would be a pain in the ass to run sql queries to match each one lol)
4 mensajes
• Página 1 de 1
¿Quién está conectado?
Usuarios navegando por este Foro: No hay usuarios registrados visitando el Foro y 0 invitados
- Contenido
- Descargas
- En desarrollo
- Comunidad y Soporte
- Rss
- Enlaces de Interés
- phpBB Oficial
- phpBB Oficial (Español)
- Raul Arroyo Monzo
- PasionReef
- Sobre CaniDev
- Condiciones de uso
- Política de Privacidad
- Sobre nosotros
- Contacto
- © 2011-2024 CaniDev