Psyguy's Profile User Rating: -----

Reputation: 62 Whiz
Group:
Authors
Active Posts:
279 (0.31 per day)
Joined:
12-January 11
Profile Views:
5,165
Last Active:
User is offline Jun 07 2013 03:03 PM
Currently:
Offline

Previous Fields

Country:
US
OS Preference:
Windows
Favorite Browser:
Chrome
Favorite Processor:
Intel
Favorite Gaming Platform:
PC
Your Car:
Who Cares
Dream Kudos:
200

Latest Visitors

Icon   Psyguy I reject your reality and replace it with my own...

Posts I've Made

  1. In Topic: Using Pivot in a query causing issues

    Posted 7 Jun 2013

    Thanks for the reply andrew, however, after hassling the DBA a couple more times to double check that the database compatibility was set to 90 (which he previously said was) he confirmed that the compatibility was miraculously set to 80...the original query works now :P

    I guess that solves the question of whether "*" can be used in a pivot query :D.
  2. In Topic: Why does ISNull function return null value

    Posted 23 May 2013

    I'm not sure why you would use a ISNULL on a COUNT(*). The COUNT function can only return a number. If there is no data, it returns zero. Have you tried just using

    declare @count int
    
    select @count = count(*)
    from [TableName]
    ....
    set @parameterName = convert(varchar(50), @count)
    
    


    I used convert rather than cast.

    EDIT: see the following thread
  3. In Topic: can any one explain me this program

    Posted 19 Apr 2013

    This is not a program, per se, but is a class which creates the Stack data structure.

    A Stack is a FILO (first in last out) data structure. Example:

    Pseudocode:
    stack = []
    push 1
    stack = [1]
    push 2
    stack = [2,1]
    push 3
    stack = [3,2,1]
    int poppedval1 = pop //returns the value popped, in this case 3
    stack = [2,1]
    int popedval2 = pop //returns the value popped, in this case 2
    stack = [1]

    Unless you have a more specific question, that's all i have for you (although this class could be made better if it automatically increased the size of the array when the stack was full).
  4. In Topic: CheckedListBox Vb.Net

    Posted 19 Apr 2013

    Idepends on what you mean.

    If you mean you want to deselect any item in the list, you can use the method that was previously discussed.

    If you mean you would like to make it so the blue bar doesn't show up when you select something, you can just change the SelectionBackColor to something other than blue.

    Edit: if you change the selection back color, you will need to evaluate the selection fore color as well to ensure there is high enough contrast with the back color.
  5. In Topic: Sql Query - sort numeric values in ascending order

    Posted 18 Apr 2013

    I'm fairly certain that ascending is the default sort order (at least it is in SQL Server 2005). This being the case, why can't you just use the following:

    select Sl_No
    from Table 
    order by Sl_No
    
    


    The only time you need to specify the order is if you want to order it in descending order.

    Edit: "asc" is a valid keyword in SSMS, so if it "is not working" then we are going to need more information to help you, as your previous code should work.

My Information

Member Title:
D.I.C Regular
Age:
35 years old
Birthday:
October 14, 1977
Gender:
Location:
Eugene, OR
Full Name:
Joel M. Priddy
Years Programming:
3
Programming Languages:
VB.NET, C#, C++, Java, XML, SQL

Contact Information

E-mail:
Click here to e-mail me
LinkedIn:
http://www.linkedin.com/pub/joel-priddy/12/49/7b5/
Twitter:
joel_priddy

Friends

Comments

Page 1 of 1
  1. Photo

    sarahbanana Icon

    22 Apr 2013 - 15:20
    can you help me wtith the question i have just posted:D!
Page 1 of 1