Showing posts with label web. Show all posts
Showing posts with label web. Show all posts

Thursday, March 29, 2012

Cant telnet x.x.x.x 1433 on localhost

Hi,
I used Microsoft SQL server 2000 on Microsoft Windows Server 2003 for database server and used Redhat Linux Enterprise for Web server.

I wrote the PHP script (on Redhat) connect to database server, its does not work. And then I install freetds on Web server but not work too.

I have problem not be solve...
- on Redhat, cannot telnet x.x.x.x 1433 to database server. But telnet to other port is success.
- on database server, cannot telnet x.x.x.x 1433 and telnet 127.0.0.1 1433.
- between web server and database server can used ping !
- I used command 'netstat -an' on database server is not show for 1433 port.

please help me... :eek:My first guess would be that you have NOT applied SQL 2000 service pack 3a or later to your SQL Server machine. Windows 2003 will not allow SQL Server to use TCP/IP unless it is protected from the Blaster worm.

-PatP|||thank you :)

Thursday, March 22, 2012

Cant seem to find IUSR_MachineName in users using SQLEXPRESS 2005

Hello,

I have an ASP web app with an SQL back end. I am currently migrating to a
new Windows 2003 Server machine and SQL Server 2005 Express. When I import
the old database, I'm trying to grant the IUSR_MachineName account access to
the database, but I can't seem to find that user account. I'm clicking new
users, and when I type this user in, SQL doesn't recognize it, and when I
click "Browse" all I see is BUILTIN/Administrators, BUILTIN/Users NT
Authority/System SA (which is not in use) and a long name that includes a
lot of dollar signs, the machine name and SQL express in it (it's a big
cryptic looking thing). Any idea how I get this to work again?

Thanks!"Rico" <r c o l l e n s @. h e m m i n g w a y . c o mREMOVE THIS PART IN
CAPS> wrote in news:jqQDf.291171$tl.48607@.pd7tw3no:

> When I import the old database, I'm trying to grant the
> IUSR_MachineName account access to the database, but I can't seem to
> find that user account.

I can't find that account either, unless...

On one Server 2003, I do not have IIS6 installed/activated (I have not yet
indentified any roles this server will have). On another Server 2003, I do.
In Computer Management control panel, Local Users and Groups, Users, I see
IUSR_<machinename>.

On the third hand, this built-in name will not show when searching for
objects when adding names to the Security tab of Folder Properties, nor, I
would imagine, any other place where you can pick names of Users or Groups.

I think it's just a name you have to know about.

Now, SQL Server 2005 Express - I just finished installing that. What a
fracking nightmare!

--
Remove INVALID from e-mail address.

Brian Smither
Smither Consulting|||ARGH! Thanks Brian,

I managed to fight through that (was my inexperience with SQL 2005,
(defining the Logins before defining the Users).

Now I'm faced with a different issue. I finally got my ASP.Net app working
using an ADO interface to SQL Server 2005 to create a crystal report,
exporting to a pdf file (phew!). I was screaming for joy when I finally got
this all working. I began testing, starting with the first report, it ran
for a long time and didn't produce anything. I went back to the first
report I ran, and it ran a long time and didn't produce anything. I opened
up management studio, and IT wouldn't even connect! I got a "Cannot
generate SSPI context" error, out of the blue, after it was already working.
nothing had changed in the meantime, I'm always careful about that.

Anyway, if you have any idea what might have occured, please let me know. I
hope this is not indicative of an unreliable database system.

"Brian Smither" <bsmitherINVALID@.INVALIDcitlink.net> wrote in message
news:Xns975FEE24E4A1SmithCon@.67.98.68.13...
> "Rico" <r c o l l e n s @. h e m m i n g w a y . c o mREMOVE THIS PART IN
> CAPS> wrote in news:jqQDf.291171$tl.48607@.pd7tw3no:
>> When I import the old database, I'm trying to grant the
>> IUSR_MachineName account access to the database, but I can't seem to
>> find that user account.
> I can't find that account either, unless...
> On one Server 2003, I do not have IIS6 installed/activated (I have not yet
> indentified any roles this server will have). On another Server 2003, I
> do.
> In Computer Management control panel, Local Users and Groups, Users, I see
> IUSR_<machinename>.
> On the third hand, this built-in name will not show when searching for
> objects when adding names to the Security tab of Folder Properties, nor, I
> would imagine, any other place where you can pick names of Users or
> Groups.
> I think it's just a name you have to know about.
>
> Now, SQL Server 2005 Express - I just finished installing that. What a
> fracking nightmare!
>
> --
> Remove INVALID from e-mail address.
> Brian Smither
> Smither Consultingsql

Tuesday, March 20, 2012

Can't see print button

Hi. I'm starting with Reporting Services 2005 and I need to use it in a web
application.
I followed the steps I found in the MSDN. I create a datasource, create the
report and then I use it in a report viewer control.
I found some problems:
1) I see no print button, and it's set to true in the viewer
2) I only can export to Excel. No other alternatives are possible.
3) I have compilation errors adding some columns from the dataset.
Can you help me to solve some of these problems?
Thank you in advance.
--
Regards,
Diego F.For #1, print is not supported in local mode processing, that is why there
is no button.
--
-Daniel
This posting is provided "AS IS" with no warranties, and confers no rights.
"Diego F." <diegofrNO@.terra.es> wrote in message
news:%23kin1HREGHA.344@.TK2MSFTNGP11.phx.gbl...
> Hi. I'm starting with Reporting Services 2005 and I need to use it in a
> web application.
> I followed the steps I found in the MSDN. I create a datasource, create
> the report and then I use it in a report viewer control.
> I found some problems:
> 1) I see no print button, and it's set to true in the viewer
> 2) I only can export to Excel. No other alternatives are possible.
> 3) I have compilation errors adding some columns from the dataset.
> Can you help me to solve some of these problems?
> Thank you in advance.
> --
> Regards,
> Diego F.
>
>

