Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. XML / XSL
  4. Problem with typed datasets and column expressions

Problem with typed datasets and column expressions

Scheduled Pinned Locked Moved XML / XSL
helpdatabasexmlquestion
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    AirGuitarist
    wrote on last edited by
    #1

    I am having trouble using column expressions to return an aggregate of child rows in a typed dataset. Here is my scenario: I have two tables defined in my xsd schema: Orders and Order Details. The relevant fields are: Orders - OrderID (primary key) - Total (expression column) OrderDetail - OrderID (foreign key) - Qty - PricePerUnit - ItemTotal (expression column: Qty*PricePerUnit) my problem is that when I try to set the expression property of the Total column in "Orders" to "Sum(Child.ItemTotal)" and then run the dataset generator, I get the following error: The custom tool 'MSDataSetGenerator' failed. Unbound reference in the aggregate expression 'Sum(child.[ItemTotal])' I also get this error when referencing the foreign key constaint name: Sum(Child(FK_Orders2OrderDetails).ItemTotal)" The MSDN library says that my syntax is correct (look up DataColumn.Expression property) Any ideas? Thanks

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups