SrilekhaRamesh Posted July 18, 2023 Share Posted July 18, 2023 Table1:Revenue data in that table (dealerid,Description,excavator,grader,wheelloader,slm)all the fields in table1 Table2:Revenue Target in the table(Dealer_ID,Category_Name,Description)all the fields in table2. I'm using (dealerid,Dealer_ID,Description) both the fields are same using this innerjoin for both the table but category_Name and description both the fields exceuting duplicate rows exctract.. Quote Link to comment https://forums.phpfreaks.com/topic/317094-mysql/ Share on other sites More sharing options...
requinix Posted July 18, 2023 Share Posted July 18, 2023 I don't see any duplicate rows in that output. 1. What data do you have in the tables? 2. What is the query you are executing? 3. What results do you want to get, and why? Quote Link to comment https://forums.phpfreaks.com/topic/317094-mysql/#findComment-1610578 Share on other sites More sharing options...
SrilekhaRamesh Posted July 19, 2023 Author Share Posted July 19, 2023 12 hours ago, requinix said: I don't see any duplicate rows in that output. 1. What data do you have in the tables? 2. What is the query you are executing? 3. What results do you want to get, and why? SELECT dbms.revenue_data.dealerid,dbms.revenuetarget.Category_Name,dbms.revenuetarget.Description, dbms.revenuetarget.Dealer_ID,dbms.revenue_data.Excavator,dbms.revenue_data.Grader,dbms.revenue_data.WheelLoader,dbms.revenue_data.SLM from dbms.revenue_data Inner join dbms.revenuetarget ON dbms.revenue_data.dealerid=dbms.revenuetarget.Dealer_ID WHERE dbms.revenuetarget.Dealer_ID='81019218'; In above the query for both revenuedata and revenue target but duplicates will exceuting can u help me plz. I getting output from these query but how I got output means for eg: A=1, B=2,C=3 O/P: A=1 A-2 A=3 B=1 B-2 B=3 C=1 C-2 C=3 I am getting like this Quote Link to comment https://forums.phpfreaks.com/topic/317094-mysql/#findComment-1610583 Share on other sites More sharing options...
requinix Posted July 19, 2023 Share Posted July 19, 2023 There are no duplicates in that output either. Look at the Grader column: every value is different. That means every row is different. You need to describe what data you want to get with a query. What rows do you want? What values do you want? What rows and values do you not want? Quote Link to comment https://forums.phpfreaks.com/topic/317094-mysql/#findComment-1610585 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.