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 9215679
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T02:15:28+00:00 2026-06-18T02:15:28+00:00

i need autocomplete in netbeans with codeigniter database mysql objects. I have enabled autocomplete

  • 0

i need autocomplete in netbeans with codeigniter database mysql objects.
I have enabled autocomplete for standard classes, but if i get mysql results there is nothing (because of dynamically created objects via http://php.net/manual/en/function.mysql-fetch-object.php
My workaround is to declare a model_raw class that just contains the fields.

/**
 * 
 * @param int $id
 * @return Account_model_raw 
 */
public function get_Account($id) {
    if (is_int($id) === FALSE)
        return null;

    $query = $this->db->get_where($this->table, array('id' => $id), 1);
    if ($query->num_rows() <= 0)
        return null;
    $ret = $query->row();

    return $ret;
}

class Account_model_raw{
var $id;
var $login;
var $password;
var $lastlogin;
}

And now i can get the autocomplete in netbeans if i use a the get_Account Method.

MY QUESTION is if there is a nicer way AND to keep the class synchronized with the mysql. what if a table changes? i dont want to manually edit the database and the raw class files.

Maybe those raw files can be created automatically with a script?

  • 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-18T02:15:29+00:00Added an answer on June 18, 2026 at 2:15 am

    You could use MY_Model or an ORM Library.

    https://github.com/jamierumbelow/codeigniter-base-model

    http://redbeanphp.com/

    So you dont need to declare explicitly in your model if you are using X and Y object, you use these library in a way you declare your Model using X table and then you can call unto the function the ORM provides to access the field values in your Database.

    PS : Dont rely on Autocomplete for these types of functionality, though you will not see what is in your DB from your NetBeans you can atleast rely on the library to know where to place x,y object you provide for it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

There's autocomplete , but it doesn't force the selection of an item. I need
I need to assign an ID to jquery autocomplete Combobox but i have multiple
I have a problem with using facet. I need autocomplete and for this I
I have a autocomplete textbox, and I need to fetch the students who are
I have tried for several days now to get autocomplete working. I have a
I need to have an autocomplete functionality using jquery, and I've encountered ZendX_JQuery which
Ok need some help here. I have an autocomplete setup to pull from a
I need help with Autocomplete box with Images. I cannot get it display correctly.
I'm attempting to use JQuery autocomplete and need to get the id of the
I have a jQuery autocomplete field which gets results from Amazon's autocomplete, as you

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.