Keyword

Advanced Search

Search Results (Searched for: Re Error SQL)

  • PM Muthumbi
  • PM Muthumbi's Avatar
13 Mar 2010 06:40
Replied by PM Muthumbi on topic Front End Article Submission?

Front End Article Submission?

Category: English K2 Community

I want the same functionality for registered members to post news. I have created an item menu but i get an item not found error, am i missing out on something? There is also an option to point to an item to display but with it there isn't a link to post news. In my own opinion i thought it was there so that an item can be featured itself. Also my latest news link wont work, am still getting Warning: Invalid argument supplied for foreach() in \components\com_k2\views\latest\view.html.php on line 120 error, i tried replacing with a code from forum member tonico [Attachment bug: SQL error ] file modified.rtf but nothing worked i still get the error. Please help with this. Thank you.

Olivier Nolbert said:Hi Nick,
You have to create an item menu that links to a k2 itemlist view, then just connect to the front-office of your website, click on the item menu and you should have a link 'Add an item...' at the top right of the page.

Are you french ?

Olivier
  • jeanette hustad
  • jeanette hustad's Avatar
08 Mar 2010 14:39

clicking on image gives SQL syntax error when opening the item/page

Category: English K2 Community

Yes i know this stuff might happen when using SVN. But what is good is that we do discover some bugs and get rid of them to the next release:-)

Lefteris Kavadas said:Hi. You are right about this bug. Just fixed it. Please note that when using the SVN version you may encounter in such kind of issues. Thank you for reporting this issue to us.
  • Lefteris
  • Lefteris's Avatar
08 Mar 2010 12:20

clicking on image gives SQL syntax error when opening the item/page

Category: English K2 Community

Hi. You are right about this bug. Just fixed it. Please note that when using the SVN version you may encounter in such kind of issues. Thank you for reporting this issue to us.
  • Ian Powney
  • Ian Powney's Avatar
08 Mar 2010 09:37
Replied by Ian Powney on topic Attachment bug: SQL error

Attachment bug: SQL error

Category: English K2 Community

Thanks for your code - this has solved my headache. - Fixed the problem

tonino said:Hello my friend, I resolved in this way (I am no expert in php): i have edit / components/com_k2/templates/default/item.php

look for the line of code n 354

I attach a file in text format because it is impossible to paste code on this forum

To me it worked!

Sorry for my English
  • Simon Wells
  • Simon Wells's Avatar
06 Mar 2010 16:35

After Adding A bulk amount of data via phpmyadmin add new item brings up error

Category: English K2 Community

Hi Mickey,

Seems by the error message that this is a problem with your database and not K2.
I would suggest that your restore your database to before the bulk upload.
Recheck your upload file for errors, consider importing in the data in two smaller batches.

I would consult the documentation for mysql, check the mysql forums or speak with your host company.

Regards,

Simon
K2Joom.com
  • jeanette hustad
  • jeanette hustad's Avatar
05 Mar 2010 21:04

clicking on image gives SQL syntax error when opening the item/page

Category: English K2 Community

Hi,

 

I have inserted an image in my article. When clicking on the image from the category view, the item (page) opens and the image gets bigger. But on top of the page i get the following message:

 

No valid database connection 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 ') AND itemID!=4' at line 1 SQL=SELECT DISTINCT itemID FROM jos_k2_tags_xref WHERE tagID IN (,) AND itemID!=4

I am running joomla v. 1.5.5, latest k2 with the "beta" version for frontend editing with joomfish installed.

Maybe it has something to do with the beta version, but anyway i need to fix it.

 

Does anyone know how and in which file i can fix this?
  • C Pham
  • C Pham's Avatar
02 Mar 2010 12:26

Warning: Invalid argument supplied for foreach () in

Category: English K2 Community

Hi, I just figured out the issue. It required some digging. Basically the tables were not created during the install process. My issue was the SQL file used by K2 in the install package had some statements that were throwing errors with MySQL 4.X that was on my server. I updated to 5.X and now K2 is installed and everything works great.

