473,473 Members | 1,552 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

using oracle with master/detail asp.net ?

I have created a master/detail asp.net page using detailview control and
gridview control, out of which detailview is editable.

I have created a dataset using Oracle Connection and I want to display
Product Name Column besides its Product ID Column.

If I use a sub query as recommended by Microsoft in of Oracle in dataset, it
gives error.

Select productID,price,amount
(Select productName from Products
where productID=A.ProductID) ProductName
from Invoice A

However, if I run the same query using Sql Server, its acceptable by
Dataset, any idea please ?

Please note, I want this query so that I can generate Insert,Update
Statements to update the records, thats why I am not using the Joins.

Best Regards,

Luqman


Feb 27 '07 #1
5 1809
Select productID,price,amount
(Select productName from Products
where productID=A.ProductID) ProductName
from Invoice A

try this

Select productID,price,amount , (Select productName from Products
where productID=A.ProductID) as ProductName
from Invoice A
Lenny
Feb 27 '07 #2
Your query gives following error, if I use Oracle.

Generated SELECT statement.
Error in SELECT clause: expression near 'SELECT',
Error in SELECT clause: expression near 'FROM',
Missing FROM clause.
Unable to parse query text.

However if I copy and paste the same query in Oracle Sql Plus, it runs
fantastic, I don't understand why Dataset not accepting it.
Even after typing the query in Dataset, it successfully runs in Query
Builder when I click on Execute Query Button.

Any idea please ?

Best Regards,

Luqman

"Lenny" <no****@la.dicowrote in message
news:uz**************@TK2MSFTNGP02.phx.gbl...
Select productID,price,amount
(Select productName from Products
where productID=A.ProductID) ProductName
from Invoice A


try this

Select productID,price,amount , (Select productName from Products
where productID=A.ProductID) as ProductName
from Invoice A
Lenny

Feb 27 '07 #3
However if I copy and paste the same query in Oracle Sql Plus, it runs
fantastic, I don't understand why Dataset not accepting it.
Even after typing the query in Dataset, it successfully runs in Query
Builder when I click on Execute Query Button.
are you pasting the code into the gridview wizard ?
I had the same problem.
if it's this issue, paste a simple query in the wizard and then go into the
source code to edit it with your query.

Lenny

Feb 27 '07 #4
Hi Lenny,

I am not using the gridview wizard, I dragged the table from Server Explorer
into Dataset Designer, right click on TableAdapter fill,getdata method,
click on configure and create the query.

I think oracle.net Provider is not supporting this type of query.

Best Regards,

Luqman

"Lenny" <no****@la.dicowrote in message
news:9D**********************************@microsof t.com...
>
>However if I copy and paste the same query in Oracle Sql Plus, it runs
fantastic, I don't understand why Dataset not accepting it.
Even after typing the query in Dataset, it successfully runs in Query
Builder when I click on Execute Query Button.

are you pasting the code into the gridview wizard ?
I had the same problem.
if it's this issue, paste a simple query in the wizard and then go into
the source code to edit it with your query.

Lenny

Feb 27 '07 #5
I am not using the gridview wizard, I dragged the table from Server
Explorer
into Dataset Designer, right click on TableAdapter fill,getdata method,
click on configure and create the query.

I think oracle.net Provider is not supporting this type of query.
I do not use dataset and objectdatasource. I had some difficultes too with
oracle.
try to use sqldatasource instead of datset.
edit the selectcommand in sqldatasource with the complex sql.

Lenny

Feb 27 '07 #6

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

Similar topics

133
by: jonathan | last post by:
hey all, I realize that this question might pop up from time to time, but I haven't seen it a while and things might of changed, so - Right now (July 2004) how does mysql stand up in...
2
by: ruca | last post by:
Hi, I have a master and a detail datagrid. I put detail grid showing insise of a column of master grid. The problem is that it's not what I really want. What I really want would be that the...
3
by: Brian H | last post by:
I am looking for working examples of making use or 2 datagrids and one dataset Grid 1 master Display minimul info Grid 2 slave. Disply detail info When the user clicks a row on the master I...
2
by: Ken C | last post by:
I've setup a Master detail table from a typed dataset on 2 different data grid The first one I bind it with the Master data table name The second data set I bind it with the MasterDetail...
2
by: Coen | last post by:
Hello, I have a strange performance delay of about 2 sec's in moving to the next row. I use multiple forms with each master-detail table relations. The master-table displays it's table rows in...
3
by: fstenoughsnoopy | last post by:
Ok the complete story. I have a Contact Table, Query and Form, that are used to input and store the contact info for customers. They have FirstName, LastName and Address as the primary key...
0
by: Sam | last post by:
Sorry to post the same post multiple times but the URL Addresses were not Correct in Earlier Posts. Here are the correct URL's: 1) Run It URL is here: ...
4
by: gene kelley | last post by:
I had a VB6 app that used a third party ListView control to simply display various recordsets. The control had a VirtualMode which I used for this display. Now in VB2005, I want to do the same...
2
by: John | last post by:
Hi I am trying to create a master/detail form. I have my master and details tables dragged onto the dataset. I have also dragged the fields from master table on the form which has created the...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
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,...
0
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...
1
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...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

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.