How Can I Apply Transaction Log To The Other Similar SQL Server

Apr 26, 2001

I have two SQL 6.5 servers running independently. Both servers have almost identical databases. For example, we create purchase order in SQL server A. And post the same purchase order # for it's PO Receipt and PO Inspection in SQL server B. How can I apply all transactions entered from SQL server A to SQL server B, and vise versa at end of the day. How can I get help or training for writing codes for manipulating transaction log?

View 1 Replies


ADVERTISEMENT

Transaction Log File Too Early To Apply

Jul 20, 2005

HiI implement a manual standby by backing up Transaction log files everyhourand database nightly and restoring these on a standby server.Every thing works fine but the Transaction log restore fail with errorlistedI am sure the database backup finishes before the transaction logbackupsThanksTYThe log in this backup set terminates at LSN 22927000000763100001,which is too early to apply to the database. A more recent log backupthat includes LSN 22927000000773700001 can be restored. [SQLSTATE42000] (Error 4326). The step failed.

View 1 Replies View Related

Restore Database FROM MDF/LDF, Then Apply Transaction Log From POint Of Failure? Is It POssible?

May 18, 2005

If I have a database backup from sunday, and a failure occurs monday...  Can the backup .mdf and .ldf files be attached, and the backup log after the point of failure be applied to them?
The problem I am having is it looks like you can only restore from a .bak file, and then apply the log at the point of failure.  IT doesn't look like you can restore the .ldf/.mdf files, and then apply the backup log from the point of failure.
 
Can someone please help?  I'm in desparate need of fixing this !
 
Thanks,dp
 
 

View 1 Replies View Related

CROSS APPLY Vs OUTER APPLY Example Messed Up?

Nov 27, 2007

Hi... I'm reading the MS Press 70-442 Self-Paced Training kit, and I'm having problems with this example.
I'd like help getting it to work correctly, or understand why it is isn't working the way I planned.

On page 67, the lab is about the APPLY operator (CROSS APPLY and OUTER APPLY). I first have to input a sample table-valued function into the AdventureWorks database:




Code Block
CREATE FUNCTION fnGetAvgCost(@ProdID int)
RETURNS @RetTable TABLE (AvgCost money)
AS
BEGIN
WITH Product(stdcost)
AS
(
SELECT avg(standardcost) as AvgCost
FROM Production.ProductCostHistory
WHERE ProductID = @ProdID
)
INSERT INTO @RetTable
SELECT * FROM Product
RETURN
END



and then run a sample T-SQL statement





Code Block
SELECT p.Name, p.ProductNumber,
Convert(varchar, cost.AvgCost,1) AS 'Average Cost'
FROM Production.Product p
CROSS APPLY fnGetAvgCost(p.ProductID) AS cost
WHERE cost.AvgCost IS NOT NULL
ORDER BY cost.AvgCost desc

My problem is with the WHERE clause... According to page 56, CROSS APPLY returns only rows from the outer table that produces a result set, so why do I need to explicitly filter NULL values?

When I remove the WHERE clause, the query retrieves lots of NULL AvgCost values.

Again, according to page 56, it is the OUTER APPLY that returns all rows that return a result set and will include NULL values in the columns that are returned from the table-valued function.

So, in short, I don't see the difference between CROSS APPLY and OUTER APPLY, using this example, when I remove the WHERE clause?

(Please refrain from introducing another example into this question.)

View 8 Replies View Related

How To Basically Copy Tables With New Names Rather Than Create Similar Tables From Similar Manual Input.

May 26, 2007

I have a table that I am basically reduplicating a couple of times for each part of this database that I want to create.Each table basically has the same data: The tables will be called motherTable, fatherTable, sonTable, daughterTable and so on.I am pretty much using the following in each column: UserID, MotherID(or FatherID or SonID, etc., etc. and so on for each unique table), FirstName, LastName, MiddleName, BirthPlace, Photo, Age.I don't see an option to copy a table and just modify the second ID part and rename that table accordingly.How can I make this an easier way of creating these similar tables without retyping all these columns over and over again?Thanks in advance. 

View 4 Replies View Related

Array (or Similar Thing ) In Sql Server

Jul 4, 2005

I would like to write a fun or stored procedure to do some operation. It require me to know that what category is currently belong to certain people(people_table: category_table1               to           Many)However, when i use the select statement in stored proc, it return a set of result, not a scalar , therefore, i cannot use the variable to hold it. In addition, there are no array in SQL server.Question:1. Is there any way to hold the collection of result(like array)?2. Also, how to determine to use fun or stored procedure?(Since a integer is need to return by them)Thx

View 4 Replies View Related

How To Create A Sql Server Sequence Similar To Oracle?

Jun 2, 2008