Thanks.
  • C Pham
  • C Pham's Avatar
02 Mar 2010 10:38

Warning: Invalid argument supplied for foreach () in

Category: English K2 Community

Hi, I'm having the same issue. Downloaded the latest k2 install zip file and this error comes up after a "success" message:

Thank you for installing K2 by JoomlaWorks, the powerful content component for Joomla! 1.5.

Warning: Invalid argument supplied for foreach() in ../joomla/libraries/joomla/database/database/mysql.php on line 678

Warning: array_key_exists() [function.array-key-exists]: The second argument should be either an array or an object in ../joomla/administrator/components/com_k2/install.k2.php on line 73

Warning: Invalid argument supplied for foreach() in ../joomla/administrator/components/com_k2/install.k2.php on line 103

This issue doesn't occur when I installed it on my local that uses XAMPP. Any ideas?

Thanks!
  • Arturo Guzman
  • Arturo Guzman's Avatar
26 Feb 2010 00:16
Replied by Arturo Guzman on topic Search K2 Problem

Search K2 Problem

Category: English K2 Community

Hi,

The problem is when trying to search in the tags, if you turn it off from the Search_K2 plugin parameters, the error won't show anymore, of course you'll lose the tag searching functionality.

As far as I can tell, this is a bug in the K2 Search plugin, since it uses MySQL's MATCH function incorrectly. So the best thing to do is to go back to the old plugin, where the search is done using the LIKE operator.

In the MySQL Site it explains that the MATCH function in NATURAL LANGUAGE MODE performs a search against a text collection, and a text collection can only exist within a table. When the plugin tries to search the tags it adds a foreign column into the MATCH function, which of course breaks the query.

Art.
  • Lefteris
  • Lefteris's Avatar
18 Feb 2010 13:34
Replied by Lefteris on topic Bug in the search plugin

Bug in the search plugin

Category: English K2 Community

Hi. The queries you posted are from the K2 component search not the K2 search plugin. The queries are fine. Maybe providing a link to your site will help us see what's wrong.

cmath said:Hi Lefteris, The following sql query is executed, but there are no errors on the page, although the search is not returning any results:
SELECT i.*, c.name AS categoryname,c.id AS categoryid, c.alias AS categoryalias, c.params AS categoryparams
FROM jos_k2_items AS i
LEFT JOIN jos_k2_categories AS c
ON c.id = i.catid
WHERE i.published = 1
AND i.access <= 2
AND i.trash = 0
AND c.published = 1
AND c.access <= 2
AND c.trash = 0
AND ( i.publish_up = '0000-00-00 00:00:00' OR i.publish_up <= '2010-02-17 10:51:06' )
AND ( i.publish_down = '0000-00-00 00:00:00' OR i.publish_down >= '2010-02-17 10:51:06' )
AND MATCH(i.title, i.introtext, i.`fulltext`,i.image_caption,i.image_credits,i.video_caption,i.video_credits,i.extra_fields_search,i.metadesc,i.metakey) AGAINST ('ramakrishna')
ORDER BY i.id DESC
LIMIT 0, 10
SELECT COUNT(*)
FROM jos_k2_items AS i
LEFT JOIN jos_k2_categories c
ON c.id = i.catid
WHERE i.published = 1
AND i.access <= 2
AND i.trash = 0
AND c.published = 1
AND c.access <= 2
AND c.trash = 0
AND ( i.publish_up = '0000-00-00 00:00:00' OR i.publish_up <= '2010-02-17 10:51:06' )
AND ( i.publish_down = '0000-00-00 00:00:00' OR i.publish_down >= '2010-02-17 10:51:06' )
AND MATCH(i.title, i.introtext, i.`fulltext`,i.image_caption,i.image_credits,i.video_caption,i.video_credits,i.extra_fields_search,i.metadesc,i.metakey) AGAINST ('ramakrishna')

Thanks,

