There are a number of tools available for synchronizing Tables, Indexes, Views, Stored Procedures and objects within a database. (We love RedGate here, and throw a lot of money their way).
However, I'm having a very difficult time finding tools that will help with Jobs, Logins and Linked Servers.
Do these things exist? Am I missing som...
Is there any way that I can create the type time in C# to be compatible with the type time of the SQL server?
...
Hi!
We have a few tables in our SQL Server (2005 & 2008) database with columns defined as nvarchar(4000). We sometimes need to be able to store more data than that and consider to use nvarchar(max) instead. Now to the questions.
Are there any performance implications we should know of?
Is it safe to use "alter table" to do the actual...
I am looking to calculate the shortest distance between two points inside SQL Server 2008 taking into account land mass only.
I have used the geography data type along with STDistance() to work out point x distance to point y as the crow flies, however this sometimes crosses the sea which i am trying to avoid.
I have also created a p...
connect();
$arr = mssql_fetch_assoc(mssql_query("SELECT Applications.ProductName,
Applications.ProductVersion, Applications.ProductSize,
Applications.Description, Applications.ProductKey, Applications.ProductKeyID,
Applications.AutomatedInstaller, Applications.AutomatedInstallerName,
Applications.ISO, A...
Hi, i have few questions for SQL gurus in here ...
Briefly this is ads management system where user can define campaigns for different countries, categories, languages. I have few questions in mind so help me with what you can.
Generally i'm using ASP.NET and i want to cache all result set of certain user once he asks for statistics for...
Recently a software application we utilize upgraded from ASP to ASP.NET. In the process they abandoned the old web-based product and rewrote the entire UI, using new DB tables. The old DB tables still exist in the database and contain legacy files in binary or blob formats. I'm wondering if there is an easy way to export all these legacy...
Say that the raw text of CSV exports and an associated timestamps are stored in a database, where one record is equivalent to one export.
Does anyone have a way to execute a query on the CSV file stored in that field without creating a second connection to the database or exporting the data to a file and then reopening it using the csv ...
Does Sql Server support replication to SQL Server CE? In the documentation, SQL server CE seems to be not supporting the st_geometry type.
...
The current structure is as follows:
Table RowType: RowTypeID
Table RowSubType: RowSubTypeID
FK_RowTypeID
Table ColumnDef: FK_RowTypeID
FK_RowSubTypeID (nullable)
In short, I'm mapping column definitions to rows. In some cases, those rows have subtype(s), which will have column definitions sp...
We have a number of machines which record data into a database at sporadic intervals. For each record, I'd like to obtain the time period between this recording and the previous recording.
I can do this using ROW_NUMBER as follows:
WITH TempTable AS (
SELECT *, ROW_NUMBER() OVER (PARTITION BY Machine_ID ORDER BY Date_Time) AS Orde...
I have a view that I'm trying to setup an Index for. One of the select columns for the view executes a user-defined function that has a return value of varchar(250). However, when I try to setup an Index on that column, I see a size of nvarchar(4000). Why is that and will that cause a problem if I continue to setup my index?
...
I have a stored procedure that needs to return something from one of two databases:
IF @x = 1
SELECT y FROM Table_A
ELSE IF @x = 2
SELECT y FROM Table_B
Either SELECT alone will return what I want, but adding the IF/ELSE makes it stop returning anything. I tried:
IF @x = 1
RETURN SELECT y FROM Table_A
ELSE IF @x = 2
R...
I am wondering if it is possible to take the results of a query and return them as a CSV string instead of as a column of cells.
Basically, we have a table called Customers, and we have a table called CustomerTypeLines, and each Customer can have multiple CustomerTypeLines.
When I run a query against it, I run into problems when I want ...
In my database, assume we have a table defined as follows:
CREATE TABLE [Chemical](
[ChemicalId] int NOT NULL IDENTITY(1,1) PRIMARY KEY,
[Name] nvarchar(max) NOT NULL,
[Description] nvarchar(max) NULL
)
The value for Name can be very large, so we must use nvarchar(max). Unfortunately, we want to create an index on this col...
Are there any best practices for storing Windows logins in SQL server tables(e.g. AddUser field for an audit table)? I have seen tables using sysname, varchar(255) etc.
p.s. Apologies in advance if this has already been answered. I couldn't find or formulate the right query to look this up.
...
I just had to write the most redonkulous expression in an SSIS Derived Column to get dates formatted like "01-JAN-2010". It lookes like this:
There's got to be a better way... isn't there?
...
Wrote a Truck show Contest voting app, financial etc using sqlite. decided to write backup app for show day using ce 3.5. Created db moved to data directory, created tables configured dgridviews all is well. Entered some test data started management studio 08 ran select query against table and got null returns. Started app from vs studio...
Hi there I am wondering whats the best "price field" in SQL Server for a shoplike structure?
Looking at this overview: http://www.teratrax.com/sql_guide/data_types/sql_server_data_types.html
We have data types called money, smallmoney, then we have decimal/numeric and lastly float and real
Name, memory/disk-usage and value ranges:
M...
Hi,
We have an application which uses WAMP server. Now, there is a new requirement from a customer who wants to use MS SQL Server instead of MySQL.
How easy is it to port to SQL Server from MySQL. Also it has to retain this configuration.
Apache->PHP->SQL Server on windows.
How can I connect from Apache to SQL Server. Hope PHP works well...