In oracle, I can setup a sequence generating unique ids and query the next value (which is used as a unique identifer). I know sql server has the identity field but I need to query the next val so I can insert rows into multiple tables.
When a user submits a form, I want to take the dept info from the form (in c# asp.net 2.0) and grab the first two characters. Then query the next val from a table that holds an int.. During insert into two tables it would be something like "IT100" or "SL101". But it needs to be unique.
Is there a way to setup a table in sql server similar to a sequence where I can just query the next val (or some other way?). Remember, I cant do this as identity because I need the key being inserted in other tables during form submit.
 It seems very simple but I can't seem to find an answer online that allows me to query the next val in my code then perform the multiple inserts.
Thanks in advance for any assistance you can lend on this,
dev1aspnet

View 2 Replies View Related

Does SQL Server 2005 Has Similar Function Like Mysql_fetch_row ?

Mar 13, 2008

I just began to use SQL Server 2005 as database programming and
found out that I have to translate mysql_fetch_row into SQL Server 2005
but I cannot find some related functions/api, and I was wondering
Does SQL Server 2005 has similar function like mysql_fetch_row ?
Or if not, any advice how I can program to acheive similar functions ?
thank you in advance.

View 4 Replies View Related

SQL Server 2014 :: Merge Similar Records From Excel?

May 19, 2015

I am working on a project that will require me to get a flat data file (excel spreadsheet) with hundreds of thousands of records. Each record is an Owner, and specifically what they own. There will be a field for OwnerName that I want to figure out a way to pull the data into a database like;

Table(Owners) - make sure owner is listed only once

Table(Properties) - joined to owners showing all properties that person owns

Now the tricky part, the owner names might not be exactly the same. Some records might have;

Smith, John
John Smith
Smith, John T
etc.

To make matters worse, this will be a continuous process. I will receive updated excel spreadsheets from time to time and will need to import the new records, many times overwriting the old data. For the good news, there should be an OwnerID that will be unique within the excel data. So as I am merging similar records into the Owners table, I should have a list of OwnerID's that can forever be used to link to the owner.

View 3 Replies View Related

SQL Server 2014 :: Similar Queries Produce Different Output?

Sep 22, 2015

create table #t1 (id int)
create table #t2 (id int)

insert into #t1 values (1)
insert into #t1 values (2)
insert into #t1 values (3)

insert into #t2 values (1)
insert into #t2 values (2)

Run the below quires, you will get 2 different outputs.Second is the desired output. I cant find reason for query1

-- Query1

select * from #t1 a left join #t2 b on a.id = b.id and b.id is null

-- Query1

select * from #t1 a left join #t2 b on a.id = b.id where b.id is null

View 3 Replies View Related

Failure To Apply SP2 To SQL Server 2005 EE

Nov 29, 2007

I am running SQL Server Enterprise Edition Build 9.0.1399 as a default instance on a Windows Server 2003 Enterprise Edition SP2.

Whenever I try to apply Service Pack 2, I obtain the following error:

A recently applied update, KB921896, failed to install

I looked into the other threads but they either discuss community versions of SQL Server or named instances - niether or which apply to me. I also looked but there are no folders named MSSQLSERVER on this machine.

Can somebody Please Help as this is preventing me from deploying a major solution.

Thanks!

View 6 Replies View Related

SQL Server 2014 :: Splitting Similar Data Into Separate Columns?

Aug 18, 2015

If you see below there are 2 customer names on 1 loan, most of them share the same lastname and address, I want to separate it with fields,LoanID, customer 1 Firstname, Customer 1 Lastname, Customer 2 FirstName, Customer 2 Lastname, Adddress,zip

Loan IDFirst NameLastnameAddressaddress 2CityStateZip
1236048Joey Yesen xxxx abc GROVE RDNULLCLEVELANDTX77327
1236048Dickey Yesen xxxx abc GROVE RDNULLCLEVELANDTX77327
1235983Randy Seany xxxx abc Haleyville StNULLAuroraCO80018
1235983Barry Seanyxxxx abc Haleyville StNULLAuroraCO80018

The query I am using

select
L.Loanid
,B.FirstMiddleName
,B.LastName
,MA.AddressLine1
,MA.AddressLine2
,MA.City
,MA.State
,MA.Zip

from Loan AS L

LEFT JOIN Status As S on S.LoanID = L.LoanID
LEFT JOIN Borrower B on B.LoanID = L.LoanID
LEFT JOIN MailingAddress MA on MA.LoanID = L.LoanID
where S.PrimStat = '1' and B.Deceased = '0'

View 3 Replies View Related

DB Design :: How To Avoid Similar Entries In Column List In Server

Sep 16, 2015

I am sharing one sql query and o/p:

select distinct  case 
          when LastStatusMessageIDName = 'Program completed with success' then 'Office 2013 SP1 Installed Successfully'
          when LastExecutionResult = '2013' then 'Machine Does not have Office 2013'
          when LastExecutionResult = '17023' then 'User cancelled installation'
          when LastExecutionResult = '17302' then 'Application failed due to low disk space.'

[Code] .....

The below is the output for the given query,here i want to see only one comment value in my list and the count is also sum of all where comment should be Application will be installed once machine is online(Bold columns o/p)

Comment  Machine Name
Application will be Installed once machine is Online 4
Application will be Installed once machine is Online 12
Application will be Installed once machine is Online 42
Application will be Installed once machine is Online 120
Machine Does not have Office 2013 25
User cancelled installation 32
Application failed due to low disk space 41
Office 2013 SP1 already Exist 60

I need o/p like below:in single line

Application will be Installed once machine is Online 178
Machine Does not have Office 2013 25
User cancelled installation 32
Application failed due to low disk space 41
Office 2013 SP1 already Exist 60

View 2 Replies View Related

Can I Implement A File System With SQL Server Similar To Oracle Content Services?

Apr 29, 2008

I need to implement a file system for an application that allows me to roll back to a point in time. I can do this with either a journaling file system (Unix based such as JFS) or with a database file system such as Oracle Internet File system (now Oracle Content Services). I would MUCH prefer to use SQL Server but cannot find anything that supports this other than a 2000 ppt referencing the then up and coming SQL Server .NET File System.

The application(s) in question are older and store data in proprietary data files and need to access a local (or mapped) drive in standard form (d:programsmyprogram).

Does SQL Server 2005 or 2008 support this type of access? I have searched but cannot find anything to support this.

Thanks.
B.W.

View 1 Replies View Related

How To Convert SQL Server Datetime To Oracle Timestamp (or Other Type With Similar Precision)?

Jul 10, 2007

In SQL Server I've created a linked server to an Oracle database. I am trying to insert (within the context of an sql server table trigger) an SQL Server datetime to an Oracle column with similar precision. Oracle timestamps are not compatible with sql server datetimes and I don't know how to convert the data (or if I should use a different type of column to store the data in Oracle). I have full control over the structure of the Oracle table so I can use a different type if timestamp is not best, but I need the destination column to have at least the same precision as the sql server datetime value. What is the easiest way to do this?

View 22 Replies View Related

How To Apply A Sql Script File On Sql Server 2000 Without OSql.exe

Mar 5, 2007

Hi guys
I need to apply a sql script file on Sql server 2000 by .net 2.0 program. but on the current running machine, there is not Osql.exe file. Do you guys know how to execute the sql file without the command? Is there any way provided in .net library ?
Thanks for you response!

View 3 Replies View Related

SQL Server 2012 :: Using Cross Apply To UNPIVOT Data

Jan 15, 2014

I was reading Kenneth Fisher's and Dwain Camps' articles on unpivoting using cross apply... And I can actually get them to work....

CREATE TABLE #TxCycle(
Cycle INT NOT NULL,
PatientID INT NOT NULL,
ALOPECIA TINYINT,
Causality1 TINYINT,
Relatedness1 TINYINT,

[Code] ....

The one thing I was wondering was this: how do I extract the symptom names from the field list without knowing them all beforehand? Dwain does this

-- DDL and sample data for UNPIVOT Example 2
CREATE TABLE #Suppliers
(ID INT, Product VARCHAR(500)
,Supplier1 VARCHAR(500), Supplier2 VARCHAR(500), Supplier3 VARCHAR(500)
,City1 VARCHAR(500), City2 VARCHAR(500), City3 VARCHAR(500))

Can this be adapted if you don't know all the column names beforehand? (Likely not). Back in the dark ages, when I was working on a database like this, it was in Access, and I could loop over the fields collection and evaluate each field name. (Yes, I know you're not supposed to store information in field names, but I inherited that mess!)

