SQL Server :: Create An Articles Database In C#?
Jan 3, 2011
I would like to make a website where you can type in the url [URL] and the webpage will retrieve the article and display it in the articles view.
How would I best go about doing this?
Would I use a SQL database? Xml files? Text Files?
View 1 Replies
Similar Messages:
Sep 25, 2010
I'm an ASP.NET newbie, but not so new at programming in general.
I'm creating a commercial website, and I want to allow an admin to add new articles (an article consists of text, images and various properties such as category).
I am trying to decide the optimal Modus Operandi. This site is commercial, so SEO is a major consideration. This means that I want each url to be "unique". That is, if someone navigates to an article about raccoons, he should be redirected to [URL]. This means - I can't have one page that loads the appropriate article dynamically a-la AJAX (gotta use deep-linking)
So how exactly do I do this? suppose the admin entered his text, uploaded the images and set the article properties. I create a new subfolder, save the images to the server (I understand that saving images to a DB is a big no-no), their addresses in a DB, and the content itself to the DB. But now what?
How do I go about creating the actual page?
Is there a function for creating a new aspx file? then what about its corresponding cs file? Or is it unwise to use aspx? Maybe plain html? but then how does it work with my site's master page? Or maybe just create another copy of a general aspx file which is populated with an article according to a parameter?
View 1 Replies
Jan 14, 2011
I would like show top active users in my Index page. How I can get most active users who insert new articles , and wrote comments?
How I can get latest 10 records in table A?
View 5 Replies
Mar 1, 2011
how I can correct an error. I've built the MVCMusicStore tutorial here:
http://mike-ciccone.com/Store/
The first time I visit the site and attempt a database connection I get this error:
Exception Details: System.Data.SqlClient.SqlException: CREATE DATABASE permission denied in database 'master'.
But when I refresh, it all works fine. I'm at a bit of a loss. I don't believe I'm attempting to create a database, but I realise that the error may not really have anything to do with that. This is hosted at GoDaddy shared hosting. The database was created and I used an SQL script to create the tables initially and populate the data. My connection string works as I can pull data from the database, but I do have
a feeling it will be a web.config setting that will correct this.
View 3 Replies
Jul 28, 2010
I have a mdf database in my computer. And I have sql management studio 2005 installed. I would like to mange the mdf database with this program and I do not know how.
View 3 Replies
Mar 30, 2011
When I created table on the shared SQL server on hosting server using management studio, I right click mouse on the table, it pops up create table. However, the table schema is my user name but not dbo. I wnat to create table with dbo schema.
View 2 Replies
Jan 20, 2011
I want to create password in single database for example when i attach My database abc.mdf or open that database then it ask me password. as like access database password..
View 3 Replies
Jan 6, 2011
i have a mssql database in my local machine and i have a new mssql database on server
i created the local database with sql server express and in my server i have a sql server database
now all i need is to create the tables as it is in local database in my server database the data inside of database is not importent i just need the tables
how can i create my new database tables like in my local database with all trigers and relashen ships?
View 2 Replies
Sep 3, 2010
i am new to asp.net. i like to learn asp.net and c#. when i try to connect to sql server, it asks server name. i don't know server name and it asks database name also. how to create database and where can i access like phpmyadmin. in phpmyadmin i can create database and tables.
View 9 Replies
Nov 8, 2010
how to create schema like below for my database... and why it usefull
dbo.Employees.EmployeeNumber,
dbo.Employees.LastName + ', N' +
dbo.Employees.FirstName AS [Full Name],
dbo.Employees.HourlySalary,
dbo.TimeSheets.TimeSheetCode, dbo.TimeSheets.Week1Monday,
dbo.TimeSheets.Week1Tuesday, dbo.TimeSheets.Week1Wednesday,
dbo.TimeSheets.Week1Thursday, dbo.TimeSheets.Week1Friday,
dbo.TimeSheets.Week1Saturday, dbo.TimeSheets.Week1Sunday,
dbo.TimeSheets.Week2Monday, dbo.TimeSheets.Week2Tuesday,
dbo.TimeSheets.Week2Wednesday, dbo.TimeSheets.Week2Thursday,
dbo.TimeSheets.Week2Friday, dbo.TimeSheets.Week2Saturday,
dbo.TimeSheets.Week2Sunday
FROM dbo.Employees INNER JOIN dbo.TimeSheets
View 2 Replies
Aug 11, 2010
I have created a script with pulish to provider button on VS 2010 and I need to deploy my database to my sql server.How can I do that ?
I cannot create a copy of my database on sql server with sql script file.
View 3 Replies
Nov 29, 2010
Is it possible to create a MS SQL 2005 database using Visual Studio 2008?
How about using Visual Web Developer 2008 Express Edition?
View 3 Replies
Jul 18, 2010
I'm kind of at my wits end here as it appears not many others have had this problem so it's possible that I'm missing something very simple but what is it?
I'm using SQL Express 2008 R2, Visual Web Devel Express 2010, .NET framework 4 and tell me whatever else you need to know.
I'm not being able to use add new item feature to insert an empty SQL database into my little project. It tells me connection to a .mdf file require SQL server to be installed and running on local computer. Well I can connect to server with management studio and connect to it inside VS. Database explorer will show me a database when I manually connect using tools>connect to database then data source = Microsoft SQL Server. It then shows up in database explorer. So why isn't the add new item feature working for me? What gives?
View 1 Replies
Jan 28, 2011
I have worked on a timesheet application application in MVC 2 for internal use in our company. Now other small companies have showed interest in the application. I hadn't considered this use of the application, but it got me interested in what it might imply.
I believe I could make it work for several clients by modifying the database (Sql Server accessed by Entity Framework model). But I have read some people advocating multiple databases (one for each client).
Intuitively, this feels like a good idea, since I wouldn't risk having the data of various clients mixed up in the same database (which shouldn't happen of course, but what if it did...). But how would a multiple database solution be implemented specifically?
I.e. with a single database I could just have a client register and all the data needed would be added by the application the same way it is now when there's just one client (my own company).
But with a multiple database solution, how would I create a new database programmatically when a user registers? I have done all database stuff using Linq to Sql, and I am not very familiar with regular SQL programming...
how this could be done (as well as input on whether it is a good idea or if a single database would be better for some reason).
EDIT:
I have also seen discussions about the single database alternative, suggesting that you would then add ClientId to each table... But wouldn't that be hard to maintain in the code? I would have to add "where" conditions to a lot of linq queries I assume... And I assume having a ClientId on each table would mean that each table would have need to have a many to one relationship to the Client table? Wouldn't that be a very complex database structure? As it is right now (without the Client table) I have the following tables (1 -> * designates one to many relationship):
Customer 1 -> * Project 1 -> * Task 1 -> * TimeSegment 1 -> * Employee
Also, Customer has a one to many relationship directly with TimeSegment, for convenience to simplify some queries.
This has worked very well so far. Wouldn't it be possible to simply have a Client table (or UserCompany or whatever one might call it) with a one to many relationship with Customer table? Wouldn't the data integrity be sufficient for the other tables since the rest is handled by the relationships?
View 2 Replies
Oct 25, 2010
How to create Database from .bak file in asp.net c#
and the new database should be created with new database name,user id and password
View 4 Replies
Oct 29, 2010
I am reading xml file using dataset.readxml() method. after this i want to send this data to the database. I want c# code to create a database in sql sever and push watever data in the dataset to that created database.... i am dealing with many xml documents. some could be of same format.. lets say... if 2 docs of same format exists... then it shud not create new database or new tables.. it shud push the data to the suitable format...as i am a newbie its a bit confusing for me... i dont even have any idea on how to proceed with this.
View 4 Replies
Sep 2, 2010
Is it possible to create a SqlServer database at a network drive?
View 2 Replies
Aug 16, 2010
Please advice me how can we create we create a new table or can add rows in database sql server 2005 while user make changes in site?
View 5 Replies
Jun 19, 2012
Cannot open backup device BACKUP DATABASE is terminating abnormally.i need to create database back from the web application but i get the above error
BACKUP DATABASE DB1 TO DISK='SERVERcPbackupDB1_19062012.bak' WITH FORMAT
View 1 Replies
Feb 28, 2013
I am having an initial database with name as DB1, Now when each user registers for my site, a new database is created dynamically, so I need to increment the database name from DB1 to DB2, DB3 and so on.. and it should check the previous database name before creating a new database.
View 1 Replies
Sep 29, 2010
i've created a database in sql server ex. 2008 but when i tried to use it at another computer i keep getting this message: The database "<data base path>" cannot be opened because it is version 655. This server supports version 612 and earlier. A downgrade path is not supported. Could not open new database "<data base path>". CREATE DATABASE is aborted. An attempt to attach an auto-named database for file "<data base path>" failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share. how can i solve this?
View 3 Replies
Dec 6, 2010
I'm working on a new asp.net 4.0 resume web site. I'm starting off with SQL Server Express 2005 and using the standard security and login features given with ASPNETDB.mdf. My site will be hosted on GoDaddy.com.
Quesiton. Should the tables that will contain the information that users will be putting in like resumes, contact information and such go into ASPNETDB.mdf or should it go into a separate database.
View 2 Replies
Feb 22, 2011
I want to create a database in Sql server 2005 with library tables like aspnet_applications, aspnet_profile etc.,
I want to provide admin interface[webform] for the client to create user in the aspnet_Users.
How can I attain this?
View 1 Replies
Sep 26, 2010
I am able to create database through script generated by SQL Server 2008 but unable to create tables from generated script. Please indicate if any step is missing.
************* Code *******************
[Code]....
****************** Contents of text file appended below ***********************
[Code]....
View 5 Replies
Mar 17, 2011
I've just taken over looking after a website and well to be honest the way it's been put together is not the best, but I have to make do as the client does not have the money to make major changes.Anyway currently there is data stored in a MsSQL database and some in an XML file. The xml file does have a ContentID attribute which matches the ContentID in a table.Not really done much with XML as I tend to use a database and LINQ.What would be the best way to tie these two together so I could output the results in a gridview for example.
View 2 Replies