Need To Replicate Sales Info To Head Office

Aug 21, 2007

Here's My scenario,

I am using SQL2k5 with sp2. In have three branch stores in my site each with SQL 2k5 and a master server at headoffice also with SQL 2k5. The sales transactions for each store goes to a table called sales transaction. What I need is that the info from the sales transaction of each branch populate the sales transaction table at the head office, but not vice versa. That is to say the sales transaction table at each branch must have their information alone and no information from any other branch. Only the head office must have sales transactions from all branches in it's table. What type of replication do i use and how do i implement it?

Muchas muchas gracias.

View 3 Replies


ADVERTISEMENT

Get 1 Record Out Of SQL Express And Use Info In &<head&> And &<body&> Areas, Not In A Grid.

Jan 1, 2008

 Hi
Just started using Visual Studio Express 2005 (Web) with Server 2005 Express and I am trying to extract the data from a SQL but cannot find how to connect to and open a SQL recordset so as to use the values of a single record dotted around a page.  I would be using the values in the <Head> and <body> areas of the page.  The body of the page would utilise standard data grids for sub and sub data, this being no problem.
Below is how I would have retrieved the "EndDate" value from an Access databse under asp.

 Set Conn=Server.CreateObject("ADODB.Connection") Set rs=Server.CreateObject("ADODB.RecordSet") Conn.Open "DBQ=" & Server.MapPath("../private/Drapers.mdb") & ";Driver={Microsoft Access Driver (*.mdb)};"   rs.open "SELECT * FROM Products where ID = 44", Conn, 3, 3     rs("Metta1") rs("Metta2")
The following is from the Web.config file

<connectionStrings><add name="ConnectCB" connectionString="Data Source=.SQLEXPRESS;AttachDbFilename=|DataDirectory|CBBasic.mdf;Integrated Security=True;User Instance=True" providerName="System.Data.SqlClient"/></connectionStrings>
I have tried lots of things that were either code that was superceeded  or just plainly didn't work.
Any help would be appreciated.
      John

View 3 Replies View Related

Is 64 Bit Excel Driver (of Office 2003 Or Office 2007) Available Now?

May 27, 2006

Hi!

Today we moved from 32bit to 64bit computing environment.  64bit Window server 2003 and SQL 2005 are now our playing ground. And 32 bit Office 2003  is also installed.  Excel  in  Office program plays  important roll in our mission. 

One of our routine task is that 
step 1. get  Excel data files  from other websites and
step 2. extract specific data from them and
step 3. converting them into some type of data that can be compatible  with SQL

Our problem occured in step 3.  To convert data, we realised taht  64 bit excel driver, which we believe is not yet available, is required.

My questions are:  

1. Is 64 bit excel driver (of office 2003 or office 2007) available now? 

2. Is there any way OR IS IT POSSIBLE to use 32 bit excel driver with 64bit SQL 2005?
    If possible, please enlighten me.

I would appreciate it very much if anybody answer my questions.

Sincerely

 

 

 

 

 

 



 

   

 

 

 

View 8 Replies View Related

Transact SQL :: Establishing Unique Sales ID To Future Sales IDs From Original Sale

May 19, 2015

i am trying to find a way to link an 'initial' Sale ID of a product to 'future' Sale IDs of products that will trace back to the original Sale ID.For example, if I call the original sale , 'Sale ID #123',  how can i link future Sale ID's (child[ren]) and all future sales to the original Sale ID #123? Can I use a Surrogate Key or similar function?

Parent:Sale ID #123
Children: Sale ID # 456,
Sale ID #789,
Sale ID #.....

how I can link the original Sales ID (Parent) to Sale ID's (child[ren]) of future purchases currently existing and in the future going forward?

View 4 Replies View Related

Report That Shows Customer And Total Sales Who Had Max Sales By Year?

Dec 9, 2014

I have the below data. I need to produce a report that shows customer and total sales who had the max sales by year.

Order ID Cust ID Year Sales
O1 C1 2000 100
O2 C1 2000 150
O1 C2 2000 50
O1 C1 2001 150
O2 C3 2001 200

Report:

Cust ID Year Sales
C1 2000 250
C3 2001 200