View 7 Replies View Related

SQL Server 2008 :: Cross Apply With Parameterized Function?

Sep 9, 2015

I'm unable to reproduce the error. when they upgrade their OS and SQL EXPRESS to a more recent version the error disappears.

The error is: Incorrect syntax near '.'

the query in question resembles this:

Select column1, column2
from Table1 T
cross apply function(t.column4,t.column5) F
where column3 = 'XXXX'

I made sure that the compatibility level is greater than 90 this error is happening on SQL2005 SP2 as well as SQL2008 with SP2 (but not all clients are suffering from the same problem)

Can it be the .net framework? Although the machines had .net framework 3.52.

Can the OS be an issue? The OS' seem to be old, Windows Server 2008 SP2

I've tried to reproduce the error by setting up virtual machines with same OS and SQL but, again, can't reproduce.

View 9 Replies View Related

Unable To Apply SP2 To SQL Server 2005 Developer Edition

Feb 5, 2008

I can't install the client tools of SQL Server 2005 SP2. I'm doing it on a fresh re-install of SQL Server 2005 Developer Edition (without SP1). It's been a rollercoaster -- I tried it on SP1 and that didn't work, so I decided to uninstall altogether, then couldn't re-install; I had to install most pieces of SQL Server 2005 individually (executing each msi file separately), then I had to install most pieces of SP2 individually, too.

