CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • General Discussion (please no support requests here!) (Moderator: Michał Mach) »
  • 64 Character limit for Tags are too short
Pages: [1]

Author Topic: 64 Character limit for Tags are too short  (Read 1978 times)

druderman

  • I’m new here
  • *
  • Posts: 24
  • Karma: 0
  • CiviCRM version: 4.1+
  • CMS version: Drupal 7
  • MySQL version: 5.0.77 and 5.1
  • PHP version: 5.2.13
64 Character limit for Tags are too short
December 23, 2011, 08:34:12 am
I want to better identify contacts by assigning tags.
But when doing this I quickly hit the 64 character limit.

I want to track how they heard about my organization e.g. "online : web : yahoo" or "broadcast : radio : wcbs".
With tags like this, it's easy for someone to use the auto-lookup feature in case the list of tags is long e.g. to find all 'radio' tags or all 'broadcast'.
I also want to assign a program of interest at our university. Here's an example long one "Online Graduate Certificate Program in Sleep and Sleep Disorders in Health and Disease".
Actual use cases involve strings that can get up to about 100 characters.
(Really, what I ultimately want I want is long nested/hierarchical tags.)

To get around the 64 character limit on CiviCRM tags, I have done the following:

Run this SQL:
% ALTER TABLE `civicrm_tag` MODIFY `name` VARCHAR(255) NULL DEFAULT NULL COMMENT Name of Tag.';

Modify the data type definition here to make maxlength => 255 instead of 64:
civicrm/CRM/Core/DAO/Tag.php
'name' => array(
                    'name' => 'name',
                    'type' => CRM_Utils_Type::T_STRING,
                    'title' => ts('Name') ,
                    'maxlength' => 255,
                    'size' => CRM_Utils_Type::BIG,
                ) ,

What do you think?
Is a Define for Max Tag Length something that should be added to the civicrm.settings.php file at some point?
I use Drupal 6, is there a way to use Drupal tags instead of CiviCRM tags?
« Last Edit: December 23, 2011, 08:51:38 am by druderman »

Kurund Jalmi

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4169
  • Karma: 128
    • CiviCRM
  • CiviCRM version: 4.x, future
  • CMS version: Drupal 7, Joomla 3.x
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: 64 Character limit for Tags are too short
December 23, 2011, 09:52:35 am
Quote
Is a Define for Max Tag Length something that should be added to the civicrm.settings.php file at some point?
I don't think so, since it is not a scalable solution.

Quote
I use Drupal 6, is there a way to use Drupal tags instead of CiviCRM tags?
Currently no, but it would be great addition if you or someone in the community works on this.

Hth
Kurund
Found this reply helpful? Support CiviCRM

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: 64 Character limit for Tags are too short
December 23, 2011, 11:16:22 am
Hi,

Are you aware that tags can be hierarchical? It seems that you are trying to add the name of parents tags into the children tags.

X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

druderman

  • I’m new here
  • *
  • Posts: 24
  • Karma: 0
  • CiviCRM version: 4.1+
  • CMS version: Drupal 7
  • MySQL version: 5.0.77 and 5.1
  • PHP version: 5.2.13
Re: 64 Character limit for Tags are too short
January 03, 2012, 07:39:26 am
Don't you think a fixed limit of 64 characters is a little tight anyway?

Seriously:
I'm actually looking for a clear Drupal/CiviCRM way to associate Contacts with a list of majors ('BS in Biology', 'MS in Nursing', etc.) and additionally a source (the contact heard about us via 'web - yahoo - ad', 'broadcast - radio - WABC', etc.)
In each case, the list is too long (maybe 100+ choices) to expose as a drop-down and also the actual text for the options may be longer than 64 characters?
If I do not use CiviCRM tags, is there some other way to implement this that you might suggest that I explore?
(If I get some direction that does not include tags and tag length limits, then I can start a new thread on the topic.)




xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: 64 Character limit for Tags are too short
January 04, 2012, 09:45:21 pm
Do you have an example of > 64 char?

(personally never had the issues on one of my install)
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

druderman

  • I’m new here
  • *
  • Posts: 24
  • Karma: 0
  • CiviCRM version: 4.1+
  • CMS version: Drupal 7
  • MySQL version: 5.0.77 and 5.1
  • PHP version: 5.2.13
Re: 64 Character limit for Tags are too short
January 05, 2012, 05:25:17 am
Yep, from my post at the start of this thread:
"Online Graduate Certificate Program in Sleep and Sleep Disorders in Health and Disease"

I now think that tags are not right for this, since none of this information categorizes Contacts.
« Last Edit: January 05, 2012, 08:47:57 am by druderman »

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: 64 Character limit for Tags are too short
January 11, 2012, 07:13:41 am
Hi,

Part of the problem is that the tags are displayed in the summary, and long tags will make a weird result.

Otherwise, would it make sense to use a shorter name (eg. Online grad Sleep disorders) and put the complete correct name in the description?

X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • General Discussion (please no support requests here!) (Moderator: Michał Mach) »
  • 64 Character limit for Tags are too short

This forum was archived on 2017-11-26.