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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T08:05:34+00:00 2026-05-31T08:05:34+00:00

Here is my code: $child = $this->getDetails($row[‘ParentOf_Id’]); which is in another function that calls

  • 0

Here is my code:

$child = $this->getDetails($row[‘ParentOf_Id’]);

which is in another function that calls a function called getdetails:

function getDetails($child_id=null,$limit=20){

    // select all the fields in the children table
    $this->db->select(castedColumns($this->children_table, $this->db));
    //where the id is the child id
    $q = $this->db->get_where($this->children_table, 'id='.$child_id);
    //store results array in details
    $details = $q->row_array();

I then get the following SQL error:

A Database Error Occurred
Error Number:

Incorrect syntax near ‘=’.

SELECT CAST(AdditionalNotes AS TEXT) as AdditionalNotes, CAST(DisabilitiesNotes AS TEXT) as DisabilitiesNotes, DOB, msrepl_tran_version FROM Children WHERE id=

Id does not get appended? why?

Been driving me nuts because, when I do echo $child_id; I get the child Id before passing it into the SQL.

  • 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-05-31T08:05:35+00:00Added an answer on May 31, 2026 at 8:05 am

    try:

    $this->db->select(castedColumns($this->children_table, $this->db));
    $q = $this->db->get_where($this->children_table, array('id' => $child_id));
    $details = $q->row_array();
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this code here, which is intended to allow any type of arguments:
Ok the error is showing up somewhere in this here code if($error==false) { $query
enter code here Hi All, I have a simple windows service application that connects
See here: http://code.google.com/p/ie7-js/ Does anyone have any experience or remarks about this javascript? Is
I have this code here: var infiltrationResult; while(thisOption) { var trNode = document.createElement('tr'); var
I have code that's somewhat like this: ($i=0; $i < 100; $i++) { do
here is post my code:this is no the entire code but enough to explain
I have a java class that creates a process, called child, using ProcessBuilder. The
This code is given in python official essays on graph theory . Here's the
How to prevent parent event if child's event is executed. Here is the code

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.