View 1 Replies View Related

Power Pivot :: Calculate Sum Of Actual Sales Until Date And Forecast Sales After A Date?

Sep 30, 2015

I want to calculate the sum of actual sales until a date and forecast sales after a date.I am not sure what the best approach to this problem is, but I have tried my best with the following approach. Any better ways to solve this (using DAX).

I have created a parameter table that offers the last date of each month as possible choices to the user. I have tried to create a measure that sums actual sales up until this date.

SalesQuantityActual:=IF(HASONEVALUE(parLastActualMonth[Date]);CALCULATE(factSalesActual[Quantity];factSalesActual[Date]<=VALUES(parLastActualMonth[Date]));BLANK())

Unfortunately the measure above does not work.

In addition to the parameter table, I also have a normal date table.

View 2 Replies View Related

Replicate Schema/Replicate Data Only

Sep 7, 1999

Using SQL 7.0 I'd like to replicate just schema from DB on server A to DB on server B, then be able to replicate data only form DB on server B to DB on server A. I need help!!

Thanks for ANY information you can give me...
~Jepadria

View 2 Replies View Related

Contains Not Working Or Probably It's My Head......but Anyhow I Need Help

Jan 25, 2008

Hello!
 
I try to execute the below statement on a column, I've been trying on a row where subType3 contains this string ",31,32,34,23,55,54,39,44,51,52," without the ",. The column is declared as varchar(MAX)
SELECT subType3 FROM aTable WHERE CONTAINS(subType3, '32')
The above statement executes and returns the result as expected, BUT if I execute this:
SELECT subType3 FROM aTable WHERE CONTAINS(subType3, '55')
then nothing is returned. I can't see any real pattern, 32, 34 and 54 returns the row. If I try with any of the others nothing is returned....Why is this? 
I sort of need to use contains, if I dont wan't to start chopping up the string and patindex or something like that. Patindex works by the way, but when I have many values then it gets a bit cumbersome using anything else than contains.
Thanks for any and all help,
Cheers!
/Eskil
 
 

View 2 Replies View Related

Row Size Over Head

Apr 25, 2000

Hi all !
I have a table where there are a number of columns with varchar(20) and varchar(255).
I am looking at a table with 4 varchar(255) and 10 varchar(20) 's.
I have to estimates the size of the table.I can do that given the rowsize and the number of rows in the table.
My problem is what is the kind of over head that I need to take into account when I am dealing with a table with soo many variable length columns when calculating the row size?
What is the over head difference between char datatye and varchar datatype?
I can't go for char datatypes now.
Help and info regarding this is very much appreciated.

regards
Sush.

View 1 Replies View Related

Column Head

Feb 13, 2007

Hello
Is there a way to get the column head in query output.
Thanks

View 3 Replies View Related

A Query That Is Over My Head...

Dec 8, 2005

Question:
How do I return a list of items that matches one or more criteria that I pass in?

Background:
A user enters a sales lead (a company is looking for a place to have their event). That lead has a number of
criteria elements (start date, end date, city, region, maximum room rate, one or more amenities, etc. - more
details below) that should be used when trying to find Hotels that match that criteria. Obviously, some
criteria is more important than others (city, start and end date are more important than the maximum room
rate) - and it's unlikely that many (if any) of the Hotels will match *all* of the criteria entered by the
user. So, I'm looking to return a list of Hotels that match at least one of the criteria - if possible,
ordered by how many criteria elements match.

What makes this query particularly difficult, is that some of the criteria to match are stored in multiple
tables. For example, each Hotel has "Amenities" (Golf, Spa, etc.) - that are stored in a seperate table.
When a user enters a lead, they select which amenities they want to match. Also, a lead specifies a number
of rooms to block for each day between the Arrival and Departure date - these numbers can change from day
to day - but for this query - I think it's acceptible to get the largest number of rooms needed from any of
the days and compare that one number against the "MaxDailyRoomBlock" field of a Hotel (represented by the
"Property" table). Also, since a Hotel has different rates defined for each season, the query will have to
match the "MaxRate" against the rate of the correct season based on the Arrival and Departure dates. Also,
the rate can be within 20% of the stated "MaxRate".

Here are the following variables that will be passed into the query as criteria items:
RequestCity, RegionINDEID, ArrivalDate, DepartureDate, MaxRate, MaxTheaterSeating, MaxBanquetSeating,
MaxSchoolSeating, MaxBreakoutRooms, MaxRoomBlock

I know this is a huge post - and I sincerly appreciate any help you can provide.

DDL for Tables:
*In the DDL.txt attachment

Sample Data:
* In the data.txt attachment

Previous Attempts:
Unfortunately, I don't even know where to begin, so I haven't tried anything yet.


Expected Results:

PropertyIDNameNumOfMatches
-----------------------------------------------
1Marriot San Diego5
2Hilton San Diego3
3Hilton San Diego Downtown2



Thanks in advance, again...

View 3 Replies View Related

In Over My Head And Need Guidance

Aug 24, 2007

I am the IS manager for a medium business. I am also the DBA and the programmer and help desk and trainer etc etc.

In 2003 I embarked on a project which went live in 2005. We contracted to have our order processing system rewritten into SQL. I went from a character based 4GL language called Progress running in a UNIX enviroment to a knock down, drag out, full blown microsoft solution. I have been operating this new system for two years making modest enhancements and improvements as my skills with microsoft are increasing and improving (retraining my brain to think objects)and hiring contractors to do the really cool fun stuff.

I have to learn Server 2003, SQL Server 2005, SQL Express, T-SQL, Replication, Reporting Services, SSIS, IIS, DTS, Visual Source Safe, Visual Studio, VB, C#, ADO.NET and the .NET Framework fits in here too although I don't really know where.

I hope you are starting to understand my feeling of being 'in over my head'. Right now everything is running perfect. I do backups, restore them and create new reports. Basic stuff.

On top of this our company has merged with a larger one and this bigger company does not have a microsoft solution. They have an AS400 home grown application that I do not want to learn. I will not go backwards!!!!! I will loose my job/position in the next couple of years. I want certifications (to get that interview).

I just don't have the skills to back up the certification (I don't want to be one of those exam cram people) I do a plethora of unrelated taks all day long. Not because I have to do them I choose to do them. I like both DBA and Programming.

So, if you were me, and could get certifications and have experience to back them up what would you do first?

View 4 Replies View Related

This Is Making My Head Spin

Dec 18, 2007



I have a table that contains categories, users, modifydates . All three of those fields may be repeated many times.

I need to build a table that contains user, modifydate, oldcategory, newcategory, duration (number of days between modifydates when there is a category change)

I can use the min(modifydate) to get the 1st occurrence of each new category, but I am having trouble populating the oldvalue and then also getting the duration.

Adding to the complexity, I have to take the last entry of a null category prior to category being populated the first time and populate it with the first occurrence of category, Likewise, I have to populate the first occurrence of null after the last occurrence of a popoulated category. In other words, this simulates populated categories prior to first occurrence and after the last occurrence.

Any help would be great.

View 6 Replies View Related

How To Find The Head Of A Blocking Chain?

May 1, 2002

I'm trying to write a script that will go against sysprocesses (I think) and find the head of a blocking chain, and how many SPIDs it is blocking on down the line.

I found a reference to a script called head_blockers.sql in the Swynk Scripts database (posted March 2000), but the script appears to no longer be available for download.

Any help would be appreciated!

Thank you,
Susan Jones

View 2 Replies View Related

Function To Return Head Of Parent

Jan 19, 2014

I have an existing function and need to alter function to give result of the parent-description until its parent is reached.

--CREATE TABLE

CREATE TABLE [dbo].[CityData](
[Id] [int] NULL,
[ParentID] [int] NULL,
[City] [nchar](20) NULL,
[Location] [nchar](50) NULL,
[Amt] [int] NULL
) ON [PRIMARY]

[Code] ....

View 3 Replies View Related

Column Head On A Matrix Report.

Jan 24, 2008

Hi
I have a huge matrix with 8 columns and then all the data that's generated when choosing a date span. These 8 columns are Topic, Salesperson, Company and so on and then the right part of the matrix grows with values for each month.