Lefteris Kavadas said:Hi. Are you getting any error? Please enable debug mode and check the query ( or post it here....). cmath said:Lefteris, I have set Enable search in tags to NO, but still have the problem in search. What is the fix for this? Could you provide us the updated search file?
  • Swami Abhiramananda
  • Swami Abhiramananda's Avatar
17 Feb 2010 13:31
Replied by Swami Abhiramananda on topic Bug in the search plugin

Bug in the search plugin

Category: English K2 Community

Hi Lefteris,
The following sql query is executed, but there are no errors on the page, although the search is not returning any results:
SELECT i.*, c.name AS categoryname,c.id AS categoryid, c.alias AS categoryalias, c.params AS categoryparams
FROM jos_k2_items AS i
LEFT JOIN jos_k2_categories AS c
ON c.id = i.catid
WHERE i.published = 1
AND i.access <= 2
AND i.trash = 0
AND c.published = 1
AND c.access <= 2
AND c.trash = 0
AND ( i.publish_up = '0000-00-00 00:00:00' OR i.publish_up <= '2010-02-17 10:51:06' )
AND ( i.publish_down = '0000-00-00 00:00:00' OR i.publish_down >= '2010-02-17 10:51:06' )
AND MATCH(i.title, i.introtext, i.`fulltext`,i.image_caption,i.image_credits,i.video_caption,i.video_credits,i.extra_fields_search,i.metadesc,i.metakey) AGAINST ('ramakrishna')
ORDER BY i.id DESC
LIMIT 0, 10
SELECT COUNT(*)
FROM jos_k2_items AS i
LEFT JOIN jos_k2_categories c
ON c.id = i.catid
WHERE i.published = 1
AND i.access <= 2
AND i.trash = 0
AND c.published = 1
AND c.access <= 2
AND c.trash = 0
AND ( i.publish_up = '0000-00-00 00:00:00' OR i.publish_up <= '2010-02-17 10:51:06' )
AND ( i.publish_down = '0000-00-00 00:00:00' OR i.publish_down >= '2010-02-17 10:51:06' )
AND MATCH(i.title, i.introtext, i.`fulltext`,i.image_caption,i.image_credits,i.video_caption,i.video_credits,i.extra_fields_search,i.metadesc,i.metakey) AGAINST ('ramakrishna')

Thanks,

Lefteris Kavadas said:Hi. Are you getting any error? Please enable debug mode and check the query ( or post it here....). cmath said:Lefteris, I have set Enable search in tags to NO, but still have the problem in search. What is the fix for this? Could you provide us the updated search file?
  • harrytasker
  • harrytasker's Avatar
15 Feb 2010 20:36 - 17 Feb 2010 14:28
[Solved] Problem with installation was created by harrytasker

[Solved] Problem with installation

Category: Simple Image Gallery PRO

I just bought the Simple Image Gallery Pro (as i was very happy with the Frontpage Slideshow, which i also bought).
I have a problem though with installation.
I am getting the following error:
        * Plugin Install: DB function failed with error number 2006          MySQL server has gone away SQL=SELECT `id` FROM `jos_plugins` WHERE folder = 'content' AND element = 'jw_sigpro'          SQL =          SELECT `id` FROM `jos_plugins` WHERE folder = 'content' AND element = 'jw_sigpro'        * Error Loading ModulesMySQL server has gone away SQL=SELECT id, title, module, position, content, showtitle, control, params FROM jos_modules AS m LEFT JOIN jos_modules_menu AS mm ON mm.moduleid = m.id WHERE m.published = 1 AND m.access <= 2 AND m.client_id = 1 ORDER BY position, ordering 

I really don't have a clue what is wrong, maybe someone can help me out (using Joomla 1.5)
  • Fernando P
  • Fernando P's Avatar
15 Feb 2010 19:40
Replied by Fernando P on topic Bug in the search plugin

Bug in the search plugin

Category: English K2 Community

I'm using:

Joomla 1.5.15
MySQL 5.1.30
PHP 5.2.9
Apache 2.2.11


