all groups > dotnet ado.net > april 2007 > threads for april 15 - 21, 2007
Filter by week: 1 2 3 4 5
Referential update error with DataSet
Posted by Flomo Togba Kwele at 4/21/2007 9:05:52 PM
I get an error when executing the Update method on a dataset. The dataset is a
strongly typed one, with two tables in a parent/child relationship.
The parent has an identity column for its PK, while the child's PK is a
composite one. Its first column is the identity column of the parent and the... more >>
binding source position when sorted
Posted by Rick at 4/21/2007 7:43:11 AM
VS 2005
I want to make sure I have this concept down correctly.
I have a strongly typed datatable and a binding source connected to it.
On my windows form a grid is connected to the binding source.
When the grid is unsorted the datatable(bindingsource.positon).mycol =
DirectCast(bindin... more >>
Amazming....but curious...
Posted by TJ at 4/21/2007 6:06:00 AM
Hi,
Enviornment : Visual Studio .NET 2005 and SQL Server 2005
I created one stored procedure, let's say GetData()...Basically, what it
does is that it just returns data from table. (Select [A],[B] from [Test]
where id=@id..something like this...)
I created a strongly typed data set with... more >>
Vista MDAC not installed HELP
Posted by paolol at 4/21/2007 12:00:00 AM
Hi,
I have an error when I try to install a program that say "MDAC not present",
I went to the MS page and downloaded the MDAC_TYP but when I run it nothing
happen, I have Vista business with all patch, please help :(
Thanks
Paolo
... more >>
need column names from a select - may be no rows
Posted by David Thielen at 4/20/2007 8:30:00 PM
Hi;
I have a case where I have a select and I need to get the column names the
select will return. If the select will return a row I can just run the
select. But it is possible for there to be no rows and I still need the
column names. In this case Execute will return a DbDataReader with 0 ... more >>
Parameter object with return value
Posted by Norbert_Pürringer at 4/20/2007 6:15:24 PM
Hello there!
Is it possible to define a stored procedure command by adding the return
value parameter without specifying the data type? I don't really know, what
the data type of the return value is, so I prefer to get the value as
object. Is there a chance to do it?
Regards,
Norbert
... more >>
Where is the lock: on a row or a table?
Posted by Lubomir at 4/20/2007 9:24:01 AM
Hi,
I would like to ask, how SQ Server Express manage the table access:
I have two processes. What happen if one process is writing data into
table,and another process is updating data from this table at the same time.
Will be the second process allowed to access this table for reading ? ... more >>
debug breakpoint in generated tableadapter?
Posted by henk gijsbert at 4/20/2007 4:53:17 AM
Hi,
I don't succeed into debugging into generated tableadapter code.
Neither by stepping in (F11) nor by putting a breakpoint. Is this not
possible or is there something special I must do in order to debug
into tableadapter code. It is not that I want to change the generated
code, I want to ... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
Manipulating data in .NET
Posted by beschler at 4/19/2007 12:40:00 PM
I have an ODBC data source that has EXTREMELY limited SQL functionality that
I want to expose via a web service.
For example, I need to SELECT DISTINCT and teh ODBC client does not support
the DISTINCT keyword. So, in the web service I am forced to retrieve ALL
records that match the WHERE... more >>
Serialize a DataSet to a string?
Posted by Chris Davoli at 4/19/2007 8:28:05 AM
I have a dataset (with one table in it) that I want to serialize into string
data to store out on a SQL server DB. Here are my questions:
1.) Does anybody have some code that can do this? I saw there was a
serialize method that uses a streamwriter, but I need a code example. ie;
something l... more >>
insert data into Access database (could it be AutoNumber?)
Posted by Scott Starker at 4/19/2007 7:56:00 AM
This is a question from a Newbie. Although it executes correctly there is no
new record added to the table (which isn't what I want :). Could it be that
the table has an "AutoNumber" field (RecordID)? I have tried (among other
things):
SQLString = "SELECT * FROM TypeNames"
DBAdapter2 = New O... more >>
How to pass field name itself as a parameter?
Posted by Andrew at 4/19/2007 7:20:02 AM
Hello, friends,
In our c#.net app (2.0), I have an UPDATE statement like the follows for
Oracle DB:
UPDATE contract SET phone = :phone, fax = :fax, status = :status, ....(more
fields here) WHERE contractNum = :contractNum
I know I need to pass values for each parameters before execution... more >>
How does ADO.NET 2.0 DataAdapter do batch updates?
Posted by ronscottlangham NO[at]SPAM yahoo.com at 4/19/2007 6:33:03 AM
New feature in ADO.NET 2.0 is the ability to do batch updates using
the DataAdapter UpdateBatchSize property. From what I understand,
enhancements were added to the SQL Server and Oracle Data Providers to
support this. We have the need to support this directly without going
through the DataAda... more >>
SQL express and .NEt 1.1 ???
Posted by calderara at 4/19/2007 1:42:02 AM
Dear all,
I have a simple question based on accessing to SQL express 2005 throught a
..net 1.1 librrary- Does this SQLClient class is capable of accessing SQl 2005
express ?
Or do we need to use 2.0
thnaks for info
regards
serge... more >>
Quick seelct query record count
Posted by John at 4/19/2007 1:06:58 AM
Hi
I need to check if a record exists (or not) in a table for a particular id.
Is there a quick way to do this (like ms access dlookup function or
similar)?
Thanks
Regards
... more >>
How can I Do bulk update
Posted by Umeshnath at 4/18/2007 10:32:01 PM
How can I Do bulk update.
For example I have editable grid ,user is edting the grid and storing into
dataset. I have to update all the changes into DB. I need to update only the
changed records or fileds.... more >>
OT: Anyone know where I can get a Postal Job?
Posted by Eric Thompson Jr at 4/18/2007 5:59:18 PM
There is so much talk about being a Postal Employee here in the Vista group,
I was wondering if anyone had information on how one can become a Postal
Employee. That would make my Momma proud.
... more >>
Using ADO.Net to Create and Alter an Excel File...
Posted by JJDoherty at 4/18/2007 12:46:31 PM
Hi All,
I've posted this before but unfortunately I have found a solution yet
so I am hoping that someone can help.
What I wish to do is take an excel file from an end user, copy and
rename it as "backup of...". Then I want to take the original file,
delete it and create a new blank copy of... more >>
DataView to XML
Posted by Stuart Shay at 4/17/2007 9:12:31 PM
Hello All:
I want to Filter a DataView then output to XML, the problem is when I =
place a Row Filter on the DataView the changes are not applied on the =
XML output.
Thanks=20
Stuart=20
DataView oDataView =3D new DataView(oDataSet.Tables[0]);
oDataView.RowFilter =3D string.Format("Em... more >>
SqlConnection exists in both System.Data.dll and System.Data.SqlClient.dll
Posted by YodaJ007 NO[at]SPAM gmail.com at 4/17/2007 6:15:36 PM
Can anyone point me in the right direction here? I'm attempting to
compile a Windows project that consists of a single form at this
time. It's a newly generated windows project with a few controls.
Here is the compile error:
The type 'System.Data.SqlClient.SqlConnection' exists in both 'c:
... more >>
Auto-update DataGridView
Posted by Peter A at 4/17/2007 10:01:24 AM
I have a DataGridView that is bound to a BindingSource whose data source
is a table in a DataSet. The dataset is filled from an OleDBDataAdapter
which is connected to an Access database.
When a new row is added to the database, I want the DataGridView to
automatically update to show it. Is ... more >>
How To Fill Strong DataSet DateTime Column With yyyyMMDD Data Valu
Posted by twahl at 4/17/2007 9:22:03 AM
I'm reading data from a file using OleDbDataAdapter into a strongly type
dataset. One of the columns has a DataType of System.DateTime. The data
that for this column in the file is of format yyyyMMDD. When an
..Fill(dataset.datatable) is executed I receive the following exception:
'Inva... more >>
SQL issue with spaces in source name
Posted by Waxaholic at 4/17/2007 6:53:15 AM
I am using the following statement and have run into a problem when
trying to bring in a column with a space in it. I have tried using the
recommended "[" and "" double quotes but it still complains. Here is
the code.
"SELECT TIP " & _
",POS_NBR " & _
",POS TITLE " & ... more >>
ConnectionString using DSN not working
Posted by Fendi Baba at 4/17/2007 4:32:57 AM
I have been using SqlConnection .NET strings in my web,config and my
application is working finr. However due to requirements, I am forced
to change the connection string to use DSN and I cannot connect to the
data. Can anyone point out what is wrong with my settings.
Here is the SqlConnectio... more >>
Problem in inserting data into AccessDB
Posted by Elan.Hira NO[at]SPAM gmail.com at 4/17/2007 12:09:03 AM
Hi,
I am trying to insert a record to a table in my local AccessDB through
CSharp. I dont get any error when i execute the program. But after i
insert, the table is not getting updated. Below is the code which i
use to insert
private void button2_Click(object sender, EventArgs e)
{... more >>
Is it just me or have adapters taken a MASSIVE step forward in 2.0?
Posted by Richard Coltrane at 4/17/2007 12:00:00 AM
Hi,
Im just screwing around with some tableadapters in 2.0. I had tried using
adapters in 1.1 but i thought they were bloody awful truth be known. DAL
code seem to get scattered every where and they weren't very flexible.. so i
went on with hand coding all DAL.
I completely ignored table... more >>
Add DateTime value to OracleParameter
Posted by Norbert_Pürringer at 4/16/2007 7:44:40 PM
Hello there!
Why is the following use of an Oracle parameter not possible?
DateTime value = DateTime.Now;
((OracleParameterCollection)coll).AddWithValue(timestamp, value);
I get the error message "Invalid variable name!"
Regards,
Norbert
... more >>
best practise for using sql connection in c# windows application
Posted by Milsnips at 4/16/2007 4:04:43 PM
Hi there,
these are the scenarios i have come across (considering the connection pool
max=100).
1. A c# Windows app that will be used by say 1000 users concurrently.
2. A c# windows app that will be used by 20-30 users concurrently.
In a real world situation, what would be a better solut... more >>
Primary key
Posted by Lubomir at 4/16/2007 3:00:03 PM
Hi,
Some of my Tables don't have a column that could be used for a primary key
definition. All tables have indexes defined, however.
Is there any benefit to make an extra column to define the primary key, even
if I will not use this column in queries?
Thanks,
Lubomir... more >>
Where is the dll?
Posted by JimHeavey at 4/16/2007 12:42:01 PM
If I create a .udl on my desktop and configure that file to connect to the
databases, test it and it connects just fine, How can I find the name of the
".dll" which is being used for this connection?
I connect just fine using the .udl file, copy that connection string from
the .udl into my ... more >>
ADO.NET tutorial in gotdotnet/quickstart
Posted by John Brown at 4/16/2007 12:10:02 PM
Is the ADO.NET tutorial in gotdotnet/quickstart relevant to .NET Framework
SDK v2.0? Or is it a leftover from previous versions? (I do not have the
samples and the directions to getting the samples involve downloading the NET
Framework v1.0 and that is the only reference to a version on the wh... more >>
Driver Issue
Posted by JimHeavey at 4/16/2007 12:08:04 PM
I have 2 machines, each has a different version of the drivers which connect
to DB2.
I successfully connect to the database in Machine #1. I move my code to
Machine #2 and I removed the reference to the IBM DB drivers and point it to
the older version of the drivers. I know that this is tak... more >>
Factory class with ADO.NET commands containing parameters
Posted by Norbert_Pürringer at 4/16/2007 12:00:00 AM
Hallo there!
Has anyone tried to write a factory class able to create database
independent commands dealing with parameters? I need a factory supporting
OracleCommands, SqlDbCommands, OleDbCommands and OdbcCommands. Does anyone
know a good homepage representing such a factory class?
Rega... more >>
TableAdapter creates a conflict.
Posted by Richard Coltrane at 4/16/2007 12:00:00 AM
Hello.
I have a table in a db with autoincrement on for the PK field. The table is
empty.
I have used the wizard to create a tableadapter from that table. I create a
bunch of records and put them into the dataset and call Update on the
tableadapter and i get a constraint error. Column x... more >>
Dynamic linked tables in Jet databases with ADO.NET
Posted by Mark Rae at 4/15/2007 5:46:10 PM
Hi,
I've been given (i.e. lumbered with!) upgrading a VB6 desktop application to
a C# v2 WinForms application.
It's basically a reporting application which uses Jet4 as its database.
There is a single "main" backend database called Report.mdb, plus many
monthly database files called e.g... more >>
print the current time on the screen
Posted by Allen Maki at 4/15/2007 3:05:22 PM
Hi everybody,
I need help.
I want to print the current time on the screen. After research I managed to
run the codes below in regular C++. But I could not make it to run in .NET
Framework environment. Can anybody tell me how to make these codes to work
in .NET Framework or sho... more >>
Unsupported Oracle data type 100
Posted by David Thielen at 4/15/2007 12:16:01 PM
Hi;
I am getting the following on a DbCommand.ExecuteReader() using the
OracleClient:
+ $exception {"Unsupported Oracle data type 100
encountered."} System.Exception {System.NotSupportedException}
Any ideas?
--
thanks - dave
david_at_windward_dot_net
http://www.windwardreports.c... more >>
Scope_Identity returning Decimal for an Integer field
Posted by RobinS at 4/15/2007 10:32:22 AM
SQLServer2005, VS2005, C#.
I have a stored procedure that returns a SCOPE_IDENTITY after doing an
insert.
Here's the pertinent part of the SQL.
INSERT INTO PlanData
(PlanName, ...) VALUES (@PlanName, ...)
SELECT PlanID = SCOPE_IDENTITY()
PlanID is defined as an integer in the... more >>
Separate Table Adapters from DataTables
Posted by Paul Daly at 4/15/2007 9:08:03 AM
I'm trying to come up with the architecture for my senior project.
It's a web application with a SQL Server backend. I would like to use
a multi-tiered approach with the database, a data access layer, a
business logic layer and a user interface layer.
The structure of the solution is as follo... more >>
|