Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8865173
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T16:26:14+00:00 2026-06-14T16:26:14+00:00

Building a component, version 1.5 (gonna be cut loose soon, I know, but it’s

  • 0

Building a component, version 1.5 (gonna be cut loose soon, I know, but it’s what I need to work with.)

Issue with the /admin/tables/mycom.php file. (In which mycom is whatever the component name is)

I’m not following the use of this file. From reading the walkthrough, it’s creating a table class that extends JTables.

Now, some of the DB column names I’m using have ‘space’ characters in them. ie, ‘field 1’ instead of ‘field1’ (don’t ask me, it’s not my data.)

The sytax for identify these fiels is:

 $myfield = null

It says these reference your fields in the mySQL table, but my field names include space which wouldn’t work with this syntax.

Any help understanding this class, it’s php file and what it’s use is would be much appreciated.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T16:26:16+00:00Added an answer on June 14, 2026 at 4:26 pm

    By creating a JTable class for your table most of the code for editing your table is done for you. I suggest you familiarize yourself with JTable in the Joomla library so you know what functions are pre-written for you that you can use and override.

    As to the issue of your DB column name having spaces… well to be honest it’s just a bad idea. Here are some MySQL naming convention best practices for you….

    • always use lowercase with underscores instead of CamelCase. Goes for both the table and column names. (first_name instead of FirstName, address_1 instead of Address1
    • every table should have an “id” column as the primary key, don’t call it UserID or anything else
    • the table name should be plural (profiles, supports, etc.)
    • foreign keys should have the singular name of the related table followed by underscore id. For example: “profile_id” or “support_id”.

    If you can I would recommend you do some ALTER TABLE updates to the MySQL e.g.

    ALTER TABLE `#__example` CHANGE `Field 1` `field_1` VARCHAR(50) NOT NULL DEFAULT 'empty';
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i'm building a serialization component that uses reflection to build the serialized data, but
I'm building a gui component that has a tree-based data model (e.g. folder structure
When building a Delphi 2009 component package, how do you specify which directory should
I'm building a login form composite component. The page that uses it will pass
I'm building a component that is an extension for another software product. It's loaded
I'm building a component to ban spam bots' IPs based on the invalid requests
I am new to component building, and I have noticed that other components have
Am in process of building my custom component. Am trying to read values of
I've recently begun building version 2 of my year-old custom MVC framework. It's worked
I have a project I'm building with maven and I need to generate a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.