I could get everything to work except for the SP2 client tools. I get this error in the event log:


Product: Microsoft SQL Server 2005 Tools -- Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: SqlWbSetup.5F46584E_060D_4BCB_ADEE_BD15A7BFCC2A, location: C:Program FilesMicrosoft SQL Server90ToolsBinnVSShellCommon7IDESqlWb.exe, command: /setup

followed by this one:


Product: Microsoft SQL Server 2005 Tools - Update 'Service Pack 2 for SQL Server Tools and Workstation Components 2005 ENU (KB921896)' could not be installed. Error code 1603. Additional information is available in the log file C:Program FilesMicrosoft SQL Server90Setup BootstrapLOGHotfixSQLTools9_Hotfix_KB921896_sqlrun_tools.msp.log.

Here is my summary.txt file:

Time: 02/04/2008 23:06:40.328
KB Number: KB921896
Machine: KRISTER
OS Version: Microsoft Windows XP Professional Service Pack 2 (Build 2600)
Package Language: 1033 (ENU)
Package Platform: x86
Package SP Level: 2
Package Version: 3042
Command-line parameters specified:
Cluster Installation: No

**********************************************************************************
Prerequisites Check & Status
SQLSupport: Passed

**********************************************************************************
Products Detected Language Level Patch Level Platform Edition
Setup Support Files ENU 9.2.3042 x86
Database Services (MSSQLSERVER) ENU SP2 2005.090.3054.00 x86 DEVELOPER
Analysis Services (MSSQLSERVER) ENU SP2 2005.090.3054.00 x86 DEVELOPER
Reporting Services (MSSQLSERVER) ENU SP2 9.00.3054.00 x86 DEVELOPER
Notification Services ENU SP2 9.00.3054.00 x86 DEVELOPER
Integration Services ENU SP2 9.00.3054.00 x86 DEVELOPER
SQL Server Native Client ENU 9.00.3042.00 x86
Client Components ENU RTM 9.00.1399.06 x86 DEVELOPER
MSXML 6.0 Parser ENU 6.10.1129.0 x86
SQLXML4 ENU 9.00.3042.00 x86
Backward Compatibility ENU 8.05.2004 x86
Microsoft SQL Server VSS Writer ENU 9.00.3042.00 x86

**********************************************************************************
Products Disqualified & Reason
Product Reason
Database Services (MSSQLSERVER) The product instance MSSQLSERVER been patched with more recent updates.
Analysis Services (MSSQLSERVER) The product instance MSSQLSERVER been patched with more recent updates.
Reporting Services (MSSQLSERVER) The product instance MSSQLSERVER been patched with more recent updates.
Notification Services The product instance NS been patched with more recent updates.
Integration Services The product instance Integration Services been patched with more recent updates.

**********************************************************************************
Processes Locking Files
Process Name Feature Type User Name PID

**********************************************************************************
Product Installation Status
Product : Setup Support Files
Product Version (Previous): 3042
Product Version (Final) :
Status : Not Selected
Log File :
Error Description :
----------------------------------------------------------------------------------
Product : Database Services (MSSQLSERVER)
Product Version (Previous): 3054
Product Version (Final) :
Status : NA
Log File :
Error Description : The product instance MSSQLSERVER been patched with more recent updates.
----------------------------------------------------------------------------------
Product : Analysis Services (MSSQLSERVER)
Product Version (Previous): 3054
Product Version (Final) :
Status : NA
Log File :
Error Description : The product instance MSSQLSERVER been patched with more recent updates.
----------------------------------------------------------------------------------
Product : Reporting Services (MSSQLSERVER)
Product Version (Previous): 3054
Product Version (Final) :
Status : NA
Log File :
Error Description : The product instance MSSQLSERVER been patched with more recent updates.
----------------------------------------------------------------------------------
Product : Notification Services
Product Version (Previous): 3054
Product Version (Final) :
Status : NA
Log File :
Error Description : The product instance NS been patched with more recent updates.
----------------------------------------------------------------------------------
Product : Integration Services
Product Version (Previous): 3054
Product Version (Final) :
Status : NA
Log File :
Error Description : The product instance Integration Services been patched with more recent updates.
----------------------------------------------------------------------------------
Product : SQL Server Native Client
Product Version (Previous): 3042
Product Version (Final) :
Status : Not Selected
Log File :
Error Description :
----------------------------------------------------------------------------------
Product : Client Components
Product Version (Previous): 1399
Product Version (Final) :
Status : Failure
Log File : C:Program FilesMicrosoft SQL Server90Setup BootstrapLOGHotfixSQLTools9_Hotfix_KB921896_sqlrun_tools.msp.log
Error Number : 1721
Error Description : MSP Error: 1721 There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor.
----------------------------------------------------------------------------------
Product : MSXML 6.0 Parser
Product Version (Previous): 1129
Product Version (Final) :
Status : Not Selected
Log File :
Error Description :
----------------------------------------------------------------------------------
Product : SQLXML4
Product Version (Previous): 3042
Product Version (Final) :
Status : Not Selected
Log File :
Error Description :
----------------------------------------------------------------------------------
Product : Backward Compatibility
Product Version (Previous): 2004
Product Version (Final) :
Status : Not Selected
Log File :
Error Description :
----------------------------------------------------------------------------------
Product : Microsoft SQL Server VSS Writer
Product Version (Previous): 3042
Product Version (Final) :
Status : Not Selected
Log File :
Error Description :
----------------------------------------------------------------------------------

