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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T19:51:56+00:00 2026-05-27T19:51:56+00:00

I am trying to achieve the following MySQL query in Zend Framework 1.11: SELECT

  • 0

I am trying to achieve the following MySQL query in Zend Framework 1.11:

SELECT [other_columns], 1 AS dontShow FROM deal_merchants;

I am interested in selecting the number 1 and giving it the dontShow alias. However when I run the following code:

$select = $this->select(Zend_Db_Table::SELECT_WITHOUT_FROM_PART);
$select->setIntegrityCheck(false)
       ->from('deal_merchants',array('MIN(BidPrice) AS price','USERS_ID','MIN(BidQuotaFrom) AS MinFrom','MAX(BidQuotaTo) AS MaxTo','users.ImageURL','1 AS dontShow'));

I get the following exception:

SQLSTATE[42S22]: Column not found: 1054 Unknown column 'deal_merchants.1' in 'field list'
  • 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-27T19:51:56+00:00Added an answer on May 27, 2026 at 7:51 pm

    Figured out how to do it. Not sure if it’s the best way, but it works. Here is how, if someone stumbles over this:

    $select = $this->select(Zend_Db_Table::SELECT_WITHOUT_FROM_PART);
    $select->setIntegrityCheck(false)
           ->from('deal_merchants',array('MIN(BidPrice) AS price','USERS_ID','MIN(BidQuotaFrom) AS MinFrom','MAX(BidQuotaTo) AS MaxTo','users.ImageURL','(SELECT 1 FROM dual) AS dontShow'));
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to achieve the following: SELECT id, name FROM t_profiles MINUS (SELECT p.id,
I am trying to achieve the following without using sub query. For a funding,
I am trying to achieve the following... _4S.NJB_Request request = (from r in db.NJB_Requests
I've following query to execute SELECT m.*, s.momento_idmember, sd.id_send, d.momento_id FROM `momento_send` s, `send_distribution`
I'm trying to achieve the following in SQL Server 2005: SELECT (IF EITHER EXISTS)
I am trying to achieve the following: I am using MySQL and ASP.NET. I
what i'm trying to achieve is the following. I've got a MySQL database and
I am tring to query a set of data from mySQL with the following
I am trying to achieve the following SQL from NHibernate (via NHibernate Criteria or
I'm trying to achieve the following: Where: Surname is always required NI Number OR

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.