TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Abhilash J A
536
2.4k
597k
sql query for duplicate records
Jun 10 2016 9:28 AM
Hello Sir,
I am stuck with a problem, Here is master(Tble_MainData) table contain company name, brand name, item name. But I want list of MasterID,companyid,brandid,itemid as same shown in the matertable's each record instead of names, using select query that below mentioned
'
(if there is mistake in select query please current it) and also i have attached herewith 4 tables with data script.
select distinct(Tble_MainData.ID),ProductCompany.Id as CompanyID,Brands.Id as BrandID, Items.Id as ItemID from Tble_MainData
inner join Brands on Tble_MainData.Brand = Brands.BrandName
inner join Items on Tble_MainData.Item = Items.ItemName
inner join ProductCompany on Tble_MainData.Company = ProductCompany.CompanyName
Kindly replay me.
Thanks.
Attachment:
DB_4_Tables.zip
Reply
Answers (
3
)
My trigger is not insert value into correct row
Run time Error in C#