Jump to content

Table Missing ??


NinjaTaktikz

Recommended Posts

SELECT
      SUM(IF(increment_day < '2010-06-01',SUM(vdat_2992.counts),SUM(vdat_2449.clicktositeindicator))) as CTS
FROM
      (
        SELECT * FROM vdat_2874 WHERE increment_day >= '2010-06-01'
        UNION
        SELECT * FROM vdat_2992 WHERE increment_day <= '2010-06-01'
      ) detail    
WHERE
      campaignid IN (1633605)

 

I keep getting error saying

Category Timestamp Duration Message Line Position

Error 7/14/2011 12:00:44 PM 0:00:11.875 <link> - MySQL Database Error: Unknown column 'vdat_2992.counts' in 'field list' 1 0

 

What am I doing wrong. I even gave the database table in front of the column. Please Help.

 

Thank You

 

Gary

Link to comment
https://forums.phpfreaks.com/topic/242013-table-missing/
Share on other sites

@OP

 

Perhaps,

SELECT
      SUM(IF(increment_day < '2010-06-01',SUM(detail.counts),SUM(detail.clicktositeindicator))) as CTS
FROM
      (
        SELECT * FROM vdat_2874 WHERE increment_day >= '2010-06-01'
        UNION
        SELECT * FROM vdat_2992 WHERE increment_day <= '2010-06-01'
      ) detail    
WHERE
      campaignid IN (1633605)

will do?

 

Hope it helps.

Link to comment
https://forums.phpfreaks.com/topic/242013-table-missing/#findComment-1243355
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.