Giter Site home page Giter Site logo

Comments (7)

yandod avatar yandod commented on June 10, 2024

table prefix is quite suspicious.
could you show list of tables on your database?

from candycane.

drtobal avatar drtobal commented on June 10, 2024

yo, here is the show tables query on mysql
I have created another database called ttest_candycane, but the error is the same.

mysql> show tables;
+---------------------------+
| Tables_in_ttest_candycane |
+---------------------------+
| cc_attachments            |
| cc_auth_sources           |
| cc_boards                 |
| cc_changes                |
| cc_changesets             |
| cc_changesets_issues      |
| cc_comments               |
| cc_custom_fields          |
| cc_custom_fields_projects |
| cc_custom_fields_trackers |
| cc_custom_values          |
| cc_documents              |
| cc_enabled_modules        |
| cc_enumerations           |
| cc_issue_categories       |
| cc_issue_relations        |
| cc_issue_statuses         |
| cc_issues                 |
| cc_journal_details        |
| cc_journals               |
| cc_members                |
| cc_messages               |
| cc_news                   |
| cc_plugin_schema_info     |
| cc_projects               |
| cc_projects_trackers      |
| cc_queries                |
| cc_repositories           |
| cc_roles                  |
| cc_schema_migrations      |
| cc_settings               |
| cc_time_entries           |
| cc_tokens                 |
| cc_trackers               |
| cc_user_preferences       |
| cc_users                  |
| cc_versions               |
| cc_watchers               |
| cc_wiki_content_versions  |
| cc_wiki_contents          |
| cc_wiki_pages             |
| cc_wiki_redirects         |
| cc_wikis                  |
| cc_workflows              |
+---------------------------+
44 rows in set (0.00 sec)

from candycane.

yandod avatar yandod commented on June 10, 2024

What did you set for table prefix?
for quick solution, not using table prefix should help you.

from candycane.

drtobal avatar drtobal commented on June 10, 2024

the table prefix was cc_.

I know that if I do not use the table prefix it works perfect, but also wanted to report the issue.

from candycane.

drtobal avatar drtobal commented on June 10, 2024

yo, I am working on solve this, and I found the following.

The error occurs on Journal and Attachment, I think is provocated by the table prefix, is setted before process the query, here is the $queryData['joins'] before find for Journal.

array (size=5)
  0 => 
    array (size=4)
      'type' => string 'LEFT' (length=4)
      'table' => string '`ttest_candycane`.`cc_issues`' (length=29)
      'alias' => string 'Issue' (length=5)
      'conditions' => string 'Issue.id=Journal.journalized_id' (length=31)
  1 => 
    array (size=4)
      'type' => string 'LEFT' (length=4)
      'table' => string '`ttest_candycane`.`cc_projects`' (length=31)
      'alias' => string 'Project' (length=7)
      'conditions' => string 'Project.id=Issue.project_id' (length=27)
  2 => 
    array (size=4)
      'type' => string 'LEFT' (length=4)
      'table' => string '`ttest_candycane`.`cc_trackers`' (length=31)
      'alias' => string 'Tracker' (length=7)
      'conditions' => string 'Tracker.id=Issue.tracker_id' (length=27)
  3 => 
    array (size=4)
      'type' => string 'LEFT' (length=4)
      'table' => string '`ttest_candycane`.`cc_journal_details`' (length=38)
      'alias' => string 'JournalDetail' (length=13)
      'conditions' => string 'Journal.id=JournalDetail.journal_id' (length=35)
  4 => 
    array (size=4)
      'type' => string 'LEFT' (length=4)
      'table' => string '`ttest_candycane`.`cc_users`' (length=28)
      'alias' => string 'User' (length=4)
      'conditions' => string 'User.id=Journal.user_id' (length=23)

I think it would be

array (size=5)
  0 => 
    array (size=4)
      'type' => string 'LEFT' (length=4)
      'table' => string 'issues' (length=6)
      'alias' => string 'Issue' (length=5)
      'conditions' => string 'Issue.id=Journal.journalized_id' (length=31)
  1 => 
    array (size=4)
      'type' => string 'LEFT' (length=4)
      'table' => string 'projects' (length=8)
      'alias' => string 'Project' (length=7)
      'conditions' => string 'Project.id=Issue.project_id' (length=27)
  2 => 
    array (size=4)
      'type' => string 'LEFT' (length=4)
      'table' => string 'trackers' (length=8)
      'alias' => string 'Tracker' (length=7)
      'conditions' => string 'Tracker.id=Issue.tracker_id' (length=27)
  3 => 
    array (size=4)
      'type' => string 'LEFT' (length=4)
      'table' => string 'journal_details' (length=15)
      'alias' => string 'JournalDetail' (length=13)
      'conditions' => string 'Journal.id=JournalDetail.journal_id' (length=35)
  4 => 
    array (size=4)
      'type' => string 'LEFT' (length=4)
      'table' => string 'users' (length=5)
      'alias' => string 'User' (length=4)
      'conditions' => string 'User.id=Journal.user_id' (length=23)

I'm working on a PR for this.

from candycane.

drtobal avatar drtobal commented on June 10, 2024

here is the PR for this #249

from candycane.

drtobal avatar drtobal commented on June 10, 2024

Solved on #249

from candycane.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.