[TYPO3-english] Create SQL Views

Guillermo R. Oramas J. oramas.g at gmail.com
Sun Jul 3 20:32:32 CEST 2011


Thanks Stephan.

I will try with your solution. That's enough for me.

Nice trick!


-----Mensaje original-----
De: typo3-english-bounces at lists.typo3.org
[mailto:typo3-english-bounces at lists.typo3.org] En nombre de Stephan Schuler
Enviado el: Domingo, 03 de Julio de 2011 10:04
Para: TYPO3 English
Asunto: Re: [TYPO3-english] Create SQL Views

Hey Guillermo.


I know a sollution that's kind of half automated. But unfortunately, I
didn't manage to find some official documentation about it. So if anybody
knows where this feature is documented, please reply.

You can put something like the following lines into your
ext_conf_template.txt:
# cat=basic;
type=user[EXT:yourExtKey/hooks/class.yourExtKey_postInstallHook.php:yourExtK
ey_postInstallHook->updateView]; label=Update the view
 * updateView=0

This will make the extension manager call your hook after having installed
or updated the extension. Inside your hook, you can call the
t3lib_DB::sql_query yourself to create or update the view.


Kind regards,

Stephan Schuler
Web-Entwickler

Telefon: +49 (911) 539909 - 0
E-Mail: Stephan.Schuler at netlogix.de
Website: media.netlogix.de


--
netlogix GmbH & Co. KG
IT-Services | IT-Training | Media
Andernacher Stra?e 53 | 90411 N?rnberg
Telefon: +49 (911) 539909 - 0 | Fax: +49 (911) 539909 - 99
E-Mail: info at netlogix.de | Internet: http://www.netlogix.de

netlogix GmbH & Co. KG ist eingetragen am Amtsgericht N?rnberg (HRA 13338)
Pers?nlich haftende Gesellschafterin: netlogix Verwaltungs GmbH (HRB 20634)
Umsatzsteuer-Identifikationsnummer: DE 233472254
Gesch?ftsf?hrer: Stefan Buchta, Matthias Schmidt



________________________________________
Von: typo3-english-bounces at lists.typo3.org
[typo3-english-bounces at lists.typo3.org]" im Auftrag von "Dmitry
Dulepov [dmitry.dulepov at gmail.com]
Gesendet: Sonntag, 3. Juli 2011 16:20
Bis: typo3-english at lists.typo3.org
Betreff: Re: [TYPO3-english] Create SQL Views

Hi!

Guillermo R. Oramas J. wrote:
> I need to create a MySQL View, I tried to insert the SQL code in 
> ext_tables.sql like when I do with Tables but when I install the 
> extension that part of the file is not executed.
>
> Is it posible to automate the creation of the view or I need to do it 
> manually?

Manually. TYPO3 SQL parser does not support that.

--
Dmitry "itoldyou" Dulepov
TYPO3 core&security team member
E-mail: dmitry.dulepov at typo3.org
Web: http://dmitry-dulepov.com/

_______________________________________________
TYPO3-english mailing list
TYPO3-english at lists.typo3.org
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-english
_______________________________________________
TYPO3-english mailing list
TYPO3-english at lists.typo3.org
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-english



More information about the TYPO3-english mailing list