473,657 Members | 2,591 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Formatting Parent-Child data in table

Kinda new to .NET. I used to build output like this manually in ASP and I
can't find any examples of creating this with Repeater, DataList, DataGrid
etc to make it any cleaner in .NET

select a.au_lname, a.au_fname, t.title, t.price, t.pubdate
from authors a
inner join titleauthor ta
on a.au_id = ta.au_id
inner join titles t
on t.title_id = ta.title_id
where au_lname between 'M' AND 'P'

I want my output grid to be:

<tr><td colspan=3>au_ln ame, a.au_fname</td><tr>
<tr><td>t.title </td><td> t.price</td><td> t.pubdate</td></tr>
etc.

Using data from above query(This may not look right but I hope it conveys
the idea):

MacFeather, Stearns
Cooking with Computers: Surreptitious Balance Sheets 11.95 06/06/1991
Computer Phobic AND Non-Phobic Individuals: Behavior Variations 21.59
10/21/1991
O'Leary, Michael
Cooking with Computers: Surreptitious Balance Sheets 11.95 06/06/1991
Sushi, Anyone? 14.99 06/12/1991
Author3
Title Price PubDate
Title Price PubDate
Title Price PubDate
Author4
Title Price PubDate
etc
Nov 19 '05 #1
1 958
Hi Chris,

If you're looking for a hierarchical grid, a great starting place is Denis
Bauer's free control:

http://www.denisbauer.com/ASPNETCont...ierarGrid.aspx

Ken

"Chris White" <chrisjwhite@@@ mindspring...co m> wrote in message
news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
Kinda new to .NET. I used to build output like this manually in ASP and I
can't find any examples of creating this with Repeater, DataList, DataGrid
etc to make it any cleaner in .NET

select a.au_lname, a.au_fname, t.title, t.price, t.pubdate
from authors a
inner join titleauthor ta
on a.au_id = ta.au_id
inner join titles t
on t.title_id = ta.title_id
where au_lname between 'M' AND 'P'

I want my output grid to be:

<tr><td colspan=3>au_ln ame, a.au_fname</td><tr>
<tr><td>t.title </td><td> t.price</td><td> t.pubdate</td></tr>
etc.

Using data from above query(This may not look right but I hope it conveys
the idea):

MacFeather, Stearns
Cooking with Computers: Surreptitious Balance Sheets 11.95
06/06/1991
Computer Phobic AND Non-Phobic Individuals: Behavior Variations 21.59
10/21/1991
O'Leary, Michael
Cooking with Computers: Surreptitious Balance Sheets 11.95
06/06/1991
Sushi, Anyone? 14.99 06/12/1991
Author3
Title Price PubDate
Title Price PubDate
Title Price PubDate
Author4
Title Price PubDate
etc


Nov 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
3495
by: Pascal | last post by:
Hello, I've a float number 123456789.01 and, I'de like to format it like this "123 456 789.01". Is this possible with % character?
13
1972
by: Peter Diedrich | last post by:
My apologies, Spartanicus, but your layout does not work out at all. Any other suggestions how I can achieve this layout? <div> xxxxxxxxxx x x x IMG x x x x x
5
2161
by: cnu | last post by:
Hi, I have to make a formatted (indented) xml file like this : <?xml version="1.0"?> <Message> <Parent index="0" length="6">123 <Child1 index="0,1" length="6">abcd</Child1> <Child2 index="0,2" length="6">pqrsxyz</Child2> </Parent> </Message>
4
3131
by: Bradley | last post by:
I have an A2000 database in which I have a continuous form with a tick box. There is also a text box with a conditional format that is based on the expression , if it's true then change the background colour. In A2000 it works great, but in A2003 the background doesn't always change and when it does it only changes when the record looses the focus. Any way around this? Is it a bug? Or have they "improved" it?
1
4986
by: GGerard | last post by:
Hello Is there a way to use a variable in the Conditional Formatting of a Textbox? Example : I want the background of a textbox in a continuous form to change color when the value of "MyField1" is True. No problem, I just need to write "Expression is" and " = -1 "
1
2111
by: Chuck Bowling | last post by:
Up front, i'm not very good with serialization and i'm not quite sure what capabilities it has. I have an app that outputs a text file with this format: <root> \t <node1> \t\t text... \t <\node1> \t <node2>
8
1774
by: gopal | last post by:
Hi I am trying to write to log file but the formatting of string is not properly aligned in log file result The results looks some thing like this OK move.xml Successful OK AppUser_ifrUsers.asp Successful
8
8483
by: Typehigh | last post by:
I have many text fields with conditional formatting applied, specifically when the condition is "Field Has Focus". Without any events associated with the fields the conditional formatting works perfectly. However, I have code that runs under the ON CLICK event. The code changes the focus to other controls, which means the conditional formatting is no longer displayed. This part makes sense to me. Here's what doesn't make sense. The last...
4
13174
by: midlothian | last post by:
Hello, I have conditional formatting set up on a subform based on a calculated value in the underlying query. For instance, if Sales are >$1000, the query displays "Yes," otherwise it displays "No." The conditional formatting is set up to read the 'Yes' or 'No' value and color the text accordingly. I have an event in the subform that allows users to update the sales. It actually runs an update query behind the scenes. What I want to...
7
2084
by: Andy_Khosravi | last post by:
I use the formatting trick in A97 to simulate conditional formatting in continuous forms. It has, up to this point, worked fine. Today I was making some design changes to the parent form (the continuous form is a sub form within this parent form) when the formatting trick I was using stopped working. What's happening is that the character I use to 'block over' fields and make them appear to be invisible stopped displaying a solid bar...
0
8305
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8823
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8503
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8605
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7321
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6163
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4301
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1950
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1607
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.