**********************************************************************************
Summary
One or more products failed to install, see above for details
Exit Code Returned: 1721


Here is an error message from my hotfix.log file:

02/04/2008 17:37:49.921 MSP Error: 1721 There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor.
02/04/2008 17:40:06.468 MSP returned 1603: A fatal error occurred during installation.
02/04/2008 17:40:06.625 Registry: Opened registry key "SoftwarePoliciesMicrosoftWindowsInstaller"
02/04/2008 17:40:06.671 Registry: Cannot read registry key value "Debug"
02/04/2008 17:40:07.984 Copy Engine: Error, unable to install MSP file: C: empdownloadsMicrosoftSQLServer2005SP2-KB21896-x86-ENUHotFixToolsFilessqlrun_tools.msp
02/04/2008 17:40:08.031 The following exception occurred: Unable to install Windows Installer MSP file Date: 02/04/2008 17:40:08.031 File: depotsqlvaultstablesetupmainl1setupsqlsesqlsedllcopyengine.cpp Line: 800
02/04/2008 17:40:15.562 Watson: Param1 = Unknown
02/04/2008 17:40:15.625 Watson: Param2 = 0x6b9
02/04/2008 17:40:15.796 Watson: Param3 = Unknown
02/04/2008 17:40:16.000 Watson: Param4 = 0x6b9
02/04/2008 17:40:16.078 Watson: Param5 = copyengine.cpp@800
02/04/2008 17:40:16.140 Watson: Param6 = Unknown
02/04/2008 17:40:16.171 Watson: Param7 = SQLTools9
02/04/2008 17:40:16.250 Watson: Param8 = Hotfix@
02/04/2008 17:40:16.343 Watson: Param9 = x86
02/04/2008 17:40:16.500 Watson: Param10 = 3042
02/04/2008 17:40:16.625 Installed product: SQLTools9
02/04/2008 17:40:16.750 Hotfix package completed
02/04/2008 17:40:16.781 Attempting to continue the 32 bit ngen queue

There is a value 3 in my SQLTools9_Hotfix_KB921896_sqlrun_tools.msp.log, but I don't really see anything more descriptive in that file. These are the lines above the value 3 that look interesting:

MSI (s) (1C:30) [17:37:49:000]: Note: 1: 1721 2: CA_HxMerge_SQLCC.3643236F_FC70_11D3_A536_0090278A1BB8 3: C:WINDOWSInstallerMSI1C7B.tmp 4: ms-help://MS.SQLCC.v9
MSI (s) (1C:30) [17:37:49:078]: Transforming table Error.

MSI (s) (1C:30) [17:37:49:078]: Transforming table Error.

MSI (s) (1C:30) [17:37:49:078]: Note: 1: 2262 2: Error 3: -2147287038
Info 1721.There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: CA_HxMerge_SQLCC.3643236F_FC70_11D3_A536_0090278A1BB8, location: C:WINDOWSInstallerMSI1C7B.tmp, command: ms-help://MS.SQLCC.v9
MSI (s) (1C:30) [17:37:49:093]: Note: 1: 1721 2: CA_HxMerge_Hx.3643236F_FC70_11D3_A536_0090278A1BB8 3: C:WINDOWSInstallerMSI1C7C.tmp 4: ms-help://Hx
MSI (s) (1C:30) [17:37:49:171]: Transforming table Error.

MSI (s) (1C:30) [17:37:49:187]: Transforming table Error.

