1283 Posts
7 years ago

Hi folks

So I am experimenting with SQL pack plugin...

I have a art_alias field in a search form, I apply in the live column 'SQL Query'.

In the Live Value Column I enter my query:

SELECT alias FROM #__content WHERE id = 1

Great, it returns the correct value.


I check to see where this value is with in the variables by placing this code in a beforerender field:


I see that it is in 'value' and 'form'

Underneath I have a field

SELECT title FROM #__content WHERE state=1 AND alias = $cck->getValue('art_alias')

And I receive an error.

You have an error in your SQL syntax; 

check the manual that corresponds to your MySQL server version for the right syntax to use near 


at line 3 

SQL=SELECT title FROM #__content WHERE alias = $cck->getValue('art_alias')

This is just me experimenting but would appreciate any tips.

I have read this cool Klas Tut: sql-pack


Get a VIP membership
4229 Posts
7 years ago
Level 1

As stated in the manual $cck->get does not work in live plugin. In fact it only works in "SQL as field" in content or list views.

1283 Posts
7 years ago
Level 2


Yep, missed the asterisk


Get a Book for SEBLOD