Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Sql Query Ambiguous column

Posted on 2013-12-19
3
Medium Priority
?
582 Views
Last Modified: 2013-12-19
I would do a filter in description column, but an error is returned:

Ambiguous column name 'description '.

How can solve.

select  ObrEq.mat, COALESCE(mar.name,obreq.descrip) as description
from obreq
left join Mar on ObrEq.IdMar=mar.IdMar
 where description like '%xxx%'

Open in new window

0
Comment
Question by:rflorencio
  • 2
3 Comments
 
LVL 32

Accepted Solution

by:
awking00 earned 2000 total points
ID: 39729975
where COALESCE(mar.name,obreq.descrip) like '%xxx%'
0
 

Author Closing Comment

by:rflorencio
ID: 39730022
Thanks awking00
0
 
LVL 32

Expert Comment

by:awking00
ID: 39730201
You're most welcome.
0

Featured Post

 [eBook] Windows Nano Server

Download this FREE eBook and learn all you need to get started with Windows Nano Server, including deployment options, remote management
and troubleshooting tips and tricks

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Windocks is an independent port of Docker's open source to Windows.   This article introduces the use of SQL Server in containers, with integrated support of SQL Server database cloning.
This month, Experts Exchange sat down with resident SQL expert, Jim Horn, for an in-depth look into the makings of a successful career in SQL.
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
Viewers will learn how to use the UPDATE and DELETE statements to change or remove existing data from their tables. Make a table: Update a specific column given a specific row using the UPDATE statement: Remove a set of values using the DELETE s…

886 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question