Fernando P said:I'm having exactly the same problem. Any solutions yet?
No k2 results on normal mode, and this errorwith debug ON

JDatabaseMySQL::query: 1210 - Incorrect arguments to MATCH SQL=SELECT i.title AS title, i.metadesc, i.metakey, c.name as section, i.image_caption, i.image_credits, i.video_caption, i.video_credits, i.extra_fields_search, tags.name as tag, i.created, CONCAT(i.introtext, i.fulltext) AS text, CASE WHEN CHAR_LENGTH(i.alias) THEN CONCAT_WS(':', i.id, i.alias) ELSE i.id END as slug, CASE WHEN CHAR_LENGTH(c.alias) THEN CONCAT_WS(':', c.id, c.alias) ELSE c.id END as catslug FROM jos_k2_items AS i INNER JOIN jos_k2_categories AS c ON c.id=i.catid AND c.access &lt;= 18 LEFT JOIN jos_k2_tags_xref tags_xref ON tags_xref.itemID = i.id LEFT JOIN jos_k2_tags tags ON tags.id = tags_xref.tagID WHERE MATCH(i.title, i.introtext, i.`fulltext`,tags.name,i.extra_fields_search,i.image_caption,i.image_credits,i.video_caption,i.video_credits,i.metadesc,i.metakey) AGAINST ('clara') AND i.trash = 0 AND i.published = 1 AND i.access &lt;= 1 AND c.published = 1 AND c.access &lt;= 1 AND c.trash = 0 GROUP BY i.id ORDER BY i.created DESC LIMIT 0, 50
  • Fernando P
  • Fernando P's Avatar
15 Feb 2010 09:42
Replied by Fernando P on topic Bug in the search plugin

Bug in the search plugin

Category: English K2 Community

I'm having exactly the same problem. Any solutions yet?

No k2 results on normal mode, and this errorwith debug ON

JDatabaseMySQL::query: 1210 - Incorrect arguments to MATCH SQL=SELECT i.title AS title, i.metadesc, i.metakey, c.name as section, i.image_caption, i.image_credits, i.video_caption, i.video_credits, i.extra_fields_search, tags.name as tag, i.created, CONCAT(i.introtext, i.fulltext) AS text, CASE WHEN CHAR_LENGTH(i.alias) THEN CONCAT_WS(':', i.id, i.alias) ELSE i.id END as slug, CASE WHEN CHAR_LENGTH(c.alias) THEN CONCAT_WS(':', c.id, c.alias) ELSE c.id END as catslug FROM jos_k2_items AS i INNER JOIN jos_k2_categories AS c ON c.id=i.catid AND c.access &lt;= 18 LEFT JOIN jos_k2_tags_xref tags_xref ON tags_xref.itemID = i.id LEFT JOIN jos_k2_tags tags ON tags.id = tags_xref.tagID WHERE MATCH(i.title, i.introtext, i.`fulltext`,tags.name,i.extra_fields_search,i.image_caption,i.image_credits,i.video_caption,i.video_credits,i.metadesc,i.metakey) AGAINST ('clara') AND i.trash = 0 AND i.published = 1 AND i.access &lt;= 1 AND c.published = 1 AND c.access &lt;= 1 AND c.trash = 0 GROUP BY i.id ORDER BY i.created DESC LIMIT 0, 50
  • Chris
  • Chris's Avatar
11 Feb 2010 19:40

Fatal error: Allowed memory size of 50331648 bytes exhausted (tried to allocate 85 bytes) in /libraries/joomla/database/database/mysqli.php on line 478

Category: English K2 Community

Ok I think I know how to fix this, but I could use some help finding something. How do you reset the filter to be 20 users shown instead of all users shown? Seems that there is just too many people showing up for the memory limit to handle the request.
  • Chris
  • Chris's Avatar
11 Feb 2010 18:39

Fatal error: Allowed memory size of 50331648 bytes exhausted (tried to allocate 85 bytes) in /libraries/joomla/database/database/mysqli.php on line 478

Category: English K2 Community

