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

  • SEARCH
  • Home
  • 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 8297063
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T15:15:45+00:00 2026-06-08T15:15:45+00:00

In magento i created a custom module and completed the template and controller part,

  • 0

In magento i created a custom module and completed the template and controller part, but confused about handling the model and db part. From my custom module i want to alter the table sales_flat_order_item and add an additional field. Now i created a set up script like

$installer = $this;
$installer->startSetup();
$installer->run("
ALTER TABLE sales_flat_order_item ADD COLUMN new_field TEXT NULL;

ALTER TABLE sales_flat_invoice_item ADD COLUMN new_field TEXT NULL;

ALTER TABLE sales_flat_shipment_item ADD COLUMN new_field TEXT NULL;
");
$installer->endSetup(); 

in path
app\code\local\Namespace\Module\sql\_setup\mysql4-install-0.1.0.php
But the table is not seems to be altered what configuration can be done in the script or module files to add the additional field and processing data with the same like the other fields. any one help. Thanks.

  • 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-08T15:15:47+00:00Added an answer on June 8, 2026 at 3:15 pm

    what is your config.xml configuration looks like?

    under <global></global> tag you need to add:

    <resources>
        <sql_setup>
            <setup>
                <module>Namespace_Module</module>
            </setup>
        </sql_setup>
    </resources>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hi created a custom model inside Magento(resource is based on Mage_Core_Model_Resource_Db_Collection_Abstract ). Everything works
I read a lot of documentation about custom module creation for Magento. For my
I am creating a custom module in magento.I have created block class and phtml
I was created a custom module for my Magento project. This module works in
I am trying to create a new custom module in magento but the layout
I have created a custom template and skin for my multilingual magento website, my
I have created a custom Magento module which extends the core sales order functionality
I have created a new custom module and DB table for magento. What is
I have created a custom module in magento and wants to show products with
I've run into an issue with a custom Magento module I've created. In short,

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.