Home All Groups Group Topic Archive Search About

ADO.NET

microsoft.public.dotnet.framework.adonet
Score ADODB AppendParam problem??
Ekempd - 26 May 2006 9:47 PM - 2 messages
Hi, here is my code: cmd = New ADODB.Command If cnxIQ.State = 0 Then     cnxIQ.Open() End If cmd.let_ActiveConnection(cnxIQ) cmd.CommandText = strProcedimiento cmd.CommandType = adCmdStoredProc cmd.Parameters.Append(cmd.CreateParameter("@param1", adInteger, adParamInput, , 200506)) rsResultado = cmd.Execute //Here raise an exception ...
Score SQLXML and XSL and VB.NET
klj_mcsd - 26 May 2006 8:32 PM - 1 message
I can find an example on how I call a stored proc and return XML and attach a stylesheet to it and render the HTML to the page using vb.net. I would like to display reports this way. If there is a simpler way to ...
Score Easiest Way To Point To New Database, I Created Data Source And Connection to It, Then Dragged Table
clusardi2k - 26 May 2006 6:52 PM - 19 messages
Hello,    I completed an application as described on the subject line. Now, I have to delete my DataGridView, re-create the DataSet, TableAdapter, BindingSource, and BindingNavigator. I have to set all the properties also that I liked.   What is an easier way to do all this? Do you have a simple simple ...
Score ADO to ADO.NET 2.0
steve - 26 May 2006 3:08 PM - 9 messages
We're beginning a major rewrite of a VB6 application that currently uses ADO and an Access database.  In this application, we routinely query  multiple table through JOINs and place the result in a single connected record set ...
Score Re: C# dataset to database column types
jmbledsoe - 26 May 2006 2:24 PM - 1 message
Is your Fill operation creating the table on the fly, or are you creating the table structure (by making a typed dataset, or manually) and then filling it?  If you're pre-creating the structure, you just create a column of type string, and it should fill fine.  Updates ...
Score Strongly typed dataset + Generic provider ?
Rickard - 26 May 2006 1:17 PM - 2 messages
I have designed some datasets using VS2005 by dragging in tables from a SQL2000 server. When I look at the generated code, it references the SqlClient provider in many places (for example, the command objects and the mappings of datatypes). ...
Score DataColumn.Expression formatting
magne - 26 May 2006 12:06 PM - 3 messages
I need a calulated field which formats an integer (another column in the same row) to a certain number of digits (leading zeroes). How to specify the DataColumn.Expression property for this ? ...
Score Isolation Level, generating sequences
MarkH - 26 May 2006 9:30 AM - 2 messages
We're using ADO.NET and SQl Server 2K. I'm updating an integer column in a seperate table which I use to hold sequence numbers for different reference strings. Together the string and int form a unique code which is we use as user ...
Score Could not find installable ISAM.
Dan - 26 May 2006 8:34 AM - 4 messages
Hi, My global.asax contains this: Sub Session_Start(ByVal sender As Object, ByVal e As EventArgs) Dim oConnection As New OleDbConnection() oConnection.ConnectionString = System.Configuration.ConfigurationManager.AppSettings("newres") oConnection.Open() Session("oConnection") = oConnection End Sub My web.config contains this: ...
Score myListbox.SelectedIndex = -1 Microsoft bug !
dee - 26 May 2006 1:30 AM - 1 message
Hi when I have the following line:     myListbox.SelectedIndex = -1 When I set a breakpoint and step into the code right after this line gets executed the watch window shows     myListbox.SelectedIndex = 0 I read somewhere that calling the line twice will work: ...
Score Provider not specified, Provider keyword
jduhler - 25 May 2006 9:54 PM - 1 message
When I attempt to make an OLEDB connection to Oracle I receive: An OLE DB Provider was not specified in the ConnectionString. An example would be, 'Provider=SQLOLEDB;'. Once I add the Provider=msdaora or Provider=OraOLEDB.Oracle then it ...
Score Asychronous ADO.NET , NOT
David Rigler - 25 May 2006 8:24 PM - 4 messages
SQLconn = new SqlConnection(dbConnectionString); has async=true    SQLconn.Open(); // SQLcmd = new SqlCommand(SPName, SQLconn); SQLcmd.CommandType = CommandType.StoredProcedure; SQLcmd.CommandTimeout = 0; // And start executing IAsyncResult iaR = SQLcmd.BeginExecuteReader(); waitHandles[SQLEVENT] = iaR.AsyncWaitHandle; int index = WaitHandle.WaitAny(waitHandles); ...
Score Connection.State in VS2005
Rich - 25 May 2006 6:42 PM - 6 messages
Hello, I am just checking if VS2005/VB2005 automatically opens and closes sqlConnections for you.  I noticed that if I just invoke the connectin conn = new SqlConnection conn.ConnectionString = "..." cmd.Connection = conn .... dataAdapter.SelectCommand = cmd dataAdapter.Fill(ds, "tbl1") ...
Score When comes time to save to multiple table handling many relations...
marty - 25 May 2006 6:36 PM - 4 messages
Hi, We are working at building a web application using a SQL server database.  This DB already contains many tables and many relations ( "one to many" and "many to many"). How should I develop the "write to database" layer in order to make it ...
Score How do I accept changes on only merged rows in dataset
jj - 25 May 2006 3:37 PM - 1 message
I have two DataSets, and want to merge a subset of the rows from one to another.  When the array of rows are merged into the existing DataSet, they take the RowState from the first.  Is there a way to accept ...
Score OleDbConnectionStringBuilder and .Net 2.0 Datasets
DEWright_CA@online.nospam - 25 May 2006 3:29 PM - 8 messages
I have a set of datasets that I build in 2.0 that reference a Settings/Connection string called, name="PDS.LSS.Properties.Settings.StateConnectionString". I have a method that allows my users to either create a new MDB or select a ...
Score OleDbParaneters & the DateTime Type
Alex Maghen - 25 May 2006 2:33 PM - 8 messages
I'm writing data to an Access database using OleDb stuff. Everything works fine except when I'm working with dates. Here's what happens: If I write UPDATE SQL with an "@SomeDateTime" parameter and then I create an OleDbParameter object and I set it's Name field to @SomeDateTime and it's ...
Score Excel to Dataset
Baren - 25 May 2006 1:05 PM - 2 messages
Hi! I have Excel file as the DataSet for my application, which the user uploads and the same is stored into the database. The problem is that user put varied worksheet names for their worksheet. So, how can we read the data from the ...
Score [VS2003] Updating table - how to do that ???
Pascalus - 25 May 2006 11:14 AM - 7 messages
Hi there! I've parsed the posts in this thread but haven't found answers to my problem. It drives me nuts. I'm newbie at Database app under VS2003 and for now I only do simple things. I fill a table with hundreds of records. I can see the result in a DataGrid. ...
Score Exprression Field can't display in GridView
ad - 25 May 2006 10:55 AM - 1 message
I am using the new feature of TableAdapter of VS2005. I add some expression in the DataTable, for example, I add a LongName into the DataTable of Cusotmer, with the expresson FirstName+LastName. The Long name display on when I preview the data in desgin time, but vanish ...
Score DBNull issue
DG - 25 May 2006 7:11 AM - 2 messages
I have my object containing datarow and exposing properties: e.g.: public int Price {     get{             return _myRow.Price;         }         set{ ...
Score Exceptions from SQL Server 2005
Sanjay T - 24 May 2006 9:56 PM - 2 messages
Hi, We are using ASP.Net 2 and SQL Server 2005. We are storing sessions in the database. From time to time we get the following exception in the application while the ASP.Net session tries accessing the database. This also happens ...
Score how to handle COM control event in .NET app?
dee - 24 May 2006 8:40 PM - 1 message
Hi Does anyone know how to write a callback function to handle an event generated from an old COM control in a VB.NET application? Specifically I'm using the MCI control from VB6 and want to handle the MCI_NOTIFY message. ...
Score ASP 2.0 Gridview vs. DataGrid
maflatoun - 24 May 2006 7:55 PM - 2 messages
Hi everyone, I know when you enable paging in a datagrid the entire data is read but only the data that you want is displayed to the end user. Has this changed for Gridview? So if you have 10000 records and you only want 20 ...
Score NULL Date Fields in OleDb Calls
Alex Maghen - 24 May 2006 6:49 PM - 2 messages
Hi. I'm using Command.Parameters.Add() to add parameters to a SQL query that updates an Access table. When I want to pass a NULL value parameter for a DATE column, I'm getting a runtime error that says that there's no default value set for the parameter, ...
Score Editing WebForm Data
Joe Delphi - 24 May 2006 6:33 PM - 3 messages
Hi,         I am having trouble editing bound data in a webform.  My textbox is bound to an underlying dataset.  The dataset is filled with a single record during the page load event using the Fill() and DataBind() methods.    The ...
Score Char vs. Nchar column datatypes for strings
kaumil - 24 May 2006 6:08 PM - 2 messages
Is it advisable to use nchar columns instead of char columns as indices would not be used when parameterized queries are used by the application which are always unicode based? Please advise. Thanks ...
Score Datagrid Questions
Vayse - 24 May 2006 4:49 PM - 2 messages
I wish to do a grid of sales per quarter by Salesman. So, layout like this: SALES PERSON    Q1      Q2     Q3    Q4 John                            5        6        7        8 ...
Score Meet up at Tech Ed 2006 ?
jonathan.m.bruce@gmail.com - 24 May 2006 2:29 PM - 1 message
Hi All, We are putting together a gathering of ADO.NET, and data connectivity lumaries for an informal gathering during TechEd 2006. This will be an opportunity for everyone who lives and breaths data connectivity, ADO.NET and who is looking to get a first hand feel of everything on ...
Score how to fetch a particular field in a dataset?
a - 24 May 2006 1:57 PM - 5 messages
Hi, The dataset is filled with the queryresult like this: sda = New SqlDataAdapter(sqlstring, ConnectString) dt = New DataSet() sda.Fill(dt) Is it now possible to fetch a particular field of a particular record, like SqlDataReader and the GetValue() method? ...
Score Parameter Problem
Valhalla - 24 May 2006 1:52 PM - 1 message
i'm trying to write a simple code but i can't handle a problem. I create a dataadapter,dataset and sqlconnection with wizard. My selectcommand : this.sqlSelectCommand1.CommandText = "SELECT serCod, serName FROM Service WHERE (serCod LIKE @Param2)"; In buttonclick event i'm passing the parameter to this command : ...
Score Connection Pooling problems
Rowland Shaw - 24 May 2006 11:23 AM - 9 messages
We've been seeing a number of problems regarding connection pooling in an application we've written in -house here -- we're getting the dreaded: "The timeout period elapsed prior to obtaining a connection from the pool" (connecting to SQL Server 2005, from 1.1 Framework application) ...
Score Any way to speed up this Access DB process?
Hexman - 24 May 2006 5:44 AM - 12 messages
Hi all, I've written a vb.net 2005 app that uses an Access 2000 db.  There are 2 tables used in this particular procedure.  Table 1 has 9,870 "transaction" rows.  Table 2 is like a "master" table and has 15,000 ...
Score DataRowView changes when DataView re-ordered
IraG - 24 May 2006 12:57 AM - 8 messages
Say you have a sorted DataView, and create a DataRowView that points to a particular row in this DataView. If you edit the DataRowView and change its contents so that it re-sorts into a different position in the DataView, the result is that the ...
Score SqlBulkCopy permissions
Bryce K. Nielsen - 23 May 2006 11:26 PM - 7 messages
We're using SqlBulkCopy for some large data migration routines, but the DBA does not want to grant anything to our user account except the bare minimum needed to execute SqlBulkCopy. There's nothing in the Help file about required permissions, but reading online, it looked like you need INSERT on ...
Score Weird behavior when calling function
Peter Afonin - 23 May 2006 11:11 PM - 5 messages
Hello, I have a weirdest issue I've ever had. I have a function that enters some data into the Oracle table and returns the sequential row number for the new record (autonumber):   Private Function AddSystem(ByVal txt As TextBox, ByVal cn As ...
Score How to new a DataRow ?
ad - 23 May 2006 9:33 PM - 5 messages
I am using the new feature of TableAdapter in VS2005. I want to new a typed DataRow, I use the codes: System.Data.DataRowBuilder rb;   MyDataSet.myRow rowMine = new MyDataSet.myRow(rb); But it failed. How can I new a DataRow? ...
Score ASP.Net confusion between 1.1 and 2.0
Brent - 23 May 2006 9:33 PM - 5 messages
Ok guys/gals i have the task of upgrading a app at work from asp.net 1.1 to 2.0. Since ive only worked with .Net briefly and asp.net once i need a little help here. I have been googling around and really haven't got the ...
Score Any book about writting secure ADO.NET code?
Walid Magd - 23 May 2006 7:11 PM - 1 message
I remember seeing it online, the book itself was available online not just an ad about it. Does any one knows any thing about it? ...
Score DataSet Updates to/from Sql Server
Todd Clark - 23 May 2006 6:39 PM - 2 messages
I'm creating a simple VB.Net application that uses a DataGridView in a form to show records originating in a Sql database. I have two questions related to keeping the data current and synchronized between the DataGridView and the ...
Score datasource and binding question
WebBuilder451 - 23 May 2006 6:26 PM - 1 message
I think this should be possible, but can't seem to figure out how to do this. i create a webform with three text boxes and  buttons (4) I create a datasource by dragging and dropping it onto the form. I configure ...
Score two simple questions about dataset
Dan - 23 May 2006 5:13 PM - 2 messages
Hi, 1) In the code below, when i do: d.Fill(ds,"anything") it works just as: d.fill(ds) Why? 2) What do i get with:  x = d.Fill(ds) ? (actually, i get 39, but this is not the amount of records) ...
Score support for mp3?
dee - 23 May 2006 3:45 PM - 6 messages
Hi Is there support for playing mp3 in dotnet windows application? Thanks dee ...
Score Need help for COM working from .NET Web app, but not working from .NET EXE app
JeffQ888 - 23 May 2006 3:38 PM - 1 message
Hi, I am currenly buliding a .NET app based on a third party software. Since the third party software was implemented using COM technology, I am using .NET TlbImp utility to wrapper COM dlls, then I can use them in my .NET application. However, those ...
Score typedataset not defined in System.Data.OleDb?
Dan - 23 May 2006 3:24 PM - 2 messages
Hi, I try to use dataset with OLEdb Access, but dataset is not defined (asp.net 2.0) when using VWD. Imports System.Data.OleDb Dim a As GridView         Dim d As OleDbDataAdapter ...
Score Deploying SQL in VB applications
Brashen - 23 May 2006 2:43 PM - 4 messages
Ok ok This is more than likley and OLD question but I've gone through msdn, the sql server sites and am no further forward. I use SQL 2000 developer edition and VS2003 (I have SQL 2005 developer but not installed yet) I have a ...
Score VS.NET 2003, ADO.NET 1.1 and Access 2000: Getting a Concurrency violation
Rod - 23 May 2006 2:08 PM - 1 message
I have written a Visual Studio .NET 2003 app, using ADO.NET to retrieve several hundred records out of an Access 2000 database, and putting them all into a DataSet.  Then my app goes against a SQL Server 2000 database, ...
Score Using Visual Basic And Crystal Reports, How To Count Number Of Database Sales To A Customer
clusardi2k - 23 May 2006 1:36 PM - 2 messages
In Visual Basic using Crystal Reports, how do I count and display the number of times a specific column item repeats. For example, how do determine and display how many times I sold to a specific customer? Thank you, Christopher Lusardi ...
Score Dataset to Dataset synchronization
Brad Simon - 23 May 2006 1:31 PM - 3 messages
This should be easier than I am finding it (maybe) I have 2 databases (one external, and one internal) they have identical tables, fields, etc.  Completely identical.  We cannot access the external SQL server directly, so we built web services to return the datasets of the ...
Score Don't Want To In Visual Basic Hard Code Complete Connection Path To Database
clusardi2k - 23 May 2006 1:23 PM - 5 messages
When I create a connection to a database do I have to use the complete path to the database. E.G.: ACCESS.C:\Documents and Settings\Christopher\Desktop\TEST\Test_database.mdb I developed the VB application on my PC, and would like to give it to ...
Score Storing a stream in db...
basulasz - 23 May 2006 1:15 PM - 4 messages
I have a stream data of type System.IO.Stream. I want to strore in in db. Is this possible? If yes, how can i do that? Thanx ...
Score How To Only Read/Write-To Database Via Visual Basic Application
clusardi2k - 23 May 2006 1:10 PM - 2 messages
I have a Visual Basic application which requires entering a user ID and password to use the rest of the program. After entering the correct password, the user can update the database (Only one database is ever used) using VB. The question is what is an easy way to protect the ...
Score Best way for stepping through rows
Vayse - 23 May 2006 10:55 AM - 5 messages
I have a Datatable, dtCustomers. It has several fields. I need to loop through it, passing only the Customer Code to another function. Function name is CalcVat. Does looping through rows have a memory overhead? As in, which is better: ...
Score DataView as DataSource
Ant - 23 May 2006 7:55 AM - 7 messages
Hi, I'm using VS2003. I am trying to use the FindRows method to create something with the returned rows that I can use as a datasource for a list box. I am storing the returned rows of the FindRows in a DataRowView array. What can i ...
Score Users and authentication
mrajanikrishna - 23 May 2006 7:50 AM - 3 messages
Hello friends, I am new to dotNETand familier with classic ASP. I've one doubt regarding users. I am developing an application. In which i want to authenticate users and logged in which is valid. I've read that ASP.NET authentication is ...
Score Using SQL Server temp tables with ADO.NET Datareader
damianm - 22 May 2006 11:16 PM - 2 messages
Hi, I have a stored procedure which produces the final result set is in a temporary table (single #) of SQL Server 2000. I use a DataReader to read the data from this temporary table. Am i correct in saying the temp table wont go out of scope until I have read ...
Score Access (jet) vs SQL Server Express
JBoeker - 22 May 2006 6:44 PM - 4 messages
I need to decide which database product to use for a new C# project, Access (jet) or SQL Server Express.  The project is single user; I've used Access before in similar projects and it works OK but I'm tempted ...
Score DataTable.Select(filter) Parameter too long?
Filipe Correia - 22 May 2006 6:32 PM - 12 messages
Hi all, I've found something that I think might be a bug in the DataTable implementation. I'm getting a StackOverflowException when executing the following method, using a string parameter 64254 characters long: DataTable.Select(string filterExpression) Does anyone confirm this is a bug in DataTable.Select()? ...
Score UPDATE Problem
Joe Delphi - 22 May 2006 5:17 PM - 4 messages
Hi,           I am using ADO.NET 1.1 and am attempting to UPDATE a record in the Access database.   Problem is that the statements execute fine with no error, but when I look at the database I see that the update did not really ...
Score data updating from dataset to database problem
Pure Heart - 22 May 2006 4:45 PM - 1 message
hi i use VS 2005, to develop data application, i make a connection then make a data source using this connection, then i drop a table from the dataset that is generated on a form, every thing is ok and done for me, but when i run the ...
Score Transaction for TableAdapters
DG - 22 May 2006 3:01 PM - 2 messages
I have two SqlTableAdapters (for typed dataset, generated by VS) and want to do update of tables. In transaction of course. How to do it? i try: SqlConnection conn = new SqlConnection(Global.ConnectionString); DSTableAdapters.Table1Adapter ta1 = new DSTableAdapters.Table1Adapter (); DSTableAdapters.Table2Adapter ta2 = new DSTableAdapters.Table2Adapter (); ...
Score Novice: How To Create, Display, And Print An Access Report With Visual Basic 2005
clusardi2k - 22 May 2006 2:08 PM - 8 messages
Hello, having never used CR before, I have an Access database with one table that I use with VB. How do I print and view a report of this table? Is there any step by step documentation on the Internet? ...
Score Multi-threaded apps and data readers
Smokey Grindle - 22 May 2006 12:54 PM - 6 messages
Say I have the code provided below Dim connection As DbConnection = New SqlClient.SqlConnection("Data Source=DEVELOPMENT;Database=BENE_Development;Trusted_Connection=True;") Dim dt As New DataTable Dim cmd As DbCommand = connection.CreateCommand cmd.CommandText = "SELECT AccountName, accountid from accounts" cmd.CommandType = CommandType.Text ...
Score query DataSet
DG - 22 May 2006 11:24 AM - 7 messages
I have a copy of DB in my dataset (just rows that i need ofcourse). I'd like to create a view. (connectiong tables via Foreign Keys, and getting columns that i want) Is there a way to query dataset, or should i go to database for that. ...
Score ADOX: how to get true ordinal of Excel Table
mackey.tim - 22 May 2006 10:16 AM - 3 messages
hi, i am importing excel data through a web form, using ADOX. i only want to grab the first worksheet, but unfortunately if the user re-arranges the worksheets in the excel file, the ADOX Catalog.Tables collection still presents the tables in the original order of the ...
Score OleDbSchemaGuid.Views, rewrite the view?
Edwin Knoppert - 22 May 2006 9:14 AM - 3 messages
I finally managed me a datatable with the queries. DataTable views = oConn.GetOleDbSchemaTable(OleDbSchemaGuid.Views, new object[] { null, null, null }); this.GridView1.DataSource = views; this.GridView1.DataBind(); Is there a way i can update the VIEW_DEFINITION field in a single row (= 1 ...
Score Order of events, databinding, and UserControls
Nathan Sokalski - 21 May 2006 7:34 PM - 10 messages
I have a very simple UserControl which contains an Image and a Label, which I use to display an image with a caption. I am using this control inside a DataList, setting the two Public variables using attributes in the *.aspx ...
Score CRUD on parent/child rows in a typed dataset
mike - 21 May 2006 5:55 PM - 5 messages
i am new to ADO.NET! i have created a typed dataset with parent and child types. is there a straightforward way to load parent records and have child records load automatically rather than manually loading tables using Fill method ...
Score Typed dataset - how to I alter SelectCommand
DG - 21 May 2006 4:35 PM - 7 messages
Hi, Can anyone advise how I alter the SelectCommand in an auto-generated typed dataset programmatically?  The select command would be part of a search condition built by user inputs in the GUI. Thanks, DG ...
Score DataSet nested relations
Vad - 21 May 2006 11:12 AM - 8 messages
Hi, all. I'm trying to set relations between two DataSet tables. The problem is, that the key of the parent table has more columns than the child table, something like this: ParentTable(id, name, amount) ChildTable(id, name) So I can't relate the column "amount" to any column of ChildTable. ...
Score Cannot make a Web Reference to Web Service created (HTTP Endpoint) on SQL 2005 stored procedure
tovbinm - 21 May 2006 8:17 AM - 1 message
I failed to make a Web Reference to SQL 2005 HTTP endpoint for stored procedure, It works fine only on locahost. Whan i surf or make a web reference in VS2005 to http://locahost/TestWS?wsdl - i get the xml. ...
Score Determining whether the current item is the last one from inside ItemDataBound
Nathan Sokalski - 21 May 2006 2:17 AM - 6 messages
I have a control that I want displayed in all items except the last one. I figured the best way to do this was to determine whether the current item was the last from within the ItemDataBound event using code such as the ...
Score DataList.DeleteCommand event is not getting fired
Nathan Sokalski - 21 May 2006 1:37 AM - 5 messages
I have a DataList that has an Button as one of the controls in it's ItemTemplate. The Button has a CommandName="delete" attribute, but when I click it the DeleteCommand event doesn't even get fired. I have checked ...
Next »