My problem is that there are no column headers for the first 8 columns!! How come?
What I did to resolve this was to put in a table in the top left cell and then write in the corresponding column header. This works €¦ in IE but not in PDF or Excel. And I really need it when I export it to Excel.

Any ideas?

Kind regards.

View 5 Replies View Related

Is There A System Table With Timestamp Info Or DTS Job Info?

May 7, 2007

I want to be able to see when records have been added to a table. The issue is we have a DTS job scheduled to run every night. The developer who wrote it password protected it and doesn't work here anymore. I want to add a step to this series of DTS jobs and want to run it just prior to his job. Is there a way to see when the records are being added or when this job is being run? Thanks again, you guys are the best.

ddave

View 3 Replies View Related

Time Spans, Tricky SQL, My Head Hurts

Apr 8, 2006

Data apx (5 million rows):

Span example:
-------------M---------------
___________-------------Rx-------------

Needs to b converted to this (ignore the underscore, used for spacing):

---M-------|-------M & Rx----|---Rx--

The time spans can slide either way.

Data example:

MemberID Eff_Date Term_Date Med_COB Rx_COB
1 20050101 20050912 Y N
1 20050310 20051120 N Y
1 20060101 <null> Y N
1 20060101 <null> N Y

Resulting Records need to be in this format:

MemberID Eff_Date Term_Date Med_COB Rx_COB
1 20050101 20050310 Y N
1 20050311 20050912 Y Y
1 20050913 20051120 N Y
1 20060101 <null> Y Y

Any help with this problem would be greatly appreciated. We are running SQL2K. I like most people,would like to stay away from cursors and loops if possible.

Thanks,
nemesis01

View 8 Replies View Related

Failed Assertion = &#39;m_activeSdesList.Head () == NULL&#39; (in Combination With Error: 1203)

Jun 6, 2000

On our datawarehouse server we are regularly having a 1203 error, causing the sql-server to hang. We get this message in the errorlog: Failed Assertion = 'm_activeSdesList.Head () == NULL'. In the knowledgebase I found a bug description that is very lookalike to our problem.

Article: Q240853 FIX: Lock Escalation With Parallel Query May Cause 1203 Error And Server Shutdown

*** part of the article ***
SYMPTOMS
If a lock escalation occurs while running a parallel query, it is possible to encounter error message 1203 as follows:

spid7 Process 7 unlocking unowned resource: KEY: 13:117575457:2 (35010560ebcd)
spid7 Process 7 unlocking unowned resource: KEY: 13:117575457:2 (35010560ebcd)
spid7 Error: 1203, Severity: 20, State: 1
spid7 Process ID 7 attempting to unlock unowned resource KEY: 13:117575457:2 (35010560ebcd).
spid7 Error: 1203, Severity: 20, State: 1
spid7 Process ID 7 attempting to unlock unowned resource KEY: 13:117575457:2 (35010560ebcd).

The error message included in the error log probably mentions the same lock resource in several of the error messages.

Once the error is printed, an assertion message similar to the following is also printed:
1999-08-09 13:15:26.79 kernel SQL Server Assertion: File: <proc.c>, line=1866 Failed Assertion = 'm_activeSdesList.Head () == NULL'.
After a dump of the stack for all threads, the server initiates a shutdown of the SQL Server process.
...
*** end ***

You can find the complete article on: http://support.microsoft.com/support/kb/articles/q240/8/53.asp?LN=EN-US&SD=gn&FR=0

We can't use the workaround, because that would shut out parallelism, which is necessary for the project.

There is a fix, but in the article Microsoft says: "A supported fix that corrects this problem is now available from Microsoft, but it has not been fully regression tested and should be applied only to systems experiencing this specific problem.".
You understan,d this is not one of my favorite type of fixes...

Does anyone have already installed the fix mentioned? Had any problems with it, or did it cause some other troubles?

Thx,
Kurt De Cauwsemaecker
Database Administrator
Telepolis Antwerpen

View 1 Replies View Related

Total Sales By Customer Vs Total Sales

Nov 26, 2007