Thursday, March 8, 2012

cant retrieve connection string from web.config - ASP.NET 2.0

All,

I don't know what is the problem, i am not able to retrieve connection string from web.config in my code behind page

I used every solution provided by people in differents forums.

can anybody help me with this.

I used

WebConfigurationManager.OpenWebConfiguration("/TimeSheetApplication").ConnectionStrings("TimeSheetConnectionString").ConnectionString;

WebConfigurationManager.ConnectionStrings("TConnectionString").ConnectionString;

Here is a reference on MSDN

http://msdn2.microsoft.com/en-us/library/system.web.configuration.webconfigurationmanager(VS.80).aspx

or you can post your web.config with above code and let me look

|||

My code

Web.Config -

<connectionStrings>

<addname="TConnectionString"connectionString="Data Source=Source name"

providerName="System.Data.SqlClient" />

</connectionStrings>

Code Behind -

string query ="Select * from table"

string myConnectionString = ??

SqlConnection myConnection =newSqlConnection(myConnectionString);

SqlDataAdapter ad =newSqlDataAdapter(query, myConnection);

DataSet ds =newDataSet();

ad.Fill(ds,"table");

GridView1.DataSource = ds;

GridView1.DataBind();

? - When i used

ConnectionStringSettingsCollection connectionStrings =WebConfigurationManager.ConnectionStringsas ConnectionStringSettingsCollection;

connectionStrings["TConnectionString"].Name

it gives error

Cannot apply indexing with [] to an expression of type 'ConnectionStringSettingsCollection'

The type 'System.Configuration.ConnectionStringSettingsCollection' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Configuration, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'.

|||

You can access this way

string connString = System.Web.Configuration.WebConfigurationManager.ConnectionStrings["TConnectionString"].ToString();

|||

Thanks Farooq...

However i used the same code earlier and i am getting the error

Cannot apply indexing with [] to an expression of type 'ConnectionStringSettingsCollection'

The type 'System.Configuration.ConnectionStringSettingsCollection' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Configuration, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'

|||

make sure you have this element in web.config:

<system.web>

<compilation>

<assemblies>
<add assembly="System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
</assemblies>

</compilation>

</system.web>

Friday, February 24, 2012

cant login to sql 2005 express

when i installed visual web developer and sql management studio,i try to use sql management studio to connect to sql 2005 express,but a error ocurred.here is the error message.

TITLE: Connect to Server
----------

Cannot connect to DH\SQLEXPRESS.

----------
ADDITIONAL INFORMATION:

The type initializer for 'System.Data.SqlClient.SqlConnection' threw an exception. (System.Data)

----------

The type initializer for 'System.Data.SqlClient.SqlConnectionFactory' threw an exception. (System.Data)

----------

The type initializer for 'System.Data.SqlClient.SqlPerformanceCounters' threw an exception. (System.Data)

----------

Configuration system failed to initialize (System.Configuration)

----------

Unrecognized configuration section system.serviceModel. (C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Config\machine.config line 136) (System.Configuration)

and i wonder if anybody has experienced this error can tell me how to solve?

Can you post what in line 136 of your machine.config file?

|||

the following is the part of machine.config

