How to use wordpress with MSSQL Server? - asp.net

My company has a portal based on C# ASP.NET. I have to develop wordpress websites whose data is required to be driven from portal database i-e; MSSQL Server. There is no direct and simple solution to connect wordpress website with MSSQL. There is a project called Project Nami which can help in this regard but is there any other way to achieve this objective? Is there any other CMS that can work like Wordpress and can run with MSSQL Server?
Thank you.

Long story short: You can't. Try SQL CMS instead.

Wordpress is tightly coupled to MySQL.
It can't be done and no amount of wishing otherwise by you, your business, or your management will change that.
You can deploy Wordpress as part of a website though with a separate MySQL somewhere but I would typically consider a separate URL (blog.mywebsite.com) and hosting it elsewhere. And uploading articles into this WP.
If MSSQL is 100% required for your articles, then you can't use WP. And I'd ask why, because clearly the presentation can be done elsewhere in this case and WP is not needed.

Both answers above are incorrect. Of course you can connect php app, which is what wordpress is, to a mssql database. Microsoft has long ago provided the drivers for it. Google it and you will find drivers for linux or debian OS's. It all depends on what you want to do. You will have to write your own code to pull the data you want from your mssql database and load it to wordpress to display it on the wp site. But saying php cannot connect to mssql is incorrect. Any php app can connect and grab data from MSsql database.

Related

WordPress installation

I currently have a website running on Windows Server 2008 with MS SQL Server 2008 Web Edition.
I want to host a blog, tightly coupled to the site, and after reading a good few articles, decided that I would like to install WP in a folder off the website root, accessible like this?
http://www.mysite.com/blog
I've just upgraded to Web Platform 4.6, and this has returned a few different options with regard to installation. Here's what I have:
Standard WordPress installation
Brandoo WordPress
WebMatrix3
WordPress itself is not familiar (apart from using it of course), and wondered if anyone could shed any light on these options.
Brandoo Wordpress uses MS SQL or Azure SQL by default. If You want to install WordPress winth thos DB's, use Brandoo WordPress.
Read here and here. Since this is essentially a fork of Wordpress, security updates and whatnot may be delayed. To use the official Wordpress code, you'll have to install MySQL.

umbraco deployment procedure

I am trying to deploy umbraco website. The website runs ok locally, now when I published the website and uploaded via ftp client, there is internal error when I am trying to access the website.
My question is, since I was using SQL CE database locally, will I be still able to use that DB online or I'll have to use sql server database?
Furthermore, is there any special method to deploy umbraco application?
Thanks for reading, Laziale
If u have an windows azure account load it in to azure it works perfectly transfer your file through FTP . Install umbraco from azure as apps which azure is providing it works perfectly . I am also using umbraco on azure
You can use SQLCE on line, personally I wouldn't recommend it unless it is a very small DB, and the site gets little traffic; SQL Express is also free and a lot more powerful - but to your question, yes, SQLCE should work.
Perhaps let us see your connection string and the specifics of the error you are getting.

Which database to use for C# ASP.NET website?

I am developing an online internal web portal (like users write tests, provide document links to study, completing a study roadmap, admin user to view ststistics, etc). It caters some 150 users. I have planned to use ASP .NET with c# in Visual Studio 2008 on windows xp. I am implementing using Forms and NOT MVC since I feel at home with forms.
I do not want to use windows authentication since each user will have many attributes related to him and so it will be easy using a database. Security is not an issue since it is being used internally only.
I have only a fair knowledge about ASP and C# and VS 2008.
Now my questions:
Can I use MS SQL server database that is built in in VS 2008?( I cannot ask for external databases)
Can I export the website totally along with the databases to IIS server running in some other computer? How?
Do I need to export databases separately or provide a database creation script like PHP?
(I have more questions. Will update once I start off).
(This is my first .net web app. so can i know where i can find login scripts, pagination, examples, and pretty much all the stuff)
edit: which to use? New website or New Webapplication?
You can pretty much use any database, but it seems from your requirements that you want to look closer towards something like SQLExpress, SQL Server Compact Edition or SQLLite.
Can I export the website totally along
with the databases to IIS server
running in some other computer? How?
Your database will be shipped along with your application if you use one of the database options that I have specified above.
Do I need to export databases
separately or provide a database
creation script like PHP?
See my comment above, the database will exist when you deploy your website to IIS. It's a physical file that will be in your APP_DATA folder.
You can use:
MySQL. The reason: It has no space or memory limit!
SQL Server or SQL CE. These are both alike. They just differ in slite functions, and also the storage!
The SQL CE allows you to have 4GB. But the SQL Server lets you have 10GB.
So it depends on your work!
Also, I wanted to point out one error in a post, that the SQL CE is present in App_Data, Correct! But the SQL Server is placed somewhere like:
C:\Program Files\Microsoft SQL Server\MSSQL10_50.SQLEXPRESS\MSSQL\here_will_it_be
And yes, you can migrate it to wherever you want to place it. I mean if you want to upload it to a hosting server, you can upload it using Web Deploy! Or what ever service. When downloading you will have to repeat same process!
I hope you are doing good with your first web app! :)

How do you deploy a BLANK copy of your SQL 2005 express database with your ASP.NET project?

Age old question! When you have finished developing and testing your ASP.Net web application, the database you want to deploy is now full of test information and needs to be emptied (and identity fields reseeded to 1) before you deploy.
When using a server instance, this isnt difficult (create a SQL script to do the job) but when using a user instance, its seems there is no easy way around?
Can anyone help with this? Thanks
See if this could help you http://rip747.wordpress.com/2007/10/01/sql-server-2005-import-export-reset-identity-keys-no-workaround-2005-sucks-period-the-end/
Here is another good one
http://dotnetslackers.com/community/blogs/mosessaur/archive/2007/12/09/sql-server-2005-clean-your-database-records-amp-reset-identity-columns-all-in-6-lines.aspx
You can connect SSMS to a user instance DB, it just requires a bit of voodoo to discover the DB name.
As for scripting the sql, you can also use the Sql Server hosting toolkit to do this.

How WP-o-Matic works and how to do the same using ASP.Net? Cron job equivalent in .NET?

WP-o-Matic is a wordpress plugin to auto post based on some configured feeds, it read feeds everything time interval i setup, its working on my blog, my blog is on shared windows web hosting, i want to know how it auto work like that, and because i am on a shared hosting, so sure i didn't setup any windows services on the server, so its just keep working just after activating, seams strange idea for me.
Here's a nice article on how to create a Task Scheduler (similar to Cron) in ASP.NET
i am afraid you will have to write a windows service to run the scheduled jobs in .Net environments. In general, shared hosting companies do not provide a provision to configure a windows service on the servers so you might have to look at other alternative for hosting.

Resources