Topic-icon Using of variables in SQL query

More
07 Dec 2016 06:30 #3490

Hello,
SEF URL do not affect this functionality but as you said It's not working, It means the variable is not available in ID parameter. Please find it out which variable is being used and then update accordingly.


Thanks
Daniel

Please Log in or Create an account to join the conversation.

  • Jan Vašátko
  • Jan Vašátko's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
06 Dec 2016 21:06 #3489

Hello, I found when I use SEF URL (domain/category/id-alias), it is not working. If I put e.g. ?id=123 after it is working. Is it possible to use it with SEF URL?

Please Log in or Create an account to join the conversation.

More
06 Dec 2016 01:41 #3484

It seems to be the id variable is not available in GET / POST data. If it is, Please share your FTP & Backend Login credentials via Contact us form, We'll look into it.


Thanks
Daniel

Please Log in or Create an account to join the conversation.

  • Jan Vašátko
  • Jan Vašátko's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
05 Dec 2016 18:35 #3481

I have tried it, but when I use vchart module e.g. in article with id=123

select x, y
from #__table
where id = {id}

does not work (nothing shows). If I set

select x, y
from #__table
where id = 123

it is working. Are there some restrictions or should I use it spcial way-

Please Log in or Create an account to join the conversation.

More
05 Dec 2016 14:36 #3479

Hello,
If Article ID is there in get / post data, then it can be used. And in frontend Article ID is available in "id" variable, that's why you should use {id} ( id get variable is available on Article detail layout if you are intending to display the module on Article detail layout )


Thanks
Daniel

Please Log in or Create an account to join the conversation.

  • Jan Vašátko
  • Jan Vašátko's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
05 Dec 2016 14:27 #3478

Hello, you write

I don't understand the usage of the variables - what exactly are these variables? I would like to use SQL select like

select x, y
from #__table
where id = {articleid}

{articleid} should be the ID of the actual article. Can I use it this way? The purpose is to show different chart in every article.

Jan

Please Log in or Create an account to join the conversation.

Cron Job Starts