line 136<system.serviceModel>
<extensions>
<behaviorExtensions>
<add name="persistenceProvider" type="System.ServiceModel.Configuration.PersistenceProviderElement, System.WorkflowServices, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
<add name="workflowRuntime" type="System.ServiceModel.Configuration.WorkflowRuntimeElement, System.WorkflowServices, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
<add name="enableWebScript" type="System.ServiceModel.Configuration.WebScriptEnablingElement, System.ServiceModel.Web, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
<add name="webHttp" type="System.ServiceModel.Configuration.WebHttpElement, System.ServiceModel.Web, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
<add name="Microsoft.VisualStudio.Diagnostics.ServiceModelSink.Behavior" type="Microsoft.VisualStudio.Diagnostics.ServiceModelSink.Behavior, Microsoft.VisualStudio.Diagnostics.ServiceModelSink, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/></behaviorExtensions>
<bindingElementExtensions>
<add name="webMessageEncoding" type="System.ServiceModel.Configuration.WebMessageEncodingElement, System.ServiceModel.Web, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
<add name="context" type="System.ServiceModel.Configuration.ContextBindingElementExtensionElement, System.WorkflowServices, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
</bindingElementExtensions>
<bindingExtensions>
<add name="wsHttpContextBinding" type="System.ServiceModel.Configuration.WSHttpContextBindingCollectionElement, System.WorkflowServices, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
<add name="netTcpContextBinding" type="System.ServiceModel.Configuration.NetTcpContextBindingCollectionElement, System.WorkflowServices, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
<add name="webHttpBinding" type="System.ServiceModel.Configuration.WebHttpBindingCollectionElement, System.ServiceModel.Web, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
<add name="basicHttpContextBinding" type="System.ServiceModel.Configuration.BasicHttpContextBindingCollectionElement, System.WorkflowServices, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
</bindingExtensions>
</extensions>
<client>
<metadata>
<policyImporters>
<extension type="System.ServiceModel.Channels.ContextBindingElementImporter, system.workflowservices, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL"/>
</policyImporters>
<wsdlImporters>
<extension type="System.ServiceModel.Channels.ContextBindingElementImporter, system.workflowservices, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL"/>
</wsdlImporters>
</metadata>
</client>
<commonBehaviors><endpointBehaviors><Microsoft.VisualStudio.Diagnostics.ServiceModelSink.Behavior/></endpointBehaviors><serviceBehaviors><Microsoft.VisualStudio.Diagnostics.ServiceModelSink.Behavior/></serviceBehaviors></commonBehaviors></system.serviceModel>]

it's no problem.it guess it may be the problem of FrameWork.because when i try to conncet by visual web developer,an error occur.it says Request .net data provider,you may not install.but as we know the .net FrameWork contains the .net data provider. and the visual web developer 2008 beta2 contains .Net Framework 3.5,So i really don't understand.

|||

Hi chance1,

After having consulted some of my collegues, it seems that your web.config file is somewhat corrupted.

The section "system.serviceModel" should be registered like the following (mine is from a 3.0 machine). <sectionGroup name="system.serviceModel" type="System.ServiceModel.Configuration.ServiceModelSectionGroup, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"> <section name="behaviors" type="System.ServiceModel.Configuration.BehaviorsSection, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> <section name="bindings" type="System.ServiceModel.Configuration.BindingsSection, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> <section name="client" type="System.ServiceModel.Configuration.ClientSection, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> <section name="comContracts" type="System.ServiceModel.Configuration.ComContractsSection, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> <section name="commonBehaviors" type="System.ServiceModel.Configuration.CommonBehaviorsSection, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowDefinition="MachineOnly" allowExeDefinition="MachineOnly" /> <section name="diagnostics" type="System.ServiceModel.Configuration.DiagnosticSection, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> <section name="extensions" type="System.ServiceModel.Configuration.ExtensionsSection, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> <section name="machineSettings" type="System.ServiceModel.Configuration.MachineSettingsSection, SMDiagnostics, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowDefinition="MachineOnly" allowExeDefinition="MachineOnly" /> <section name="serviceHostingEnvironment" type="System.ServiceModel.Configuration.ServiceHostingEnvironmentSection, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /> <section name="services" type="System.ServiceModel.Configuration.ServicesSection, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />

</sectionGroup>

I would suggest you to install the same .Net Framework 3.5 on another machine and copied the "machine.config" from the good machine to the machine in question.See if this will work. Please feel free to let me know if you have any further questions. thanks.

|||

thank you Bo Chen .and i did what you suggest in a few days ago.but sadlly, it doesn't work. and later i reinstall xp and vs 2005. and the sql 2005 express works.later i try to install visual web developer express 2008.this time visual web developer 2008 can connect and use the sql 2005 express. but vs 2005 can't work nowCrying.but thank you for the people who have helped me.

|||

Hi ,

This problem might occur sometimes due to corrupt installation of sql server 2005. I was also facing the same problem.Uninstall Sql Server 2005 and reinstall it with a different instance(named). Dont try to install with the same instance which u had used previously.Try this and tell me if this works

Thanks & Regards

Keerti Somasundaram

|||

thank you.but before i install sql server 2005,i have reinstall windows xp.and there is no sql 2005 in it. and i think it may be theproblem of visual web developer2008 beta 2.

cant login to Microsoft SQL Web Data Administrator with sql option

i have installed MSDE 2000 and Microsoft SQL Web Data Administrator.

at first i login using Windows Integrated option and created an account for sql login.

but when i tried to login using newly created account i get the following error.

Invalid username and/or password, you are using a windows login that is not your own, or server does not exist.

i am using XP SP2.Is MSDE on the same machine as Microsoft SQL Web Data Administrator?|||yes, they are on the same machine.|||Is your MSDE set up to use Mixed Mode?

By default, it will use Windows Authentication. You would have had to change this default when you installed MSDE, or after installation, through manually updating a registry setting (see this KB article:MSDE security and authentication).

