Click here to Skip to main content
15,891,253 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Dear Friend i have some problem when implimented project.Their are two tables name as t1 and t2.
In the t1 table this are fields DemoDate,AuthoBy and t2 table fields are DateFor,OperatorName.In
this two table AuthoBy And OperatorName have same just like sachin,vinod etc.If i am insert information in t1 table just like 09:30 as DemoDate, Sachin as AuthoBy,another one field 9:50 as DemoDate,Vinod as AuthoBy.Next table t2 also i inserted some data 9:36 as DateFor,Sachin as OperatorName and another one field 9:55 as DateFor,Sachin as OperatorName.

Table Name:-t1

DemoDate AuthoBy
9:30 Sachin
9:50 Vinod
10:05 Sachin

Table Name :-t2

DateFor OperatorName
9:36 Sachin
9:55 Sachin
10:00 Sachin
10:06 vinod


I want to answer just like

DemoDate
9:30t1
9:36t2
9:50t1
9:55t2
10:00t2
10:05t1

I get values from union query but i want to answer as field value and also table name from that table get value.so please give me information how to solve this problem as soon as possible

Thanks in advanced !!
Posted

1 solution

Hi,

You can use MySQL's CONCAT function to add table name. Link: MySQL CONCAT Function[^]

Please let me know if you need further assistance.
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900