Post by booksandtoys » Wed Jul 22, 2009 12:26 am

When I try to filter my orders by name, I get the following error:

Error: Unknown column 'o.firstname' in 'where clause'
Error No: 1054
SELECT COUNT(*) AS total FROM `order` WHERE order_status_id > '0' AND CONCAT(o.firstname, ' ', lastname) LIKE '%tracy%'

Can anyone help?

New member

Posts

Joined
Wed Jun 17, 2009 4:43 am

Post by Daniel » Wed Jul 22, 2009 1:02 am

remove the .o in the query

i think i fixed this in 1.3.0

OpenCart®
Project Owner & Developer.


User avatar
Administrator

Posts

Joined
Fri Nov 03, 2006 6:57 pm

Post by WCNZ » Fri Jul 24, 2009 8:18 am

Daniel's right: Here's how you do it

1: Open admin > model > customer > order.php
2: Go to line 148
3: change this part:

$sql .= " AND CONCAT(o.firstname, ' ', lastname)

to this

$sql .= " AND CONCAT(firstname, ' ', lastname)

That fixes the filter by name error. ;)

New member

Posts

Joined
Mon Mar 24, 2008 11:21 am
Who is online

Users browsing this forum: No registered users and 3 guests