Saturday, February 25, 2012
Better to backup up all server databases or backup system databases separately from databa
Running SQL Server 2005 SP2 and using named instances. I am having lots of
important application databases on my server these days. My question is
this. Is it better to back up all server databases in one maintenance plan
or backup system databases separately from databases?
Spin
I don't think it matters one way or another. But then it depends on what
issues you may be struggling with.
If you have scheduling issues running a single maintenance plan, break it up
into multiple plans. Personally, I prefer dealing system databases
separately. In particular, when you are dealing relatively large user
databases, you may not want to use the MS maintenance plans and may choose to
schedule their backups in your own schduler for better flexibility.
Linchi
Linchi
"Spin" wrote:
> Gurus,
> Running SQL Server 2005 SP2 and using named instances. I am having lots of
> important application databases on my server these days. My question is
> this. Is it better to back up all server databases in one maintenance plan
> or backup system databases separately from databases?
> --
> Spin
>
Better to backup up all server databases or backup system databases separately from databa
Running SQL Server 2005 SP2 and using named instances. I am having lots of
important application databases on my server these days. My question is
this. Is it better to back up all server databases in one maintenance plan
or backup system databases separately from databases?
--
SpinI don't think it matters one way or another. But then it depends on what
issues you may be struggling with.
If you have scheduling issues running a single maintenance plan, break it up
into multiple plans. Personally, I prefer dealing system databases
separately. In particular, when you are dealing relatively large user
databases, you may not want to use the MS maintenance plans and may choose to
schedule their backups in your own schduler for better flexibility.
Linchi
Linchi
"Spin" wrote:
> Gurus,
> Running SQL Server 2005 SP2 and using named instances. I am having lots of
> important application databases on my server these days. My question is
> this. Is it better to back up all server databases in one maintenance plan
> or backup system databases separately from databases?
> --
> Spin
>
Thursday, February 16, 2012
Best way to populate a page with lots of SQL Data
I have a page that has about 8 dropdown boxes that need to be populated from sql tables. What is the best way to populate these boxes.
Here is how I have it now
conn =New SqlConnection(ConfigurationManager.AppSettings("SQLString"))
''''''''''''' Fill in DropDownList Status '''''''''''''''''''
strSelect ="SELECT * FROM Requests_Status"
cmdSelect =New SqlCommand(strSelect, conn)
conn.Open()
dtrSearch = cmdSelect.ExecuteReader()
ddlRequestStatus.DataSource = dtrSearch
ddlRequestStatus.DataTextField ="RequestStatusName"
ddlRequestStatus.DataValueField ="RequestStatus"
ddlRequestStatus.DataBind()
ddlRequestStatus.Items.Insert(0,New ListItem("-- Select Below --", -1))
cmdSelect.Cancel()
dtrSearch.Close()
conn.Close()
''''''''''''' Fill in DropDownList Container '''''''''''''''''''
strSelect ="SELECT * FROM Containers"
cmdSelect =New SqlCommand(strSelect, conn)
conn.Open()
dtrSearch = cmdSelect.ExecuteReader()
ddlContainer.DataSource = dtrSearch
ddlContainer.DataTextField ="ContainerName"
ddlContainer.DataValueField ="ContainerID"
ddlContainer.DataBind()
ddlContainer.Items.Insert(0,New ListItem("-- Select Below --", -1))
cmdSelect.Cancel()
dtrSearch.Close()
conn.Close()
'''''''''''''''''''''''''''''
I then repeat the same commands as above for the other 6 dropdowns. This seems like a bad way to have to do all this.
Thanks
Craig
Databind the dropdown controls to a SqlDatasource.|||ugh... Isn't that what I am doing? What is the difference between what you say and the code I posted?
C
|||You aren't using a SqlDatasource, you are databinding to a SqlCommand in code.
Switch to design view, look for a control named SqlDatasource and drop one on your page. Run the wizard. Set the dropdown's datasourceid to the name of the sqldatasource (Probably SqlDatasource1). Rinse and repeat.