I have a report which totals sales by customer. Then table footer has a grand total of all customer sales. I would like to get a percent of each customer's sales against the total sales. How do I get the sum from the table footer to use in an individual customer row?

Thanks.

View 3 Replies View Related

Timeframe For Add-In For Office RTM

Dec 7, 2006

When is the Add-in going to be updated for the RTM of office?

View 1 Replies View Related

Can&#39;t Add New Records During Office Hours

Jul 7, 2000

I have a SQL 7.0 backend for a new DB of mine. This is the first time I
have developed a SQL backend from scratch, so the problem may be my design.
The problem may lie with my Access frontend (I have tried both 97 and 2k),
but I am inclined to think not considering the behavior.
On only one table (the master table no less), I cannot add records during
business hours. I can add records to other tables and edit records on this
table though. This troublesome table has a field indexed as unique that is
not the PK (don't know if that has any bearing, but it is the only table in
this DB that has that property).
The adding records problem appears to be network traffic related because
sometimes records can be added at lunchtime and definitely after hours. I currently only have 3 connected users. I had these problems with only one connected user, so the DB itself is not being strained by traffic. I often have more traffic on the DB after hours to avoid the problems. I have worked on the connection and network traffic angle for awhile, when I stumbled upon the bizarre part. If I add a record via a stored procedure and run this SP on the SQL query analyzer on the server (no network is involved) it is still slow to add the record (30 minutes or more). Needless to say this would equate to an failure on the front end. The same query will run in 0-3 seconds after hours!
Does anyone have any clue how this could happen? I am stumped.
I do have a budget for a consultant if I need one, but I need to find
someone who has a chance to fix this problem. If you don't know the answer
but can refer someone in the DFW area, I am in your debt.

Debbie

View 4 Replies View Related

MS Office Integration &&amp; SSIS

Dec 4, 2006

Using SSIS, every month/week I have to generate serveral excel files. I need to find a way to automatically format these excel files (Bold, Headings in Different color etc.). Is there a way to integrate MS Office excel task in SSIS?

Thanks

Shafiq

View 5 Replies View Related

Embed Office Document

Oct 27, 2005

is it at all feasible to embed an office doument (specifically word) into an ssrs report so that the document will print out when renderered to pdf?

View 4 Replies View Related

Office 2007 And SSIS

Oct 4, 2007

Help! My network support staff just upgraded my MS Office products from Office 2003 to Office 2007, and now I no longer get the "F5 = Run" option in Microsoft Visual Studio to run any of my SSIS packages that ran just fine yesterday, before the upgrade.

The "Debug" option does not occur in the menu choices across the top of the screen. (They are File, Edit, View, Project, Build, Data, Format, SSIS, Tools, Test, Window, Community, and Help -- no Debug.)

I store my packages in the File System. I can run many of them just fine, even today, with the Execute Package Utility. My problem occurs when I try to run them in Visual Studio.

Even if I make a simple, new package that moves a table from Access 2003 to SQL Server 2005, I see no Debug menu selection option when I am finished with the new package.

I figure it must be something simple -- I just don't know where to find it in the Visual Studio menu.

Most of the packages I am trying to run do not access Office files: they access dBase 5 files (database); they run processes on SQL Server 2005 servers. I realize that I may have to make some adjustments to connections to Access databases, should such databases be upgraded to Office 2007.

Thanks in advance.

Dan

View 9 Replies View Related

SQL Database Mail - Responding To And Out Of Office Msg

May 16, 2006

Hi All,
Do anybody know if it's possible to have an SQL 2005 server deal with and out of office reply from an email its send via the new Database Mail?
My application sends mail to users, giving them task instructions via Database Mail, however if they have thier out of office set true, I just get a reply msg in the profiles inbox. I would like the SQL server to know that they are out of office.
I can recogise the replys by the subject and I have control over the format of the replies, so its just case of getting the SQL server to read msg in the inbox.
Thanks
Gary T

View 3 Replies View Related

Windows Authentication And EM/QA/ISQL/Office

Jun 26, 2006

Hi,