MSI (s) (1C:30) [17:37:49:187]: Note: 1: 2262 2: Error 3: -2147287038
Info 1721.There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: CA_HxMerge_Hx.3643236F_FC70_11D3_A536_0090278A1BB8, location: C:WINDOWSInstallerMSI1C7C.tmp, command: ms-help://Hx
MSI (s) (1C:08) [17:37:49:234]: Invoking remote custom action. DLL: C:WINDOWSInstallerMSI1C7D.tmp, Entrypoint: Set_CommitFlag
<Func Name='LaunchFunction'>
Function=Set_CommitFlag
<Func Name='GetCAContext'>
<EndFunc Name='GetCAContext' Return='T' GetLastError='87'>
Doing Action: Set_CommitFlag
PerfTime Start: Set_CommitFlag : Mon Feb 04 17:37:49 2008
<Func Name='Set_CommitFlag'>
Set_CommitFlag called successfully.Committed
<EndFunc Name='Set_CommitFlag' Return='0' GetLastError='0'>
PerfTime Stop: Set_CommitFlag : Mon Feb 04 17:37:49 2008
<EndFunc Name='LaunchFunction' Return='0' GetLastError='0'>
MSI (s) (1C:30) [17:37:49:859]: Note: 1: 1721 2: SqlWbSetup.5F46584E_060D_4BCB_ADEE_BD15A7BFCC2A 3: C:Program FilesMicrosoft SQL Server90ToolsBinnVSShellCommon7IDESqlWb.exe 4: /setup
MSI (s) (1C:30) [17:37:49:906]: Transforming table Error.

MSI (s) (1C:30) [17:37:49:906]: Transforming table Error.

MSI (s) (1C:30) [17:37:49:906]: Note: 1: 2262 2: Error 3: -2147287038
MSI (s) (1C:30) [17:37:50:031]: Transforming table Error.

MSI (s) (1C:30) [17:37:50:046]: Transforming table Error.

MSI (s) (1C:30) [17:37:50:046]: Note: 1: 2262 2: Error 3: -2147287038
MSI (s) (1C:30) [17:37:50:046]: Product: Microsoft SQL Server 2005 Tools -- Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: SqlWbSetup.5F46584E_060D_4BCB_ADEE_BD15A7BFCC2A, location: C:Program FilesMicrosoft SQL Server90ToolsBinnVSShellCommon7IDESqlWb.exe, command: /setup

Error 1721. There is a problem with this Windows Installer package. A program required for this install to complete could not be run. Contact your support personnel or package vendor. Action: SqlWbSetup.5F46584E_060D_4BCB_ADEE_BD15A7BFCC2A, location: C:Program FilesMicrosoft SQL Server90ToolsBinnVSShellCommon7IDESqlWb.exe, command: /setup


I see lots of other people with problems posted online, but no answer has helped me. So, any help would be greatly appreciated.

Thanks!

View 1 Replies View Related

How To Group Similar Column Name And Sum The Similar Column Name Together

Apr 10, 2008

Hey Gurus,

I have a problem on getting the sql statement which will group similar column name and sum their number together(another column).


A million thanks in advance.

View 5 Replies View Related

SQL Server 2008 :: Apply Justify To Textbox Text In SSRS

Feb 27, 2012

How to Apply justify to textbox text in ssrs?

View 2 Replies View Related

SQL Server Admin 2014 :: Restore Lost Transaction From Transaction Log File

Jun 10, 2015

I have Full database backup upto previous day and transaction logfile of Today transaction. my database has crashed. I have restored previous day's Full backup. I have faced difficulty to restore today's transaction from today's transaction log. What are the steps to restore full database back and one day's transaction log file. Note: there is no differential database backup and transaction backup.

View 8 Replies View Related

SQL Server Admin 2014 :: How A New Partition Function Apply For Current Data

Apr 15, 2015

I have a heavy database , More than 100 GB only for six month .every Query on it takes me along time and I dont have enough space to add more indexes.by a way I decided to do partitioning. I create a partition function , on date filed and all Data records per month was appointed to a separate file.And is partitioning only for Future data entry?

View 9 Replies View Related

SQL Server 2008 :: Text String Parsing To Apply Operators To Datasets?

Aug 7, 2015

I have a problem at the moment, where the client wants to be able to type in a custom algebraic formula with add/minus operators, and then to have this interpreted, so that the related datasets are then added and returned as a single dataset.

An example would be having a formula stored of [a] + [b] - [c]

and if I were to write the SQL to apply that formula, I might write something like (let's assume 1:1 relationships with the ID's)

select a.a + b.b - c.c as [result]
from z
inner join tblA a on z.id = a.id
inner join tblB b on z.id = b.id
inner join tblC c on z.id = c.id

The formula can change though, maybe things like:

[a] + [b] + [c] + [d]
[a] + [b]

The developer before me wrote something SQL-based where they parsed the string and assigned each value of the formula as either positive or negative (e.g A is positive, B is positive, C is negative, now sum the datasets to get the result), and then created one large table of values then summed them. This does (kind of) work, I'm just contemplating potential alternatives, as it is quite a slow process, and feels like it is quite convoluted, when I get into the details. If I were to do something like this in SQL, I'd normally want each part of the expression to be a column, and then to just apply the operators, but because the formula can change, then the SQL would need to be somehow dynamic for this approach.

