Home All Groups Group Topic Archive Search About

ADO.NET

microsoft.public.dotnet.framework.adonet
Score How to tell the version of SQLServer2005Express
ad - 20 May 2006 9:30 PM - 2 messages
How can I tell the version of SQLServer2005Express if it is SP1? ...
Score Geting tables from an MDB file
Paul Wardle - 20 May 2006 8:47 PM - 2 messages
I am using .Net 2.0 - how do I get the available tables froma MDB file? I tried: DataTable dt = connection.GetSchema("Tables"); But this returns system tables, as well as the tables I need. How do I restrict this? ...
Score How to use one database connection object per page request
Arsalan Ahmad - 20 May 2006 4:20 PM - 7 messages
Hi all, I am creating a website in which in an Item detail page there are a number of web controls (7 or 8) and what is happening that inside each of control's Page_Load() function I am creating a database object to query data from ...
Score Typed datasets - breaking into the black box
DG - 20 May 2006 4:00 PM - 1 message
Hi, I use stored procedures to query and update a database. These are highly customised working with an MS Access front end I developed for them 2 years ago. Now I'm learning C# 2005 to put a more robust front end to the application ...
Score odbc works in one application, not in another
Ben - 20 May 2006 1:09 PM - 4 messages
Hi, I made two rootapplications with VWD under IIS 5. I installed ODBC.net connector from Microsoft and Myodbc 3.51 from Mysql. The same files (test.aspx and test.aspx.vb) has been copied in both rootapplications. In the first rootapplication, it works. ...
Score require help
shree - 19 May 2006 9:21 PM - 1 message
I need to retreive data from different tables say tab1,tab2,tab3 for each id value (tab4.id) in tab4 and get the whole result set into refcursor which is to be passed as an out parameter in a stored procedure and further to a .net ...
Score require help
shree - 19 May 2006 9:20 PM - 1 message
I need to retreive data from different tables say tab1,tab2,tab3 for each id value (tab4.id) in tab4 and get the whole result set into refcursor which is to be passed as an out parameter in a stored procedure and further to a .net ...
Score SqlBulkCopy to not insert IDENTITY field
Bryce K. Nielsen - 19 May 2006 8:51 PM - 6 messages
I'm using SqlBulkCopy to copy over data from one table to another, BUT I don't want the Identity field to be copied, and rather want the new server to auto-generate the identity values. What's the best way to accomplish ...
Score Sqlparameter with "IN " sintaxe
João Santa Bárbara - 19 May 2006 4:41 PM - 9 messages
Hi all i have this query . Ex: "Select * from tblMove Where ID IN (1,2,3,4,5)  and i want to replace the "1,2,3,4,5" with a parameter. is it Possible ?! thlks JSB ...
Score Insert Problem
Joe Delphi - 19 May 2006 4:12 PM - 3 messages
Hi,        I am attempting to do an INSERT operation using the OleDBCommand object.   I am receiving this error message:        "Object must implement IConvertible"        Here is the part of my code where the error occurs: ...
Score SqlDataSource
Victor Rodriguez - 19 May 2006 3:47 PM - 2 messages
Is there a way to pass a SqlDataSource from one page to another having captured data on the first one but not sent it to the server until the second page has capture some other data? thanks, Victor ...
Score CREATE VIEW error
Edwin Knoppert - 19 May 2006 12:28 PM - 27 messages
I have serious issue by inserting a query using (names are fake): CREATE VIEW Query1 AS SELECT Count(Table1.ID) AS CountOfID, Day([DatumAanmaak]) AS Dag, Month([DatumAanmaak]) AS Maand, Year([DatumAanmaak]) AS Jaar FROM Table1 GROUP BY Day([DatumAanmaak]), Month([DatumAanmaak]), Year([DatumAanmaak]), ...
Score Enumerate tables and fields by query?
Edwin Knoppert - 19 May 2006 9:33 AM - 2 messages
At [link] i don't see a way to enumerate tables (and fields). Is there way ala SQL? ...
Score sort a typed dataset table
Federico Caselli - 19 May 2006 7:52 AM - 3 messages
Hi, my application must iterate through a typed dataset  table and I should set a record-order before I itarate. I gave a look at the dataview but it seems it cannot be typed... Can you help me? ...
Score How to...?
ElHombre - 19 May 2006 7:33 AM - 2 messages
Hi! I'm new to C#. In a SQL-database I have: tblZipCodes: ZipCodeID ZipCode City tblCompanyInfo: CompanyID CompanyName Adress ZipCodeID Phone Now on the form, in C#, I'll have an extra textbox - 'city' - which will display what city after ...
Score instert into a table recursively
bonk - 19 May 2006 7:09 AM - 1 message
I have a Table that contains Items of the Type "Step". The primary key is "StepID".  Each step can have have a target step, wich represents a subsequent step. So I have a Foreign key relationship within the same ...
Score An serious bug.
ad - 19 May 2006 4:04 AM - 3 messages
I am use VS2005 to develop Web application. I put some DataTableAdapters in a ClassLibrary. When the Web Application need to deal with data, it call the methods in the ClassLibrary. It run ok in the VS2005 IDE. But when I deployment my Wep applicaotn to Web ...
Score Record Count from Data Reader
RKNET - 19 May 2006 2:04 AM - 4 messages
How to find the Record count from the Data Reader (ADO.Net) is there any way to do it without looping thru the records ? Please let me know. Thanks, RKNET ...
Score Update a Data Source by Using a Command Object in VB
clusardi2k - 18 May 2006 6:59 PM - 1 message
Hello, is there any step by step information on the Internet that says how to do it correctly? For example, how do I set up the connection string correctly and build the rest of the data command. Thank you, Christopher Lusardi ...
Score Import file into Access database
sham - 18 May 2006 6:23 PM - 2 messages
Hi to all, I need to import a file (csv) into an empty access database. If I do this manually, I would have to : 1) Open access and select get External data 2) Check delimited text 3) Then go to the next tab and select text qualifier " and click box "First ...
Score How to modify connection string at runtime for strongly typed data
BabuMan - 18 May 2006 5:59 PM - 1 message
Hi, I have been struggling for the past couple of days with this problem and I don't know how to go about fixing it.  I hope somebody can help. I have a Windows application (C#) where I have a few datasets holding quite ...
Score Need Help in how to set column sequence in a datatable.
manaleem - 18 May 2006 4:54 PM - 1 message
Hi: I am working on routine that takes in a datatable, and add extended properties to each column, by reading an XMLDocument object. The routine is currently doing a dt = source.copy, and then has a for each statement, in which extended properties are added by reading each XML ...
Score "ORA-01008: not all variables bound" OracleClient DataAdapter Update
ramsey - 18 May 2006 4:15 PM - 1 message
I am using OracleClient.  I have a dataset, a DataAdapter, and a select command.  I fill the dataset using the dataadpter (and display it in a datagridview).  I'm a happy camper. I create an update command using the following: ...
Score how to use a stored procedure?
Ben - 18 May 2006 3:49 PM - 7 messages
Hi, I want to execute a stored procedure ("myquery") in Access. I use the oledb connector.         ......         Dim oConnection As System.Data.OleDb.OleDbConnection         oConnection = New System.Data.OleDb.OleDbConnection() ...
Score ADO.NET Timeout Exception - I have tried everything
sorcerdon - 18 May 2006 3:40 PM - 4 messages
Hello! I am looking for someone who has solved this multi-million people's problem. EVERYONE seems to ahve this problem. Im a creating a data set and populating it with a call to a store proc. Its a complex stored proc with the end result as an insert to a temp ...
Score Get specific rows from dataTable using the SELECT method.
Niron kag - 18 May 2006 3:33 PM - 4 messages
I try to get specific rows from dataTable using the select method with simple criteria. For the following lines I the values of  the variables are : expression  : "Account like 6133101"        ("Account " is the name of my ...
Score Updating a dataset using SqlDependency
ChrisAtPhaseWare - 18 May 2006 3:13 PM - 3 messages
I am trying to update a DataGrid by binding to a dataset located in another class. In this class, I subscribe to a Query Notification using a SqlDependency.  In the SqlDependency's OnChange event, I attempt to merge a temporary dataset ...
Score checking if data reader is open
Smokey Grindle - 18 May 2006 2:00 PM - 4 messages
is there any way to check if a data reader is open if you dont know the original object that created it? I keep getting data reader is open errors yet I never used a data reader in this project ever... so i'm having a hard ...
Score DataReader
George Varelas - 18 May 2006 12:41 PM - 1 message
Hi. Can anyone tell me how can I get the number of rows in a SqlDataReader? There is no property like "Count" such as in an ArrayList. Thank you George ...
Score Binding Radiobutton Problem
Valhalla - 18 May 2006 11:39 AM - 1 message
Hi, I have a problem with binding. I want to bind a field in my database to a radiobutton. I achieve this with this code this.radioButton1.DataBindings.Add(new System.Windows.Forms.Binding("Checked", this.dsServis, "tableName")) My problem is: when radiobuutton's checked changed binding sets the ...
Score UPDATE with WHERE IN clause
spp - 18 May 2006 5:28 AM - 4 messages
I want to UPDATE a SQL table with a SqlCommand The Update command is UPDATE mytable SET col1 = @param1 WHERE STR(intcolumn,6,0) IN (@param2) My questions are what type of parameter should be @param2 to satisfy my update because ...
Score how to trap/deal nullRefException for cmd.ExecuteScalar w/o try-c
Rich - 17 May 2006 10:47 PM - 8 messages
Hello, 'Shmo' is a unique word in tbl1.  If it exists in tbl1, then I write it to the console. cmd.commandType = CommandType.Text cmd.CommandText = "Select fldx From tbl1 Where fldx = 'Shmo'" console.writeline(cmd.ExecuteScalar.ToString) If 'Shmo' does not exist in tbl1 - I get a nullreferenceException.  I deal ...
Score Sql Server Connection Irritations (again)
Shawn B. - 17 May 2006 8:12 PM - 1 message
We recently migrated from .NET framework 1.x to 2.0 with a code base that is 4 years old.  The application is a mix between Windows Services, Web Application, and some internal WinForms tools.  We never had a problem using ...
Score Sql Server Connection Irritations (again)
Shawn B. - 17 May 2006 8:12 PM - 18 messages
We recently migrated from .NET framework 1.x to 2.0 with a code base that is 4 years old.  The application is a mix between Windows Services, Web Application, and some internal WinForms tools.  We never had a problem using ...
Score Cannot read XML into data set
Eric - 17 May 2006 6:27 PM - 4 messages
Hello, I am trying to read in an XML file into a strongly typed data set, and I get this error:   Column name 'myColumn' is defined for different mapping types. Here is my code: myDataSet.ReadXml("myFile.xml", XmlReadMode.InferTypedSchema); ...
Score Customizing codegeneration of typed tableadapter
henk gijsbert - 17 May 2006 6:24 PM - 3 messages
I would like to inject one line of code in the update methods of generated tableadapters (to call a validationmethod on DataSets and DataTables that I define using partial classes). Can this be accomplished? (This would be nicer than having to subclass ...
Score Overlapping typed datasets in .NET2: best practices?
henk gijsbert - 17 May 2006 6:14 PM - 4 messages
Assume  I have one adressTable that is used for as well companies as persons and I have need to retrieve companies with adresses as well as persons with adresses. I could generate typed datasets, one with companytable+addresstable and one with personTable+addresstable, ...
Score Which Event Is Firing?
Joe Delphi - 17 May 2006 6:08 PM - 3 messages
Hi,         I have a DataGrid with one column defined as a hyperlink column.   I wrote a SelectedIndexChanged event handler to handle processing when the user clicks on that hyperlink.   But all I get is a 404 error -it doesn't ...
Score Parallel transactions are not supported.
Dominic Belley - 17 May 2006 4:32 PM - 1 message
Hi, In my VB.NET app, I initialize a connection when the application is loading. Case scenario here: Operation 1- I go into my "Member Management" winform and search for the Membre #2. That creates a BEGIN transaction ...calls a stored proc with (UPDLOCK) to ...
Score Need Help Using Select INTO from on mdb to another.
fracassa - 17 May 2006 4:01 PM - 2 messages
I am trying to use a SELECT INTO statment (using VB 2005) to Insert records from a "table1" in one mdb to a "table2" in second mdb located in another location. The problem is that the columns in the table2 have different names then ...
Score Get Element Value
Jay - 17 May 2006 3:41 PM - 9 messages
In a loop like so: .... xmlr=cmd.executexmlreader() xmlr.read() do while xmlr.readstate <> xml.readstate.endoffile loop How do I return each individual element name and value from a document like so: <Customer> <custno>2</custno> ...
Score Running WebMethos Fails half way thru...
Jay - 17 May 2006 3:07 PM - 2 messages
In a loop I am calling a web method 20 times and passing it a string parameter.  Even though my routine is looping all 20 times the web service is only executing 10 times... almost like my side is going too fast. ...
Score Modify ODBC DSN Properties with VB.NET Code?
zacks - 17 May 2006 3:04 PM - 2 messages
I have a single ODBC DSN that I have to change the default database frequently. Is there a way I can change that property from VB.NET code? Sure would make the process simpler than going through the setup wizard ...
Score XML From Stored Proc
Jay - 17 May 2006 12:22 PM - 5 messages
In VB.NET (Studio 2005) I need to loop thru a result set returned from a stored proc and generate XML for each row.  E.g.  exex procWhatever returns: custno, lname, fname, address 2, Doe, John, 123 4th St. ...
Score Please help me.....!
anoashu - 17 May 2006 11:57 AM - 1 message
HI...... Am getting following error when am reading some XML Data From the Stored Procedure. The GetString() function of DataReaded is working fine with SQLClient provider and its getting data , But i tried with the same in OleDB its not working.. ...
Score ODP.NET and System.Transaction support
joachim.hoffmann - 17 May 2006 9:53 AM - 6 messages
Hi, As for now it doesn't seam like the latest ODP.NET supports the new System.Transaction namespace. I have tried to download and install the latest beta of ODP.NET version 10.2.0.2.10 ([link]), but ...
Score How To Lock Record From Read/Write using Transactions
Scott - 17 May 2006 12:50 AM - 4 messages
What is desried, during a transaction, with its IsolationLevel set to RepeatableRead, will it block out other transactions from performing a read or write to the same record until it's transaction has completed? See code snippet below: SqlConnection connection = new SqlConnection(connectionString)) ...
Score FormView, DataSource, Update, and why it doesn't work
Shawn Anderson - 17 May 2006 12:46 AM - 2 messages
Does anyone have any suggestions on how to determine why my updates that happen inside a formview are not being saved back to my database?  I have a datasource with select, insert, and update statement (simple SQL), I am ...
Score Using 2003 Data Adapters in 2005
Paul Craig - 17 May 2006 12:26 AM - 2 messages
Hi everyone, I have recently upgraded several of my projects from Visual Studio 2003 to 2005 and everything went across quite smoothly. The main problem that I am having is I have used SQL Data Adapters on many of the forms. These forms ...
Score how to connect to multiple database?
cipcip - 17 May 2006 12:16 AM - 5 messages
Is it possible to connect to 3 database and execute a cross db query? I usually use SqlConnection(connectionString) for a single connection ...
Score Adding a NULL to an array then adding array to a data table
Fiddelm3742 - 16 May 2006 8:12 PM - 5 messages
I'm having problems adding some data to my data table where one of my rows contains a column that has a null value.  Here is a snippet of my code while ((strDataFileLine = DataFile.ReadLine()) != null) //Read till EOF ...
Score VB.NET 2003, SQL Svr 2k5, Dataset + Rowlock
Dominic Belley - 16 May 2006 5:31 PM - 6 messages
Hi, I use VB.NET 2003 & SQL Server 2005. I will try to make it simple. I have a winform which has a textbox "Member No". When the user enters a value and clicks the Search button, I call a stored ...
Score Insert whole dataset in to a db table - VB.Net 2005
Federico Caselli - 16 May 2006 4:32 PM - 2 messages
Hi, I have a very simple question. I have a typed dataset, dsOrders, bound to tbOrders Access table. Now I must write a function to copy all the records from the dsOrders to the Access table tbOrdersDone. How can it be done? ...
Score vfp Parameter - callin vfp geeks
Toco - 16 May 2006 4:21 PM - 3 messages
Hello.  I perform a search on a vfp table using select statement.  Based on the input paramter, the db engine performs a lookup by stripping the dashes (-) from the searched string.  The data in table is bad and I must remove ...
Score 'OraOps9.dll': Access is denied
SteveNH - 16 May 2006 4:20 PM - 3 messages
I am getting the above error from two machines when attempting to connect to Oracle: OracleConnection connection = new OracleConnection(connectStr); This used to work fine on one of these machines.  I always got this error on the other machine.  I have given ASP.NET and Authenticated ...
Score Saving image data
B. Mark McKinney - 16 May 2006 1:23 PM - 3 messages
I'm having trouble saving SqlDbType.Image data from a file to SQl Server. Using VB.Net 2003 and SQL Server 2000, I am attempting to use a stored procedure to save the data using the following code: Dim fi As New FileInfo(FileName) ...
Score SQL: create a table with recursive relationship
bonk - 16 May 2006 12:28 PM - 5 messages
I am fairly new to SQL and ADO.NET and I am currently trying to create a SQL table (using Microsoft SQL and ADO.NET 1.1) that has a recursive relationship, let me try to explain: I have a piece of Data let's call it "Item" wich may again contain one ...
Score SQLConnection, Please help me.
marcmc - 16 May 2006 12:15 PM - 4 messages
This is related to a post below but is a new issue. I have created a SQLDataAdaptor from the config wizard and set my SQLConnection1 in same wizard. I then gerated a dataset from my adaptor as all the notes tell you to do. ...
Score verbatim princo traxdata benq tdk imation
for your interest - 16 May 2006 4:30 AM - 1 message
<HTML> <HEAD> <META NAME="GENERATOR" Content="Microsoft DHTML Editing Control"> <TITLE></TITLE> </HEAD> <BODY> <P>verbatim <A href="[link]">[link] dvd barato dvd-r dvd+r cd-r ...
Score Run sql server 2005 backup from VB.net 2005
steve - 16 May 2006 4:26 AM - 4 messages
Hi All How do you run a backup / restore on sql server 2005 from within a VB.net 2005 application In VB6 I used an execmd routine to run OSQL in cmd shell In VB.net 2005 is there a better way to do it?? ...
Score How to close all connections of a database
ad - 15 May 2006 10:06 PM - 2 messages
I use sp_detach_db to detach a database, but it fail when threre are some connections to the database. How can I close all connections of this database before I detach it? ...
Score Paging in ADO.net 2.0 - row count in filtered dataset
Jawahar - 15 May 2006 8:37 PM - 4 messages
I am usign paging in a gird with a Dataset as the DataSource for a grid. I also apply a Filter expression to the dataset but when I dispaly the Rowcound or check "AffectedRows" I get the original Row count before I apply the ...
Score DataGrid Updates DataSet and Database (Not!)
marcmc - 15 May 2006 3:22 PM - 2 messages
Am i missing something blatently obvious? 1.) I have dragged a SQLdataConnection & SQLDataAdaptor to the screen where my DataGrid is. My DataAdaptor is configred for updates (see end of thread) and my table has a Primary Key. 2.) I have generated a dataset from my Adaptor. Everything is connected. ...
Score DataRow[] merge problem .net 2.0
juan blanco - 15 May 2006 2:42 PM - 1 message
Hi, I am currently migrating a few projects / solutions to .Net 2.0, and I have found out a problem merging an array of dataRows. On .net 1.1 a dataRow will be merged into a table on a dataSet with the same ...
Score Modifying a Dataset in VB.NET (Clarification)
Bmack500 - 15 May 2006 2:36 PM - 6 messages
I have code which needs to make several modification to data. If I set up a Dataset, fill it w/data from a data-adapter, is there any way to modify the dataset results using sql syntax? Or do I have to iterate ...
Score Structure of execution a query on dataTable.
Niron kag - 15 May 2006 1:34 PM - 3 messages
Hello! I am interested to lern how to execute queries on dataTables , in order to get a specific data ,   and - how do I keep the data I get from the query . Thanks for your help... ...
Score SqlDataAdapter Update table with AutoIncrement column
Jawahar - 15 May 2006 12:51 PM - 9 messages
I have the following code iAdapter = new SqlDataAdapter(); iUpdater = new SqlCommandBuilder(iAdapter); dsROCData = new DataSet("ROC"); SetConnection("XXXXX"); --> set the connection oCommROC = new SqlCommand(); oCommROC.Connection = oConn; oCommROC.CommandType = CommandType.StoredProcedure; oCommROC.CommandText = "GetROCFromIFMS"; iAdapter.SelectCommand = oCommROC; ifmsAdapter.MissingSchemaAction = MissingSchemaAction.Add; ...
Score DataGrid / DataSet / DataAdaptor / DataBase update issue
marcmc - 15 May 2006 12:05 PM - 14 messages
Hi, I'm using vb.net. My dataset is not updating my database after the user modifies the datagrid. I populate my data with the load sub below. In the Save Sub (below), I have generated my DataSet 'dataSet11' from my ...
Score How to text if a database exist?
ad - 15 May 2006 11:59 AM - 2 messages
How can I test if a DataBase existed in a server? ...
Score Crystal Report HTML problem
Alok Pagariya - 15 May 2006 10:33 AM - 1 message
Hi All, I need ur help for problem described below, i have a html string (In format contain HTML tags) now i want to display it in Crystal report i tried with simple string but it displaying me the whole string instead of formated output ...
Score Crystal Report HTML problem
Alok Pagariya - 15 May 2006 10:30 AM - 1 message
Hi All, I need ur help for problem described below, i have a html string (In format contain HTML tags) now i want to display it in Crystal report i tried with simple string but it displaying me the whole string instead of formated output ...
Score Crystal Report HTML problem
Alok Pagariya - 15 May 2006 10:28 AM - 1 message
...
Score Connection Weirdness
David Wimbush - 15 May 2006 8:51 AM - 4 messages
I have an application that follows this pattern every time it needs to interact with SQL Server: 1. Open a connection with a fixed connection string 2. Execute query 3. Close connection I'm expecting connection pooling to give me the same connection each ...
Score From QueryDef to plain SQL text
Edwin Knoppert - 15 May 2006 8:09 AM - 5 messages
I have a few queries in my MDB, some of them are using them as INNER JOINs. (A SELECT in a SELECT but then using querydefs) I would like to combine these SQL statements into one but they become highly ...
Score Run a SQL statement
george - 15 May 2006 1:53 AM - 3 messages
Can you run SQL statement against a datatable and if so how? Thanks ...
Score Formatting Data
noel - 15 May 2006 1:51 AM - 2 messages
Hi, I query data from a SQL db and I need to format the data to fit certain business rules (date, char length...).  Is the only way to do this is loop through the table and hard code it? ...
Score [REPOST2] SMO Table Owner
Scott - 14 May 2006 11:05 PM - 3 messages
Using SMO, how do I get a table's ower? I'm scripting out some tables to disk based on the table's name, but I'm getting a clash on the file name because the same table name exists with different owners. I want to encorporate ...
Score Schema Information for Ado.Net 2.0
Marc - 14 May 2006 9:45 PM - 5 messages
In Ado.Net 2.0 how should you get get schema information? I want to know the list of databases for a server and then iterate over that list to show the tables and schema data in the table. Thanks, ...
Score Insert Record in Windows Forms
JPADRON - 14 May 2006 7:58 PM - 2 messages
Hi, I'm using vs2005 to create an UI with an attached SQLEXPRESS database. I drop the table (detailview) to the main form and a BindingNavigator appear at the top of the form. When I run the app, everything works fine but UPDATE and INSERT records. In ...
Score Read/Write Data-Binding & StoredProcedures
Alex Maghen - 14 May 2006 2:59 PM - 2 messages
I'm trying to understand the most "elegant" way - the way that ASP.NET or ADO would suggest handling the back-and-forth between a Web Form and the database, when the data only get out of and into the database through Stored ...
Score 'MySql.Data.MySqlClient.MySqlConnection' not defined
Ben - 14 May 2006 10:05 AM - 2 messages
Hi, I try to connect to Mysql using the Mysql Connector 1.0.7. In "mysql.aspx", i put: <%@ import namespace="System.Data"%> <%@ Import Namespace = "MySql.Data.MySqlClient" %> ..... In "mysql.aspx.vb", i put: Dim oConnection As MySql.Data.MySqlClient.MySqlConnection ...
Next »