Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 736769
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T07:38:36+00:00 2026-05-14T07:38:36+00:00

I have asp:GridView displaying client requests using asp:SqlDataSource . I want to limit displayed

  • 0

I haveasp:GridView displaying client requests using asp:SqlDataSource. I want to limit displayed information by client:

View.aspx has to display everything, View.aspx?client=1 has to display only requests from client ID #1.

So I’m using <asp:QueryStringParameter Name="client" QueryStringField="client" /> for query "EXEC getRequests @client".

Everything works properly when some client is specified. But don’t – if not.

I tested my SP using SSMS – it works properly in both cases – when parameter is specified and when it isn’t (NULL passed explicitly).

What have I do?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T07:38:36+00:00Added an answer on May 14, 2026 at 7:38 am

    SqlDataSource won’t fire if any of it’s parameters are null, unless you specify otherwise:

    <asp:SqlDataSource CancelSelectOnNullParameter="False" />
    

    It might also be necessary to add a null default value to your querystring parameter:

    <asp:QueryStringParameter Name="client" QueryStringField="client" DefaultValue="" ConvertEmptyStringToNull="True" />
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm displaying a GridView using the following markup in my default.aspx : <Columns> <asp:BoundField
I am working on an ASP.Net website and have a GridView displaying some data,in
I have an ASP.Net GridView control on an ASPX page hosted on a SharePoint
I have a GridView in ASP which I use for displaying products in a
I have an ASP.NET GridView control with two asp:CommandField columns that are both using
i have a asp buttonfield in a asp:gridview as follows <asp:ButtonField ButtonType=Button CommandName=Select HeaderText=View
I want to use an ObjectDataSource with a GridView in ASP.NET. Displaying the data
I have a ASP.NET GridView with a column mapped to a boolean. I want
I have a asp:GridView which contains a asp:TextBox within a TemplateField. I would like
I have a asp:GridView with a HyperLinkField . It's DataNavigateUrlFormatString property is set to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.