View 5 Replies View Related

SQL Server 2012 :: CROSS APPLY Returning Records From Left Recordset Even When No Matching Record In Right One

Oct 7, 2014

Following is the query that I'm running:

create table a (id int, name varchar(10));
create table b(id int, sal int);
insert into a values(1,'John'),(1,'ken'),(2,'paul');
insert into b values(1,400),(1,500);

select *
from a
cross apply( select max(sal) as sal from b where b.id = a.id)b;

Below is the result for the same:

idname sal
1John500
1ken500
2paulNULL

Now I'm not sure why the record with ID 2 is coming using CROSS APPLY, shouldn't it be avoided in case of CROSS APPLY and only displayed when using OUTER APPLY.

One thing that I noticed was that if you remove the Aggregate function MAX then the record with ID 2 is not shown in the output. I'm running this query on SQL Server 2012.

View 6 Replies View Related

Error 8525: Distributed Transaction Completed. Either Enlist This Session In A New Transaction Or The NULL Transaction.

May 31, 2008

Hi All

I'm getting this when executing the code below. Going from W2K/SQL2k SP4 to XP/SQL2k SP4 over a dial-up link.

If I take away the begin tran and commit it works, but of course, if one statement fails I want a rollback. I'm executing this from a Delphi app, but I get the same from Qry Analyser.

I've tried both with and without the Set XACT . . ., and also tried with Set Implicit_Transactions off.

set XACT_ABORT ON
Begin distributed Tran
update OPENDATASOURCE('SQLOLEDB','Data Source=10.10.10.171;User ID=*****;Password=****').TRANSFERSTN.TSADMIN.TRANSACTIONMAIN
set REPFLAG = 0 where REPFLAG = 1
update TSADMIN.TRANSACTIONMAIN
set REPFLAG = 0 where REPFLAG = 1 and DONE = 1
update OPENDATASOURCE('SQLOLEDB','Data Source=10.10.10.171;User ID=*****;Password=****').TRANSFERSTN.TSADMIN.WBENTRY
set REPFLAG = 0 where REPFLAG = 1
update TSADMIN.WBENTRY
set REPFLAG = 0 where REPFLAG = 1
update OPENDATASOURCE('SQLOLEDB','Data Source=10.10.10.171;User ID=*****;Password=****').TRANSFERSTN.TSADMIN.FIXED
set REPFLAG = 0 where REPFLAG = 1
update TSADMIN.FIXED
set REPFLAG = 0 where REPFLAG = 1
update OPENDATASOURCE('SQLOLEDB','Data Source=10.10.10.171;User ID=*****;Password=****').TRANSFERSTN.TSADMIN.ALTCHARGE
set REPFLAG = 0 where REPFLAG = 1
update TSADMIN.ALTCHARGE
set REPFLAG = 0 where REPFLAG = 1
update OPENDATASOURCE('SQLOLEDB','Data Source=10.10.10.171;User ID=*****;Password=****').TRANSFERSTN.TSADMIN.TSAUDIT
set REPFLAG = 0 where REPFLAG = 1
update TSADMIN.TSAUDIT
set REPFLAG = 0 where REPFLAG = 1
COMMIT TRAN


It's got me stumped, so any ideas gratefully received.Thx

View 1 Replies View Related

SSIS, Distributed Transaction Completed. Either Enlist This Session In A New Transaction Or The NULL Transaction.

Feb 22, 2007

I have a design a SSIS Package for ETL Process. In my package i have to read the data from the tables and then insert into the another table of same structure.

for reading the data i have write the Dynamic TSQL based on some condition and based on that it is using 25 different function to populate the data into different 25 column. Tsql returning correct data and is working fine in Enterprise manager. But in my SSIS package it show me time out ERROR.

I have increase and decrease the time to catch the error but it is still there i have tried to set 0 for commandout Properties.

if i'm using the 0 for commandtime out then i'm getting the Distributed transaction completed. Either enlist this session in a new transaction or the NULL transaction.

and

Failed to open a fastload rowset for "[dbo].[P@@#$%$%%%]". Check that the object exists in the database.

Please help me it's very urgent.

View 3 Replies View Related

Distributed Transaction Completed. Either Enlist This Session In A New Transaction Or The NULL Transaction.

Feb 6, 2007

I am getting this error  :Distributed transaction completed. Either enlist this session in a new
transaction or the NULL transaction. Description:
An unhandled exception occurred during the execution of the current web
request. Please review the stack trace for more information about the error and
where it originated in the code. Exception Details:
System.Data.OleDb.OleDbException: Distributed transaction completed. Either
enlist this session in a new transaction or the NULL transaction.have anybody idea?!