I think I know the problem here, since my member database is 27k+, but I figured K2 would pull the users in batches like Joomla does to prevent too much data being pulled through at once.  Is this ont correct?
  • Stephen Robb
  • Stephen Robb's Avatar
10 Feb 2010 19:45
Replied by Stephen Robb on topic Search K2 Problem

Search K2 Problem

Category: English K2 Community

Hi Alwin,

I had this issue at one point and figured that the fields in the FULLTEXT search had to match exactly the fields with this flag set. (i.e. I needed to include all of the fields with FULLTEXT set in the MATCH clause). If you do that, you won't get the above error.

Stephen

Alwin said:I also have the same problem. When I run the query in mysql it is showing
ERROR 1191 (HY000): Can't find FULLTEXT index matching the column list.

and I think that is some problem with the FULLTEXT indexing...Anyone has got a solution..? also please let me know where I get the old file ...?
  • Ivan Kulaš
  • Ivan Kulaš's Avatar
08 Feb 2010 21:31
Problem with crating the Extra Field Group was created by Ivan Kulaš

Problem with crating the Extra Field Group

Category: English K2 Community

Problem with creating Extra Field Groups

TableK2ExtraFieldsGroup::store failed - Table 'zupa.jos_k2_extra_fields_groups' doesn't exist SQL=INSERT INTO `jos_k2_extra_fields_groups` ( `id`,`name` ) VALUES ( '','Blog' )




Problem when I create Categorie:

PHP Fatal error: Call to undefined function mb_internal_encoding() in C:\Domains\es-s.hr\wwwroot\zupa-bili-brig\administrator\components\com_k2\tables\k2category.php on line 49



I will work site in subdomain
  • d.k.shukla
  • d.k.shukla's Avatar
31 Jan 2010 17:53
Replied by d.k.shukla on topic Search K2 Problem

Search K2 Problem

Category: English K2 Community

Hi
I would like to share my other experience about full text search with latest K2 ver 2.2, it is working fine without any error at my local machine. My local system information is following.
PHP Built on: Linux 2.6.32-ARCH #1 SMP PREEMPT Thu Jan 7 22:28:29 CET 2010 x86_64
Database Version: 5.1.42
Database Collation: utf8_general_ci
PHP Version: 5.3.1
Web Server: Apache/2.2.14 (Unix) PHP/5.3.1 with Suhosin-Patch Phusion_Passenger/2.2.2
Web Server to PHP interface: apache2handler
Joomla! Version: Joomla! 1.5.15 Stable [ Wojmamni Ama Mamni ] 05-November-2009 04:00 GMT
User Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.7) Gecko/20100105 Shiretoko/3.5.7

After doing this test it seems that error is coming due to Mysql version but I am not sure.

I hope somebody will fix this error or express their views on this behaviour.

Shukla


Stephen Robb said:I am having the same problem. The issues seems to be with the SELECT statement, and specifically the "MATCH AGAINST" clause. I'm no SQL admin, but I can extract the query K2 is sending using debug mode and edit the query to work using LIKE, but I can't get it to work with the MATCH construct. Note that the exact match option uses "BOOLEAN MODE" in the match, and this seems to work for me too.
To me it looks like K2 is creating some invalid SQL.

This works (i.e. returns rows) where search string is found:

SELECT * FROM jos_k2_items as i WHERE MATCH(i.title, i.introtext, i.`fulltext`,i.extra_fields_search,i.image_caption,i.image_credits,i.video_caption,i.video_credits,i.metadesc,i.metakey) AGAINST ('"searchstring"' IN BOOLEAN MODE)

This doesn't work (i.e. returns no rows, neither in Joomla or in phpMyAdmin):

SELECT * FROM jos_k2_items as i WHERE
MATCH(i.title, i.introtext, i.`fulltext`,i.image_caption,i.image_credits,i.video_caption,i.video_credits,i.extra_fields_search,i.metadesc,i.metakey) AGAINST ('searchsrring')
Displaying 701 - 720 out of 789 results.

Powered by Kunena Forum