A while ago we changed from Sybase to MS Sql Server 2000. Thereby we also introduced Windows Authentication instead of SQL Logins. When end-users wanted to read directly (tools like Enterprise Manager/Query Analyzer/ isql and Office products (like Access and Excel via MS Query)) from the Sybase database we managed that with a SQL login with read-only rights. With Windows Authentication in MS Sql Server 2000 the end-user can enter the database with update rights. Is there a way to manage tools like EM/QA/isql/Office products etcetera so that the end-user can approach the database only with a SQL Login instead of Windows authentication ? Although we are building tooling to kill every user who approaches the database with the tooling mentioned, we think this is not a proper way to manage database access.
We hope someone has encountered the same problem and knows how to handle this and can help us.

Greetings,

Ferrie

View 5 Replies View Related

Office Interop Assemblies And SSIS

Apr 5, 2007

Hi guys,

I'm trying to write an SSIS script that will create an excel file and append data to it.

I downloaded the Office 2007 PIAs (Primary Interop Assemblies) and installed them on my desktop PC where i'm developing from.

However, and even though the assemblies are in the GAC, they don't appear when you look in "Add Reference" for your script task.

If i create a standard .NET web or windows app and try to "Add Reference" I can find them there.

Am I missing anything obvious?

Thanks for your help in advance

Mike

View 8 Replies View Related

HTMLOWC Office Web Component - Deprecated?

Oct 9, 2007

I'm very disappointed that OWC has been "deprecated" ie. ripped out - see http://msdn2.microsoft.com/en-us/library/ms143509.aspx . This is a major step backwards as we have got our users used to pivottables - they allow them to restructure and group summary data the way they want to save us admins from providing every possible grouping combination. Aaarrrgghhhh!

I tried the code from the above but even after restarting the SSRS and IIS no joy. The Apress Pro SSRS 2005 book also complains about the deprecation, and offers an augmented code for the rsreportserver.config file but it still doesn't work:




Code Block
<Extension Name="HTMLOWC" Type="Microsoft.ReportingServices.Rendering.HtmlRenderer.HtmlOWCRenderingExtension,Microsoft.ReportingServices.HtmlRendering" Visible="true">

<Configuration>

<OWCConfiguration>

<OWCDownloadLocation language="en">http://office.microsoft.com/downloads/2002/owc10.aspx
</OWCDownloadLocation>
</OWCConfiguration>
</Configuration>
</Extension>







I appreciate another thread mentions poss necessity of previous DLL however we don't have old installations and old DLLs surely shouldn't be nec. Any further help greatly appreciated.

Has anyone made the OWC work under SQL 2005? Why are MS making this awkward?

View 4 Replies View Related

SQL Server Express With Office 2003?

Apr 3, 2006

Does SQL Server Express work *easily* with Office 2003? I'm especially interested in using Access 2003 & Excel 2003 with SQL Server Express.

I did a search here, but found nothing.

I see Oracle is now giving away their "Express" Oracle 10g; I'm weighing options...

View 3 Replies View Related

MS Office Accounting Trouble Due To SQL Server

Mar 18, 2007

Help!

I've been using MS Office Accounting 2007 (free version) and today the application says that the database cannot be connected to. Basically, the SQL service will not start or run. Could it be due to Symatec's firewall? Please help.

Thanks,

View 3 Replies View Related

Insert Data From Office To Hosted Database

Apr 28, 2006

What is the best way to insert records into an SQL Server 2005 database that's being hosted with my website.  The data will originate from customer sites as transactions.  Do I connect to the hosted database using TCP/IP or do I create web pages that accept the data variables?  This is all new to me!
I need this to happen unattended and 24/7/365
Thanks
Tim

View 1 Replies View Related

SQL 2012 :: Filestream To Store Office Documents?

Jun 26, 2014

I have been asked to look into using Filestream for centralising MS Office documents (mostly excel).I am worried about the "user interface" aspect.I read that there are "this and that" APIs to read/write data to the filestream but surely one would need to write a specific interface to Word/Excel... which feels like far too hard.I am a great admirer of SQL Server but is it the right tool for document management?

We use SQL Server 2012 and have offices round the world with various internet connection quality.Our main aim is to stop the current "spreadsheet nightmare" so common with Excel.

View 9 Replies View Related







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