View 1 Replies View Related

Distributed Transaction Completed. Either Enlist This Session In A New Transaction Or The NULL Transaction.

Dec 22, 2006

i have a sequence container in my my sequence container i have a script task for drop the existing tables. This seq. container connected to another seq. container. all these are in for each loop container when i run the package it's work fine for 1st looop but it gives me error for second execution.

Message is like this:

Distributed transaction completed. Either enlist this session in a new transaction or the NULL transaction.

View 8 Replies View Related

Distributed Transaction Completed. Either Enlist This Session In A New Transaction Or The NULL Transaction. (HELP)

Jan 8, 2008

Hi,

i am getting this error "Distributed transaction completed. Either enlist this session in a new transaction or the NULL transaction.".

my transations have been done using LINKED SERVER. when i manually call the store procedure from Server 1 it works but when i call it through Service broker it dosen't work and gives me this error.



Thanks in advance.


View 2 Replies View Related

Transaction Scope - The Operation Could Not Be Performed Because OLE DB Provider SQLNCLI For Linked Server XXX_LINKED_SERVER Was Unable To Begin A Distributed Transaction. OLE DB Provider SQLNCLI&a

May 15, 2008

Hello, I've a problem with a software developed in C# with the framework 2.0. This is the error I receive : The operation could not be performed because OLE DB provider "SQLNCLI" for linked server "XXX_LINKED_SERVER" was unable to begin a distributed transaction. OLE DB provider "SQLNCLI" for linked server "XXX_LINKED_SERVER" returned message "No transaction is active.". If I try directly to restart the process, it works fine. Is there someone who can help me ? This is the process 1. In C# --> Call of a Query : select from the linked server (db in sql 2005) and insert into a table SQL 2005 2. In the C# --> using (TransactionScope scope = new TransactionScope()) and insert in a table in SQL 2005 which is link server Thank in advance.

View 1 Replies View Related

Similar To PhpMyAdmin For MS Sql?

Apr 11, 2005

Is there any program similar to phpMyAdmin for MS SQL servers?

Thanks in advance

View 5 Replies View Related

Do I Need DatePart Or Similar

May 11, 2006

I have a function that uses the following statement in it

SELECT src_terrier.Areacode, src_terrier.siteref, src_terrier.estatename, src_terrier.Securitised, src_terrier.unitref, src_terrier.unittype,
src_terrier.unittype_count, src_terrier.tenantname, src_terrier.tenantstatus, src_terrier.tenantstatus_count, src_terrier.unitstatus,
src_terrier.unitstatus_count, src_terrier.floortotal, src_terrier.floortotocc, src_terrier.initialvacarea, src_terrier.initialvacnet, src_terrier.TotalRent,
src_terrier.NetRent, src_terrier.FinalRtLsincSC, src_terrier.ErvTot, src_terrier.tenancyterm, src_terrier.landact, src_terrier.datadate,
src_div_mgr.div_mgr, src_portfolio_mgr.portfolio_mgr, src_centre_list.propcat, src_tbl_rental.budgeted_net_rent,
src_tbl_rental.budgeted_occupancy
FROM src_terrier INNER JOIN
src_centre_list ON src_terrier.siteref = src_centre_list.Site_Ref AND src_terrier.Areacode = src_centre_list.Division INNER JOIN
src_div_mgr ON src_centre_list.Division = src_div_mgr.division INNER JOIN
src_portfolio_mgr ON src_centre_list.Portfolio_no = src_portfolio_mgr.portfolio_no LEFT OUTER JOIN
src_tbl_rental ON src_terrier.siteref = src_tbl_rental.site_ref

WHERE (src_terrier.datadate = @dt_src_date) AND
(src_terrier.Areacode = @chr_div) AND
(src_centre_list.Portfolio_no = @vch_portfolio_no) AND
(src_centre_list.propcat = @vch_prop_cat) AND
(src_tbl_rental.site_ref = src_terrier.siteref)

The problem I have is that the 'src_terrier.datadate' is passed through as mm/dd/yyyy (which I do actually want to change to dd/mm/yyyy as that is how the data is stored) however, the src_date within the table src_tbl_rental is only set to 01/mm/yyyy. When I put an inner join on the date element it obviously does not find it as the sample data I am using is as follows

src_terrier = 28/04/2006 and src_tbl_rental is 01/04/2006. Therefore if I pass the same parameter value through the dates are not the same and I get no data at all.

How can I specify that for the purposes of the src_tbl_rental element of the select query, that I only want it to match the mm/yyyy part of the src_date.

Therefore if some passes in
28/04.2006 it will get the records from the terrier table that match that date, and only the records from rental that match the 04/2006 part of the date.

Anybody confused by that , cause I am!

Regards

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved