Browse by Tags

Related Posts

  • Error: Must declare the table variable "@Class".

    I'm getting this error: Must declare the table variable "@Class". I'm trying to pass a SQL query through C# to delete fields of a table which is selected from a drop down list. I am passing @Class as a parameter, i.e. cmd.Parameter.AddWithValue("@Class",selectedTable); As...
    Posted to Web Forms (Forum) by jbon0017 on 04-29-2009, 12:00 AM
    Filed under: parameter, parameters, query string, sql, SQL injection, ASP .net 3.5
  • Passing a set of values using the SQL 'IN' operator

    Hi, I was wondering if it was possible to pass a dynamic parameter to the the SQL 'IN' operator in a query that is created in the .xsd (data) layer. The hardcoded version works like it should: SELECT * FROM t_items WHERE id_item IN (1,2,4) The problem is that I need this to be dynamic, thus the...
    Posted to Data Access and ObjectDataSource Control (Forum) by Dr_Gonzo on 09-05-2008, 12:00 AM
    Filed under: Parameter, Passing parameters C#, sql, in
  • C# URL parameter from SQL - Beginner

    Is there any good tutorials on how to build a dynamic .aspx page in C# based upon, let's say ID from SQL database? Here is what I want: 1. Default.aspx with a textbox and a submit button. When user inserts the value 1 and clicks submit. Default.aspx shows content for that specific ID e.g. Default...
    Posted to Getting Started (Forum) by craigi70 on 10-25-2007, 12:00 AM
    Filed under: parameter, sql, url
  • SqlDataSource Paramters not working

    I am building an ecommerce app, its kind of a hybrid asp/asp.net but essentially there is an asp page which was originally used to maintain the shopping cart functions (order.asp). This page just stored the items in a cart and provided quotations, no transactions really occured. Rather than re write...
    Posted to Data Presentation Controls (Forum) by shooter1746 on 10-24-2007, 12:00 AM
    Filed under: parameter, Selectparamters, sql, sqldatasource, SqlDataSource1, sqlldatasource, SqlParameter, .Net 2.0, .NET Gridview Problems, asp.net ... ... Data access datagrid, ASP.net 2.0 GridView InsertParameters ControlParameter PropertyName, Control Parameter, datagrid, DataSource Binding, datatagrid, SQL Query
  • Simplest method for SQL insert

    I have spent the afternoon researching this, and to no avail so here's my question. I have a user input form with upwards of 60 fields that are to be filled in by the user (intranet environment). I want to post those values as a new record in an SQL database. I have setup an SQLDataAdapter tied to...
    Posted to SQL Server, SQL Server Express, and SqlDataSource Control (Forum) by climber9 on 06-13-2007, 12:00 AM
    Filed under: parameter, sql, SQL Data Adapter, insert database sql, asp.net 2.0
  • problem with retrieving/displaying data based on form input

    Hi, I've developed a form which accesses a database through a data layer and sends parameters based on the form input. I have written the following code which works by checking if the textbox is empty and passing a null value as a string to the search parameter in the query, of which there are five:...
    Posted to Data Presentation Controls (Forum) by tomosap on 02-22-2007, 12:00 AM
    Filed under: Null, parameter, problem, querystring, records, rows, search, sql, sqldatasource, string, table adapter, textbox, Updateparameters, VB, access database, ADO.NET, ASP.net 2.0 GridView InsertParameters ControlParameter PropertyName, data, data access layer, database, databinding, datasource, If Statement, method, SELECT, FORM, GridView, label, GridView asp.net
  • Label text passing "" instead of NULL

    I have a sqlDatasource on my page that runs a stored prodecure in SQL and populates a combobox value list. The stored prodecure has an optional parameter. I have tried 50 different ways I have found on Google to pass a null value for a label that has a text value of "" but have had no success...
    Posted to SQL Server, SQL Server Express, and SqlDataSource Control (Forum) by RTisserand on 09-08-2009, 12:00 AM
    Filed under: SQLDataSource, sql, parameter
  • Parameter Not Supplied - even though parameter is supplied?

    Hi all, I'm getting a parameter not supplied error on this stored procedure: @newsTitle varchar(100), @newsBody varchar(max), @hasPhoto bit, @originalFilename varchar(50), @systemFilename varchar(50) AS BEGIN -- SET NOCOUNT ON added to prevent extra result sets from -- interfering with SELECT statements...
    Posted to SQL Server, SQL Server Express, and SqlDataSource Control (Forum) by G0ggy on 11-06-2009, 12:00 AM
    Filed under: SQL, parameter, vb.net, class
  • Problem with GridView Update with SQL Parameters

    If I use UPDATE [PWL] SET [QTY] = @Quantity WHERE [Id] = @Id QTY changes to null If I use UPDATE [PWL] SET [QTY] = '1' WHERE [Id] = @Id. It works fine so I know it is the Parameter that is causeing the issue. Where else do I set the Parameter besides <UpdateParameters> <asp:Parameter...
    Posted to Data Presentation Controls (Forum) by KenNichols on 11-11-2009, 12:00 AM
    Filed under: GridView, sql, parameter
Page 1 of 1 (9 items)