Showing posts with label screen. Show all posts
Showing posts with label screen. Show all posts

Wednesday, March 28, 2012

No indication of the SQL Server edition in the About window

I installed the SQL Server 2005 standard edition after uninstalling the Express edition.

When i look in the 'About' screen in the 'SQL Server Managment studio', i don't see indication that the SQL Server 2005 i currently work with is the Standard Edition. There are only categories and their numbers of versions.

How do i know that the Edition i work on ,now , is the Standard edition ?

Open up Management Studio and run "select @.@.version". This will tell you your SQL and OS details, including edition.

Thanks,
Sam Lester (MSFT)

|||Thanks , works like a charm.

Saturday, February 25, 2012

Newbie:if query is successful, how to response.write on screen ?

I did this in the past using .asp, but with ASP.NET 2.0 perhaps things have
really changed, because I do response.write(TextBox1.Text) and doesn't work.
Here is what I am trying to:
Partial Class Default_aspx
Sub btnDefault_Click(ByVal sender As Object, ByVal e As
System.EventArgs)
Dim myString
myString = "SELECT Employee From Pubs " _
& "WHERE job_id = " & TxtBox1.Text
'If job_id = TxtBox1.Text is found Then
'I want to go a new page and displays on the screen 'OK
info matched'
'How can I jump to a new page from here ? (Pardon me if
this should be a question posted to .ASP newsgroup maybe ? )
Else
'Display TxtBox1.Text input did not match information in
the db'
Response.Write("Please click the 'back' button and try
to resubmit 'secret question' to reset password again.")
End If
End Sub
End ClassThis should be in an asp.net group. However, here are your answers:
First off, Response.Write's are generally discouraged, especially for what
you are doing. You should have a label and set the label's text to the
strings to display. Your sql should never ever under any circumstances be
created like that. Use stored procedures or at least parameterized queries.
Also, please google sql injection attacks to see why this is bad.
Judging from the code you posted it looks like you are doing authentication
of some kind. You might want to take a look at forms authentication. To
redirect someone to a new page you can do a
Response.Redirect("myOtherPage.html").