You should be able to use Windows Authentication pretty readily since you are working off of your local machine.

Sunday, February 19, 2012

can't log in with MS SQL Web Data Administrator

Installed MSDE with the SAPWD parameter. Installed the MS SQL Web Data
Administrator, started Cassini on port 81 since it didn't like port 80.
Can't get the login to work at http://localhost:81/webadmin/default.aspx. I
keep getting "Invalid username and/or password, you are using a windows
login that is not your own, or server does not exist.". For the machine name
I tried (local), localhost, and my machine's network name, for the login I
tried the sa SQL login and my Windows login. Nothing's working. I'm
obviously doing something wrong, anyone want to clue me in?
BTW my machine is XP Pro.
TIA,
Paul
I have the same problem. Anyone any ideas?

Cant' log in anymore

Hi,
I pulled down all the files from my live
database which is running remotely.
When I did this, I overwrote my Web Page
connection string, which I used to log into a
local production instance of this database.
After a few weeks I got around to recreating
my connection string, but it won't work.
Neither does my partner's login info work and
we are both admins. I am the dbo. Now I am
wondering if coincidentally somehow my machine
was compromised. Is there someway I could be
kept out? I can still log onto the machine/server
which runs SQL Server for access to the drives.
I am running Windows/2000
and SQL 2000. My authentication
is set to Windows only. I run my network
as a workgroup and there is no "Active Directory".
Logging into the server to access the drives is
no problem. The login is of course the same, since
I am using Windows only authentication.
Is there anyplace I can look to see if there
is some way to get this working again?
It is not making sense to me that I can
log in to the HDs on the LAN but cannot
log into SQL databases via a webpage.
The folders are in folder needed a Windows
login, but the SQL server logs just keep showing
that access is denied because the login is not
a trusted login, which is not true, but I cannot
prove that to the server.
Could I have been compromised or does
this sound like some other confusion?
Thanks for anyone's feedback,
FoxIf the authentication is set to Windows Authentication and you're not in a
domain, then you're basically using Workgroup security to connect. The
same username and password must exists on both machines.
Thanks,
Kevin McDonnell
Microsoft Corporation
This posting is provided AS IS with no warranties, and confers no rights.

Thursday, February 16, 2012

cant install SQL Web Data Administrator

Hi

I am using Web Developer 2005 Express. I am trying to install the SQL Web Data Administrator (setup.msi), but it gives an error message saying that I need to install Framework 1.1, BUT I already have version 2, so no-go for me there.

Also I have been trying to install the Cassini version with zero luck. When I run the build.bat file I get the csc and gacutil errors. However, when I set up the Environmental variable PATH within My Computer\Properties\Advanced\Environmental Variables\user Variables as per the instructions on the Cassini discussion forum, no change, I do not get 200 bucks or pass GO .

Please tell me I am being stupid

Dose your system fit all the requirements?

System Requirements

Supported Operating Systems:Windows 2000

Cant install SQL Server on Windows Server2003

I try to install Microsoft SQL Server 2000 Enterprise Edition on Windows Server 2003 Web Editon, but fail...

Step 1: Double the Autorun
Step 2: Click on SQL Server Components
Step 3: Click Install Database Server
The installation just disappear here. There is no response from the System.
If I use the same SQL Server disk install on Windows Advanced Server 2000,
the installation work fine.

Appreciate help....As far as I know, there is no way to install SQL Server on the Web Edition of 2003.

Jason Bentley

Tuesday, February 14, 2012

Cant install SQL Server 05 EE, VB 2005, or Visual Web Dev 2005

hi! i just joined this group today after a colleague told me about it.
anyway, i'm new to SQL and haven't tried installing any version of it.
I do have vb 6.0 though on my pc. My problem is that I can't install
SQL server 05 EE, VB 2005 or VW 2005. I have downloaded all of the
installer from the Microsoft site as well as the dotnetfix which is
supposed to install the .net framework 2.0.

whenever i try to install SQL server EE, it is telling me that it has
found beta components. but i don't have any beta versions of SQL. I
tried uninstalling my Vb 6.0 thinking its causing the error, but same
thing happened.

The next thing I did is I uninstall my .net 2.0 and when i try to
install VB or VW 2005, i got to the step where it is trying to download
the .net framework 2.0 but it is taking so long. Question: is the
dotnetfix.exe which installed .net 2.0, different from the .net 2.0
that the setup.exe of VB2005 will download? if yes, may i know if there
is a direct site where i can manually download and install it so the
VB2005 will just skip that part and go on with the installation?

When i downloaded the exe files for SQL, .net 2.0, VB and VW, i did
select the SAVE option and saved them on my external mini hard drive so
I can install it at home. Does that make any difference? could that
cause the error?

pretty clear that i am a newbie with this stuff and i never thought
that it would be this hassle to install them heheheh any help, in a
detailed way if possible, would highly be appreciated.

thanks so much!

mannypine (mrehpine@.gmail.com) writes:

Quote:

Originally Posted by

hi! i just joined this group today after a colleague told me about it.
anyway, i'm new to SQL and haven't tried installing any version of it.
I do have vb 6.0 though on my pc. My problem is that I can't install
SQL server 05 EE, VB 2005 or VW 2005. I have downloaded all of the
installer from the Microsoft site as well as the dotnetfix which is
supposed to install the .net framework 2.0.


EE = Express Edition or Enterprise Edition?

Quote:

Originally Posted by

The next thing I did is I uninstall my .net 2.0 and when i try to
install VB or VW 2005, i got to the step where it is trying to download
the .net framework 2.0 but it is taking so long. Question: is the
dotnetfix.exe which installed .net 2.0, different from the .net 2.0
that the setup.exe of VB2005 will download? if yes, may i know if there
is a direct site where i can manually download and install it so the
VB2005 will just skip that part and go on with the installation?


I can't speak for Visual Basic, but once installed, in
C:\WINDOWS\Microsoft.NET\Framework you should have a directory v2.0.50727.
If you have a lower number, that is a beta version.

Did you ever install a beta of Visual Studio 2005? Apparently you did
install the beta of something since you get the message. And that would be
a beta of SQL 2005, .Net Fx or VS 2005.

--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx|||hi erland. Sorry for that one, i meant Express Edition (EE). Im sure I
did not install any beta versions of any kind for this matter as I just
have reformatted my hard drive cuz i upgraded my motherboard just 3
nights ago. also, I checked my .net 2.0 folder and yes, i do have the
v2.0.50727 directory. btw, im not sure if it will help, i have winxp
sp2.

Erland Sommarskog wrote:

Quote:

Originally Posted by

pine (mrehpine@.gmail.com) writes:

Quote:

Originally Posted by

hi! i just joined this group today after a colleague told me about it.
anyway, i'm new to SQL and haven't tried installing any version of it.
I do have vb 6.0 though on my pc. My problem is that I can't install
SQL server 05 EE, VB 2005 or VW 2005. I have downloaded all of the
installer from the Microsoft site as well as the dotnetfix which is
supposed to install the .net framework 2.0.


>
EE = Express Edition or Enterprise Edition?
>

Quote:

Originally Posted by

The next thing I did is I uninstall my .net 2.0 and when i try to
install VB or VW 2005, i got to the step where it is trying to download
the .net framework 2.0 but it is taking so long. Question: is the
dotnetfix.exe which installed .net 2.0, different from the .net 2.0
that the setup.exe of VB2005 will download? if yes, may i know if there
is a direct site where i can manually download and install it so the
VB2005 will just skip that part and go on with the installation?


>
I can't speak for Visual Basic, but once installed, in
C:\WINDOWS\Microsoft.NET\Framework you should have a directory v2.0.50727.
If you have a lower number, that is a beta version.
>
Did you ever install a beta of Visual Studio 2005? Apparently you did
install the beta of something since you get the message. And that would be
a beta of SQL 2005, .Net Fx or VS 2005.
>
--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
>
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx

|||pine (mrehpine@.gmail.com) writes:

Quote:

Originally Posted by

hi erland. Sorry for that one, i meant Express Edition (EE). Im sure I
did not install any beta versions of any kind for this matter as I just
have reformatted my hard drive cuz i upgraded my motherboard just 3
nights ago. also, I checked my .net 2.0 folder and yes, i do have the
v2.0.50727 directory. btw, im not sure if it will help, i have winxp
sp2.


Hm, if the install is that fresh, then it the easiest way would be
to start over again, and then start with installing .Net Fx followed
by SQL Server, and then Visual Basic and Visual Web Developer. (But
avoid the other junk you usually cram in. :-)

--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx

Can't install Express June CTP?!

Hey all, I'm trying to install SQL Server 2005 Express June CTP on a windows 2003 Web Edition Server (With SP1).

I've had an old version of the .NET 2.0 Framework installed, so I downloaded the one mentioned next to the SQL Express download (this one: http://go.microsoft.com/fwlink/?linkid=48448).

Each and every time I run the setup I encounter this error:
The SQL Server service failed to start. For more information, see the SQL Server Books Online topics, "How to: View SQL Server 2005 Setup Log Files" and "Starting SQL Server Manually."
There is not even any sort of SQL Server service in the list of services, what should I do?
Regards,

Hendrik BehrensI've also tried the same on Windows XP Professional SP2. I had to uninstall a previous version of .NET 2.0 and VWD Express/VB Express Beta 2 are installed.

I get the same error message?! - The service is not there and the setup just fails with that message.

I've had SQL Express April CTP installed on a windows 2003 Enterprise *trial*, which worked, the update to Junce CTP... right, fails with the same message.
Any proposals?|||Did you look for the log files?

-Euan|||Yes I did, and I found the problem: My windows XP Professional and Windows Server 2003 Web Edition are both german - the setup fails on non-english langauge versions with default settings, this german article describes the problem and how to solve it (for everyone else who encounters this):

http://www.microsoft.com/germany/msdn/vs2005/installvs2005beta.mspx
(basically, remove the tick "Hide advanced configuration Options" and select "Local System" as the service account, instead of "Network Service", which is the default.)

Sunday, February 12, 2012

Can't import image when size is more then 8K using "microsoft.xmlhttp"

I'm using following script to import image into SQL Server from web and it does not work for image 2 (http://dbalinks.com/images/mol2.jpg) but it work for image 1 (http://dbalinks.com/images/mol1.jpg):

declare @.local int
declare @.retcode int
declare @.status int
declare @.url varchar(2000)

create table #httpresult(pic image)

--set @.url = 'http://dbalinks.com/images/mol1.jpg'
set @.url = 'http://dbalinks.com/images/mol2.jpg'

exec @.retcode = sp_oacreate 'microsoft.xmlhttp', @.local out
exec @.retcode = sp_oamethod @.local, 'open', null, 'get',@.url , 'false'
exec @.retcode = sp_oamethod @.local, 'send', null, @.status
exec @.retcode = sp_oagetproperty @.local, 'status', @.status out
insert #httpresult (pic)
exec @.retcode = sp_oagetproperty @.local, 'responsebody'

select * from #httpresult

drop table #httpresult

exec sp_oadestroy @.local


Is it possible to import image larger then 8K into SQL Server from the web using T-SQL and stored procedure?

Is there any chance that admin can do something about this?

Maybe using stream:

exec sp_oacreate 'adodb.stream',@.o OUT
exec sp_oasetproperty @.o,'Type',adTypeBinary

or something like that.

Can't import image when size is more then 8K using "microsoft.xmlhttp"

I'm using following script to import image into SQL Server from web and it does not work for image 2 (http://dbalinks.com/images/mol2.jpg) but it work for image 1 (http://dbalinks.com/images/mol1.jpg):

declare @.local int
declare @.retcode int
declare @.status int
declare @.url varchar(2000)

create table #httpresult(pic image)

--set @.url = 'http://dbalinks.com/images/mol1.jpg'
set @.url = 'http://dbalinks.com/images/mol2.jpg'

exec @.retcode = sp_oacreate 'microsoft.xmlhttp', @.local out
exec @.retcode = sp_oamethod @.local, 'open', null, 'get',@.url , 'false'
exec @.retcode = sp_oamethod @.local, 'send', null, @.status
exec @.retcode = sp_oagetproperty @.local, 'status', @.status out
insert #httpresult (pic)
exec @.retcode = sp_oagetproperty @.local, 'responsebody'

select * from #httpresult

drop table #httpresult

exec sp_oadestroy @.local


Is it possible to import image larger then 8K into SQL Server from the web using T-SQL and stored procedure?

Is there any chance that admin can do something about this?

Maybe using stream:

exec sp_oacreate 'adodb.stream',@.o OUT
exec sp_oasetproperty @.o,'Type',adTypeBinary

or something like that.

Friday, February 10, 2012

cant get sqldatasource to return results from a stored procedure

I thought I would impliment a new feature of my web page using stored procedures and the SqlDataSource object, for practice or whatever, since I don't normally use that stuff.

This is the stored procedure:

set ANSI_NULLSONset QUOTED_IDENTIFIERONgo-- =============================================-- Author:Lance Colton-- Create date: 7/31/06-- Description:Find the contest winner-- =============================================ALTER PROCEDURE [dbo].[AppcheckContest]-- Add the parameters for the stored procedure here@.BeginDatedatetime ='1/1/2006', @.EndDatedatetime ='12/31/2006', @.SectionIDint = 10,@.WinnerIDint = 0OUTPUTASBEGIN-- SET NOCOUNT ON added to prevent extra result sets from-- interfering with SELECT statements.SET NOCOUNT ON;-- Insert statements for procedure hereSELECT top 1 @.WinnerID = P.UserIDFROM cs_Posts PWHERE P.PostDateBETWEEN @.BeginDateAND @.EndDateAND P.SectionID = @.SectionIDAND P.UserID <> 2100-- I don't want to win my own contest...AND SettingsID = 1000-- This number could be different if i had more than one CS installed?AND IsApproved = 1ORDER BYNEWID()-- yes this is slow, but it works...RETURN @.WinnerIDEND

It's really simple - just needs to return the one randomly chosen integer userID. I've tested it in query designer or whatever it's called in Management Studio and it works fine there at least.

Thinking I was done the hard part, I created a new web form in visual studio, dropped a SqlDataSource on it, and used the 'configure data source' wizard from the smart tag to do all the work for me. I didn't have any trouble using the wizard to select my stored procedure, and i'm using the sa connection string to simplify my debugging. I tried using the FormParameter / FormField way of getting the output and setting the input parameters. I can't seem to get it working though. There's no errors or anything, just the output isn't coming through.

Here's the code from the aspx codebehind file:

Partial Class Contest Inherits System.Web.UI.Page Protected Sub btnSelectWinner_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnSelectWinner.Click Dim stuff As New System.Web.UI.DataSourceSelectArguments SqlDataSource1.Select(stuff) SqlDataSource1.DataBind() lblWinnerID.Text = SqlDataSource1.SelectParameters("WinnerID").ToString End SubEnd Class

As you can see, I wasn't sure if you're supposed to call databind() or select() to actually get the stored procedure to execute, so I tried both. I was hoping the last line of code there would set the label to the value contained in the @.WinnerID parameter, but instead it sets it to "WinnerID".

Here's the code from the .aspx file. Most of this was generated by the Wizard, but I messed around with it a bit.

<%@. Page Language="VB" MasterPageFile="~/MasterPage.master" AutoEventWireup="false" CodeFile="Contest.aspx.vb" Inherits="Contest" title="Untitled Page" %><asp:Content ID="Content1" ContentPlaceHolderID="CPHMain" Runat="Server"> <asp:Button ID="btnSelectWinner" runat="server" Text="Find Winner" /> <asp:Calendar ID="Calendar_From" runat="server"></asp:Calendar> <asp:Calendar ID="Calendar_To" runat="server"></asp:Calendar> <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:appcheck-csConnectionString-sa%>" SelectCommand="AppcheckContest" SelectCommandType="StoredProcedure" CancelSelectOnNullParameter="False"> <SelectParameters> <asp:FormParameter FormField="Calendar_From" Name="BeginDate" Type="DateTime" /> <asp:FormParameter FormField="Calendar_To" Name="EndDate" Type="DateTime" /> <asp:Parameter DefaultValue="10" Name="SectionID" Type="Int32" /> <asp:formParameter FormField="lblWinnerID" defaultvalue="666" Direction="InputOutput" Name="WinnerID" Type="Int32" /> </SelectParameters> </asp:SqlDataSource>   <asp:Label ID="lblWinnerID" runat="server" Text="?"></asp:Label></asp:Content>

okay well i gave up on using a sqldatasource since nobody replied.

here's my final working code using an sqlCommand object instead:

PartialClass ContestInherits System.Web.UI.PageProtected Sub btnSelectWinner_Click(ByVal senderAs Object,ByVal eAs System.EventArgs)Handles btnSelectWinner.ClickDim objCommandAs New SqlClient.SqlCommandDim objConnAs New SqlClient.SqlConnectionDim strQueryResultAs New Object objConn.ConnectionString = ConfigurationManager.ConnectionStrings("appcheck-csConnectionString-sa").ConnectionString objCommand.Connection = objConn objCommand.CommandType = CommandType.StoredProcedure objCommand.CommandText ="AppcheckContest"Dim intWinnerIDParamAs New SqlClient.SqlParameter("@.WinnerID", SqlDbType.Int)Dim DateFromParamAs New SqlClient.SqlParameter("@.BeginDate", SqlDbType.DateTime)Dim DateToParamAs New SqlClient.SqlParameter("@.EndDate", SqlDbType.DateTime) intWinnerIDParam.Direction = ParameterDirection.Output DateFromParam.Direction = ParameterDirection.Input DateToParam.Direction = ParameterDirection.Input objCommand.Parameters.Add(intWinnerIDParam) DateFromParam.Value = Calendar_From.SelectedDate DateToParam.Value = Calendar_To.SelectedDate objCommand.Parameters.Add(DateFromParam) objCommand.Parameters.Add(DateToParam) objConn.Open() objCommand.ExecuteScalar() objConn.Close()Try lblWinnerID.Text ="Winner ID: <a target='_blank' href='http://forum.appcheck.net/web/user/Profile.aspx?UserID=" & intWinnerIDParam.Value & "'>" & intWinnerIDParam.Value & "</a>" Catch ex As Exception lblWinnerID.Text = "error"End Try End SubEnd Class
<%@. Page Language="VB" MasterPageFile="~/MasterPage.master" AutoEventWireup="false" CodeFile="Contest.aspx.vb" Inherits="Contest" title="Untitled Page" %><asp:Content ID="Content1" ContentPlaceHolderID="CPHMain" Runat="Server"> Contest Start Date:<asp:Calendar ID="Calendar_From" runat="server"></asp:Calendar> Contest End Date:<asp:Calendar ID="Calendar_To" runat="server"></asp:Calendar> <asp:Button ID="btnSelectWinner" runat="server" Text="Find Winner" /> <asp:Label ID="lblWinnerID" runat="server" Text="?"></asp:Label></asp:Content>
set ANSI_NULLSONset QUOTED_IDENTIFIERONgo-- =============================================-- Author:Lance Colton-- Create date: 7/31/06-- Description:Find the contest winner-- =============================================ALTER PROCEDURE [dbo].[AppcheckContest] @.BeginDatedatetime, @.EndDatedatetime, @.SectionIDint = 10,@.WinnerIDint = 0OUTPUTASBEGINSET NOCOUNT ON;SELECT top 1 @.WinnerID = P.UserIDFROM cs_Posts PWHERE P.PostDateBETWEEN @.BeginDateAND @.EndDateAND P.SectionID = @.SectionIDAND P.UserID <> 2100-- I don't want to win my own contest...AND SettingsID = 1000-- This number could be different if i had more than one CS installed?AND IsApproved = 1ORDER BYNEWID()-- yes this is slow, but it works...END
|||Hi,

I've had a similar issue for the last few days.
I only found 1 page that helped me solve it:
http://dotnetjunkies.com/QuickStartv20/util/srcview.aspx?path=~/aspnet/samples/data/RetValAndOutputParamsInsert.src

I hope this helps you.

Cheers
Luke

|||

The above posters link is correct. The output/return value parameters are only available during the "ED" events (Inserted/Updated/Deleted). So if you want them, you have to capture them during that event.

And just a FYI - NewID isn't random, not even close. Google a better random method, which usually involves taking the last 32 bits of newid and feeding it into the rand function.

Cant get SQL Server Express to install

I'm using the disk that came with my Visual Web Developer for Dummies book. It installed on my XP Home machine, but when installing on my XP Pro machine, the fourth step, SQL Server Express, it fails. I cleaned up my hard drive (about ten gigs of free space), I followed the steps herehttp://msdn.microsoft.com/vstudio/support/readme/default.aspx to uninstall everything dot net related. Rebooted, checked my control panel, etc. Tried to install. It just fails. No error message.

Can anyone give me an idea of where to start?

Thanks

Try to install the version on msdn rather then on the CD and see if it works. Here is the link for the download.

http://msdn.microsoft.com/vstudio/express/sql/download/default.aspx

|||

Ha ha ha. Never quit.

Banging my head against the wall, or trying to get this thing to work?

I was thinking about my gov't issued perpetual virus scan, and thought I'd disable it. And then some time ago I had to do something (that never worked) regarding permissions to the INETPUB folder. And another source also suggested a direct download. Which is what I'll try next. I think I'll try it first in the 'repair' mode if it's available (as it is on the disk - it recognizes that the first three options installed properly and offers up the fourth).

|||

Success!

I had already disabled the virus scan, and so don't know if that had anything to do with it. But the download of just the SQL Server says it was successful. My dot net 2.0 framework was detected (it must be installed first), and it sailed thru like it should have in the first place.

As I think I mentioned in my first post, installation on my other laptop (wife's) with XP Home went perfect from the disk. A little weird that my old standby wouldn't work with it, but I'll accept it. And get started with what appears to be some very cool stuff.

|||I came across an issue on installing. When operating from the disk in the Visual Web Developer for Dummies book, the SQL Server just failed. No messages. When downloading from MicroSoft, I got a message that the c:\program files\microsoft sql server folder couldn't be compressed. So, while that message was up, I went thru explorer to change the properties of it. More than a few times, exe and dll files came up that were in use and couldn't be uncompressed. I finally hit the ignore all button and hoped for the best. When it was finished, I went back to the installation routine and hit continue. And it appears to have worked.

Cant get Reports Server page to work

hi I have sql 2005 Standard on WinXP and i cant get http://localhost/ReportServer to work.
I get the web page error
Server Application Error
The server has encountered an error while loading an application during the

processing of your request. Please refer to the event log for more detail

information. Please contact the server administrator for assistance.

I have re-installed sql 2005, reinstalled IIS .
I have run the aspnet_regiis -i and still nothing.

Please someone, anyone , help.

just a suggestion

have a look in your sql server configuration tools // configuration manager // expand the network configuration until you get protocols and then in the right hand pane you should see TCPIP - double click - it might say disabled. - double click and in the properties - then select IP addresses tab - 127.0.0.1 make sure this is enabled. Also check this for remote connections.

We have been down this road and that's what solved ours.

Hope it helps

jewel

|||Hi, I tried as you suggested. That was already enabled.
Still not working.|||what does your event viewer say?|||Event Type: Warning
Event Source: W3SVC
Event Category: None
Event ID: 36

Description:
The server failed to load application '/LM/W3SVC'. The error was 'The specified metadata was not found.|||

here is a link that may help :)

http://support.microsoft.com/default.aspx?scid=kb;en-us;Q257267

|||Hi, i tried what was said in the post but still nothing.
i

dont have the file mentioned above in my c:\winnt\system 32. I think

the above is for win nt . I have win xp and my component services

doesnt hang.
|||This seems more like an IIS issue. How about trying to recreate the default web site? If you deploy an ASP.NET app on the default website, does it work? If you reinstall SQL and IIS, make sure you install IIS before SQL.

cant get Reporting services

hello sir/madam

i have been installed Visual web developer 2005 express edition. with that i have been installed .net framework 2.0 and SQL server 2005. Even then i can't enabled with the reporting services. i am doing my final year projects now. i am in the conclution stage. so i hav to design reports.But without enabling with reporting services nothing i can do...

Wht will be the problem

Have a look athttp://www.microsoft.com/technet/prodtechnol/sql/2005/usingssrswithsqlexpress.mspx

If you cannot get enough information from the Technet note, please reply, and I will have a look tonight (once I can connect from my lodgings ~ 18:00 UTC)

|||

Did you get IIS working and confim that it was working, before you installed SQL Express and SQL Reporting Services?