Archived Months
June 2003
July 2003
August 2003
September 2003
October 2003
November 2003
December 2003
January 2004
February 2004
March 2004
April 2004
May 2004
June 2004
July 2004
August 2004
September 2004
October 2004
November 2004
December 2004
January 2005
February 2005
March 2005
April 2005
May 2005
June 2005
July 2005
August 2005
September 2005
October 2005
November 2005
December 2005
January 2006
February 2006
March 2006
April 2006
May 2006
June 2006
July 2006
August 2006
September 2006
October 2006
November 2006
December 2006
January 2007
February 2007
March 2007
April 2007
May 2007
June 2007
July 2007
August 2007
September 2007
October 2007
November 2007
December 2007
January 2008
February 2008
March 2008
April 2008
all groups > dotnet ado.net > july 2006

Filter by week: 1 2 3 4 5

Column Data Type problem (ADO.NET, C#)
Posted by nvx at 7/31/2006 11:57:48 PM
Hi, I need to be able to add or remove columns from an Access database table (table is bound to a DataGridView). I know I have to use ALTER TABLE to do this. After I add a System.String column (AllowDBNull = false, MaxLength = 35) to my DataSet and a VARCHAR(35) column to the DB ("ALTER TABLE t...more >>


displaying additions upadtes
Posted by Ant at 7/31/2006 11:03:01 PM
Hi, I need to display rows that have been updated AND added to a dataTable. I can use a dataviewto filter for ModifiedCurrent or Added, but how can I combine the results so as to be able to view them all? I have also tried using a dataset that has received rows from a dataSet.GetChange...more >>

how to check programatically wether a oracle stored procedure has default valued parameters?
Posted by hiten at 7/31/2006 10:13:27 PM
I want to get the collection OracleParameter[] of all the stored procedure parameters which are assigned default values in stored proc. The way in which I was trying out was to get the parameter array with the help of OracleCommandBuilder.DeriveParameter() method. But this method only gives the...more >>

Binding to two dataviews
Posted by Ant at 7/31/2006 7:50:01 PM
Hi, Why is it that if I have two seperate instances of a DataView & use the defaultView of a table to set them, then filter each one by Rowstate in different ways for each, they are both set the same, to the last rowstate filter applied to one of them? I can get around this by using th...more >>

SqlClient Connections created don't get reused in the pool and cause error in ASP.NET Page
Posted by mc at 7/31/2006 3:23:52 PM
I have a ASP.NET app which I have recently converted from OleDB to SqlClient, however when I Get a connection, use and close it, It stays open (Process Info in Sql Server Enterprise Manager say the connection is sleeping) and very soon I hit the currently defined 100 connections limit? Wh...more >>

OleDB Exception Error codes
Posted by Reny at 7/31/2006 3:02:19 PM
Can any one list the OleDbException ErrorCodes ...more >>

DataTable, Delete, GetChanges, Merge....What's wrong?
Posted by PhilipH at 7/31/2006 2:31:01 PM
/* The following code : Creates a DataTable with four fields. Copies the table in a DataSet. Message Box displays 0 rows. Adds three rows to the DataTable Merges the DataTable into the DataSet Message Box displays 3 rows. Deletes one row from the DataTable Merges the DataT...more >>

Stored procedure w/multiple SPs - can I use DataSet Designer?
Posted by Eddie at 7/31/2006 1:38:53 PM
I've got a SP that actually executes 7 other SP's. I'd like to use the DataSet Designer to create the DAL for this app, but I'm not sure it can be done with this type of SP? Right now all I get is the initial resultset which is just authentication info. I had hoped to get a seperate DataTab...more >>



Issue SQL Statement with a DataTable in VB 2005
Posted by VTOcin at 7/31/2006 12:40:35 PM
Hi, I'm creating a DataTable from an XML file: Dim ACES_FLIGHT_SCHEDULE As New DataTable("ACES_FLIGHT_SCHEDULE") ACES_FLIGHT_SCHEDULE.ReadXml(ACES_Project_Dir + "\FlightSchedule_" + CaseYear + "_Quarter" + Quarter + "_" + SATSAirportSetName & ".xml") Then I would like to execute the follo...more >>

Setting the order of rows stored in a DataTable
Posted by TomU at 7/31/2006 11:08:02 AM
Is there a way to specify the sort order of how physical rows are stored in a DataTable? I thought specifying a primary key would define the order but it doesn't. Using a DataView every time to insure the required sorted order unecessarily complicates the code. Tom...more >>

TableAdapter.Fill() Return Value Meaning
Posted by Scott at 7/31/2006 9:43:02 AM
All, I am using a TableAdapter Fill method to return a row(s0 into a data table: int return = daMyDataAdapter(myTable, 3); Where above will fill myTable when it's index = 3; However I cannot find any documentation on what the return value is for this method. I notice when index is not f...more >>

GetInsertCommand problems...
Posted by Rob R. Ainscough at 7/31/2006 9:11:31 AM
I've noticed that the OleDbCommandBuilder.GetInsertCommand often produces incorrect syntax which will generate errors. I've had to override and provide my own commands. Specifically the GetInsertCommand seems to have issues when dealing with "reserved" words -- as in a field name "Note" -- i...more >>

DB2 ODBC
Posted by Jim Heavey at 7/31/2006 7:13:03 AM
I am trying to figure out how to construct a Connection statement for DB2 via ODBC. According to the "ConnectionStrings.com", it should have the following information. driver={IBM DB2 ODBC DRIVER};Database=myDbName;hostname=myServerName;port=myPortNum;protocol=TCPIP; uid=myUserName; pwd=...more >>

Traverse a Many-to-Many relationship
Posted by Michael D. Reed at 7/31/2006 6:26:02 AM
I have two tables in an Access database with a Many-to-Many relationship, there is a connection table. The tables are [Product Line], [Factors], and the connection table is [Product Line performance Factors] this is a standard Many-to-Many relationship in that the connect table only has two f...more >>

MS Access Update Error
Posted by Jim Heavey at 7/31/2006 5:57:02 AM
When I attempt to do an updated to a MS Access Database, I get the following Error Code returend "-2147217900". The error message says "syntax error on insert statement", but I can paste that SQL into Access and it works just fine. Research on the WEB indicates that this is a permissions i...more >>

Binding to a datagrid
Posted by Ant at 7/30/2006 10:58:02 PM
Hi, I'm using C# VS2003 I need to bind either a Filtered data view or a data set of changed rows, to a datagrid programmatically to show changed rows before updating. I can't seem to do it. The Dataset I'm copying the changes from is typed. The DataTable is DsMaster.Products; For exampl...more >>

How much is too much?
Posted by Earl at 7/30/2006 10:28:13 PM
I'm working on a project with a database normalized to 4NF. I'd like to use strongly typed datasets as much as possible on the main form, but it appears I may need as many as 20-25 data adapters. What's the best practice here and does that sound out of line? ...more >>

Handle OleDbException like Primarykey violation
Posted by Reny at 7/30/2006 12:00:00 AM
Can any one give me a clue on how to handle OleDB Specific exception .like Primary key violation I want to catch specific exception and inform the user in a friendly way that this is the error ...more >>

add with null
Posted by ad at 7/29/2006 10:17:00 PM
I have two int fields of a table: Count1 and Count2 I select with the sql: Select Count1+Count2 as CountSum form myTable When one filed have a value and the other with null, the CountSum will be null. I wnat to treate the null value as 0 int, So I want to 2+ null=2 How can I do? ...more >>

Find first record where kev value is >= search value (AS400 'SETLL')
Posted by Bishman at 7/29/2006 3:25:55 PM
Hi, I wish to read a record / records whose key value is equal to or greater than the search value, ie: If a table has ten records whose key values where 10,20,30 ..... -> 100 and I had 35 as the search value I want to position ( a cursor ? ) to before the record whose kev val is 40 and...more >>

MySQL IF() equavalent ADO.NET function
Posted by Shiplu at 7/29/2006 4:51:01 AM
hi, I am looking for a function in ADO.NET. it's like IF() in MySQL. suppose a table, [sample_table] memo, name, sex, amount 1, cust1, 'M',100 2, cust2, 'F', 200 3, cust2, 'F', 230 5, cust4, 'F', 460 6, cust1, 'M',70 In MySQL I would query "SELECT name, IF(sex='M','GUY','LADY') as typ...more >>

Expression column in typed dataset
Posted by Emma Burrows at 7/28/2006 11:08:17 PM
I have a typed dataset which imports a table from an Access database. In the VS 2005 designer, I have added a column to this table (imaginatively entitled Column1), and entered an expression using the Properties dialog. When I run any of the queries in the TableAdapter while I'm still in the des...more >>

Looking for a NOT situation (two tables)
Posted by Edwin Knoppert at 7/28/2006 2:21:32 PM
I have two tables. A main table having records, the 2nd table has only a subset of the maintable. So both tables can have records where field ID #100 exists. I'm looking for a SELECT to get the records from the main-table not found in table2. ...more >>

DateTime format is not supported in ADO.NET
Posted by Shiplu at 7/28/2006 11:24:13 AM
hi, I have a example.csv file. it looks something like this, ID,START,END,OWNER,DOMAIN 115862,7/16/2006 8:16,7/16/2006 8:16,PRIVATE,PRIVATEDOMAIN 115443,7/16/2006 3:46,7/16/2006 3:46,SKYCALL4,SKYCALLDOMAIN4 115230,7/16/2006 0:54,7/16/2006 0:54,BIJOY,BIJOYDOMAIN 114541,7/15/2006 21:21,7/15/2006...more >>

Field changes
Posted by mfleet1973 NO[at]SPAM yahoo.ca at 7/28/2006 10:13:31 AM
Hello again. vb.net 2003, mssql server... I'm using a datagrid. Users can modify information in the grid. When the user scrolls to another record, I need to detect if a field (employee) has been changed. If it has changed, the program must send an e-mail to the employee selected in the g...more >>

Query a CSV file with ADO.NET and Restriction
Posted by Shiplu at 7/28/2006 8:31:54 AM
hi, I am a newbie in this group. pardon any mistake. I am using ADO.NET to query a CSV file. my CSV file has a Schema.ini file also. Excel supprots 65535 rows. thats why I switched to CSV. is there any restriction here. I have to handle 3,600,000 rows at least Thank you ...more >>

VB Express/SQL Server/ADO.net Project Design Question?
Posted by bradmarcus NO[at]SPAM gmail.com at 7/28/2006 6:05:27 AM
18 months ago I re-wrote an entire order entry system with an Access 2002 front end (original the system was all Access) and SQL Server stored procedures for all data retrievals, updates, etct. This was to prepare for a time when I could re-write the front-end in VB.net and use all of the exist...more >>

Problem of CPU time
Posted by Samuel at 7/28/2006 12:00:00 AM
Hello, First, I have an application which display in a grid data from a table in a SQL server. When the table is modifie, a notification is sent by SQL server and I catch it to make my grid update. This works good. The problem comes when I change the table by a view. I explain: for the m...more >>

DataSet.WriteXML Vs. SQL Server 2000 XML performance issue???
Posted by manoj241176 NO[at]SPAM gmail.com at 7/27/2006 10:28:26 PM
Hi, I have concern regarding two approaches to decide, 1>DataSet.WriteXML 2>SQL Server 2000 to return XML from stored procedure. With Second approach, I have to open Cursor's and nested stored proc calls and have to create temporary tables. while in first approach I dont have to create a...more >>

DataReader to Dataset
Posted by Cylix at 7/27/2006 8:19:03 PM
Sorry for the stupid question first, I am new on ADO.NET I think one of most advantange to use ADO.NET vs ADO is the closed connection recordset, that is dataset in ADO.NET. I am using sqlcommand to execute a store procedure and return a table, and assign to a sqldatareader, but is sqldatar...more >>

can not find installable isam
Posted by bindurajeesh at 7/27/2006 6:00:02 PM
I have created a mysql database on a host server and have put webforms on the host server. I have within my code behind files the connection string for a mysql prov and when a web forms attempts to hit tables I get the above error: can not find installable isam. I have attempted to contact ...more >>

BLOB storage ADO.NET
Posted by Bala Nagarajan at 7/27/2006 4:31:22 PM
Hello, I am trying to store a binary file in a blob column of a oracle table but i get the following exception " ORA-01460: unimplemented or unreasonable conversion requested". Any insight as to why this may happen?? It seems to work fine if the data size is small (weird??). I am using...more >>

Creating a table with AllowZeroLength=True using adox in Net 2.0
Posted by Roy Soltoff at 7/27/2006 3:20:01 PM
I am porting a project from VB6 to Net 2.0. One part of the project used ADOX 2.7 to create a Jet 4.0 database and various tables. In some of the tables, there are TEXT fields that are allowed to be empty. In VB6, a statement of the form, Col.Properties("Jet OLEDB:Allow Zero Length")=True w...more >>

Feedback from stored procedure
Posted by Stephan Zaubzer at 7/27/2006 2:04:25 PM
Is there a possibility to get some feedback in ado.net when a stored procedure runs? In the sqlserver query analyzer for example all messages which are printed by a stored procedure (print statement in the sp) are shown in the messges tab of the output window during runtime of the stored pr...more >>

DataReader has Rows, but can't be read?
Posted by Bmack500 at 7/27/2006 10:50:43 AM
I have the following function, which simply fetches records from a database. I use the line "if dr.hasrows then".... continue the function. However, when I try to read a record, I get the error: "Invalid attempt to read when no data is present". I've never seen this before. I know the record is ...more >>

MARS performance articles needed
Posted by Marina Levit [MVP] at 7/27/2006 10:01:38 AM
Hi, I'm trying to do research on the implications of using MARS, how it compares to just taking advantage of connection pooling etc. I'm looking for some actual articles/whitepapers, and so on. Google has been very unhelpful in finding things specifically related to performance and/or b...more >>

Problem with updating record with objectdatasource
Posted by fig000 at 7/27/2006 9:56:19 AM
Hi, I'm new to the new asp.net :-). I've set up a web form with a grid and an objectdatasource (in my presentation layer). I have a seperate datalayer project which has webservices in it. I tell the objectdatasource what my update method is by refering to a web service method through a we...more >>

problems sending a string to execute in a stored procedure
Posted by EdwinSlyfingster at 7/27/2006 7:42:02 AM
I need pass to a varchar param of a stored procedure a list with char values separated with comma ( , ) example: '2','3','4' then, at the procedure the query make a ... in ( @param ) so in ( '2','3','4' ) the problem is the ado.net don´t permit passa quotation mark. No wonder, to saffe...more >>

SQL Backup
Posted by Raju at 7/27/2006 3:22:04 AM
Hi I want to take a back of my sql database but i dont want to take full database i want to take only 40% of the data base how to do this job pls can u tell me. Raju braju.ak@gmail.com ...more >>

How to get field value in RowEditing event
Posted by ad at 7/27/2006 12:00:00 AM
I use a GridView to link a datatable. I wnat to get some filed's value in the RowEditing event of the GridView. How can I do? ...more >>

connection timeout
Posted by mjweiner NO[at]SPAM gmail.com at 7/26/2006 12:52:36 PM
I have a web applicaiton that functions as a search engine that also serves custom information to users based on their past searches and clicks. I have several stored procedures that produce this custom information that I have spent a lot of time optimizing. When I run the sprocs through quer...more >>

How to get xml based dataset to update an SQL server database?
Posted by MurdockSE at 7/26/2006 11:37:29 AM
Newbie Question (apologies ahead of time) - I have a dataset created from an XML file (lets call it DataSet1). I want to get that data into an existing SQL Database. How do I efficiently add the rows from DataSet1 to DataSet2 and set them to ADD so that an UPDATE on the DataSet2's DataAdapter ...more >>

SqlCommand.Timeout doesn't honour setting
Posted by Andy Furnival at 7/26/2006 3:29:01 AM
Hi Recently an application of mine which polls a database every 15 seconds for work to process has started causing Timeout exceptions in the SqlCommand.ExecuteReader. The reader can generally return any number of records from 100 to 20,000. My first problem is that I decided to alter...more >>

Dataset Inserting Empty instead of Null
Posted by Earl at 7/26/2006 12:46:50 AM
VS2005 app with SQL2k and stored proc. Using a strongly-typed dataset, I've noticed that on Insert, my columns that should be null are instead showing as empty. For example, using either of these three example pieces of code with the textbox remaining empty, I still get an empty string wher...more >>

Executing procedures in access db?
Posted by Edwin Knoppert at 7/26/2006 12:00:00 AM
I have a query using a module and function and executes fine in access. When this query is executed from ASP.NET 2 it results in an error that the function is not found. Is there a way to let the jet engine call this function anyway? I'm not looking for alternative VBA loading and executing...more >>

Strange error with different SQL Server versions
Posted by paulo at 7/25/2006 7:11:41 PM
Hello, We're having a really strange problem with an application we're developing. All development was done with SQL Server 2000, so the application should be compatible with both SQL Server 2000 and SQL Server 2005. However, when connected to the same database updated to SQL Server 2005,...more >>

DataReader GetValue
Posted by Ant at 7/25/2006 7:07:01 PM
Hi, when using the Datareader, I always use GetValue to retrieve the columns value. I don't have any problems with this. Are there any perforsmance benefits in using the appropriate get method e.g. GetSqlInt32; ? Are they negligable? Thanks for any ideas. Ant...more >>

Why is DbCommandBuilder generating DEFAULT VALUES on the end of some INSERT statements?
Posted by Reggie Burnett at 7/25/2006 6:46:58 PM
Our CommandBuilder class derives from DbCommandBuilder and everything works except for when there are not column values given in an insert and DbCommandBuilder wants to generate default values. In that case, it appends "DEFAULT VALUES" onto the end of the insert command. Why on earth is this...more >>

Autoincrement fields
Posted by mfleet1973 NO[at]SPAM yahoo.ca at 7/25/2006 5:39:50 PM
Hi. I'm sure that this topic has been covered before but I just can't find it so here goes. I'm using VB.Net & SQL Server 2000. I have a table with an Identity field of type int. I need to know the value of the id field upon inserting the record. When I add the new row should I update ...more >>

Connect to MS Access database
Posted by Bob Dankert at 7/25/2006 3:58:11 PM
What is going to be the best way to connect to a Microsoft Access database using the dotnet framework 2.0? I know of two ways, but both seem to have disadvantages: First is using OLE to connect with the provider Microsoft.Jet.OLEDB.4.0. The downside to using Jet is that it does not seem to...more >>


DevelopmentNow Blog