I am currently having a problem since the DB has been changed.
I am using Datasets for a c# application, and there is a user management system.
For the security issues, our current DB design is like
user log into app.
DB returns a session ID
On use of any other stored procedures, a session ID must be specified.
BUT, the DB did...
I'm changing old, vulnerable SqlCommands with SqlParameters but get a SqlException:
System.Data.SqlClient.SqlException {"Conversion failed when converting datetime from character string."}
on sqlCommand.ExecuteScalar:
Dim sqlString As String = _
"SELECT TOP 1 " & _
"fiSL " & _
"FROM " & _
"tabData AS D " & ...
Hey all...
I am trying to connect to a sqllite db from with a c# application. I have never worked with SQLLite before.
var connectionString = @"data source='C:\TestData\StressData.s3db'";
connection = new SQLiteConnection(connectionString);
connection.Open();
When i attempt to open the connection I get the fol...
Hey guys I got a weird issue.. I have a datalist that's only loaded on pageload it contains 2 columns a name and date and has 398 rows.. In IE 7 and above(and prob previous version) when I open a modal via a button click it takes almost 5 seconds to open. HOWEVER, if I do not bind this datalist it's MUCH faster..
Also this is only happe...
I have a DataGridView that is being filled with data from a table. Inside this table is a column called 'group' that has the ID of an individual group in another table.
What I would like to do, is when the DataGridView is filled, instead of showing the ID contained in 'group', I'd like it to display the name of the group. Is there some ...
I am asking my self many times before start writing a new app or data access library , should I use LINQ to SQL or classic ADO.net , I have used both and the development time I spend on building an app with LINQ to SQL is like the 1/3 compared to ADO.net.
The only think I like using LINQ to SQL is that I don't have to design the domain ...
I am very new to the ADO Entity Framework, and I'm looking for the best practice.
Here is the scenario: I have a database with a Person table and an Address table. Person has a foreign key referencing the primary key of Address, an auto-incrementing int. First, I've created an ADO Entity model with VS 2010, and sure enough the relat...
I've been reading up on SqlTransactions and have found a great load of examples like:
http://www.devhood.com/tutorials/tutorial_details.aspx?tutorial_id=451
The problem is, when I do a BeginTransaction() (Execute all the commands) and then Commit() at the end all the commands I execute get run and the ones with syntax errors or other er...
I am trying to add a new record to a Visual FoxPro data table using an ADO dataset with no luck. The code runs fine with no exceptions but when I check the dbf after the fact there is no new record. The mDataPath variable shown in the code snippet is the path to the .dbc file for the entire database. A note about the For loop at the ...
I have an automatically binded DataGridView that obtains data and update data directly from a Strongly Typed Dataset and its TableAdapter.
the DataGridView allows data editing but I'm having issues dealing with bad formatted data input.
For example, one of the columns is a date, formatted in the database as datetime, 11/05/2010. You ca...
I am creating a Windows forms application and my SQL Server database is on a remote server. How can I connect to it using Visual C# and ADO.NET?
...
Hi,
1.
I am using a DataGridView, which is bound to a dataset.
There is a bindingNavigator as well.
when a user deletes a row by clicking "bindingNavigatorDeleteItem" button, I am trying to get the row being deleted.
private void bindingNavigatorDeleteItem_Click(object sender, EventArgs e)
{
int crow = gridEventTyp...
Here is the scenario (ADO.NET Entity Framework and C#).
Contact*:
String name;
Address addr;
Address*:
String street;
String city;
*this is not the real code, but you get the picture
I am trying to create a Windows Form that appears flat to the user. In other words, the Form will have four fields (name,addr,street,city), and whe...
As per MSDN, SqlDataReader.GetSchemaTable returns column metadata for the query executed. I am wondering is there a similar method that will give table metadata for the given query? I mean what tables are involved and what aliases it has got.
In my application, I get the query and I need to append the where clause programically. Using...
Scenario: I want to let multiple (2 to 20, probably) server applications use a single database using ADO.NET. I want individual applications to be able to take ownership of sets of records in the database, hold them in memory (for speed) in DataSets, respond to client requests on the data, perform updates, and prevent other applications ...
HI=i,
I need advice on how i should go about improving my c # skills. I want to improve my skills in general c#,ADO,linq and windows form applications.
...
I would like to be able to model a many-to-many relationship that has extra details about the relationship. For example:
Person: int id, String name
Project: int id, String name
ProjectPerson: Person.id, Project.id, String role
Whenever I create the ProjectPerson association in the EF, I am unable to add the role attribute to the as...
I have a ASP.Net web application with connection string for SQL Server 2005 in the web.config.
Data Source=ABCSERVER;Network Library=DBMSSOCN;Initial Catalog=myDataBase;
User ID=myUsername;Password=myPassword;
I want to specify the collation property in the web.config for different languages like French like
Data Source=ABCSE...
The other day my ASP.NET application threw an OutOfMemoryException not related to SQL Server. About a minute later, .NET garbage collection kicked in and decreased the memory usage by 50%. The application then started throwing the below exception, but there appeared to be plenty of available Private bytes for the w3wp process. We had ...
Currently I am doing:
var items = from t in entity.Items
select new
{
Name = t.ItemName,
Description = t.ItemDescription
};
myDataGridView.DataSource = items.ToList();
The problem is that when bound to the DataGridView, I get two columns of "Name" and "Description". I want to rename these to "Item Name" a...