Making A Single File

Feb 5, 2004

i m having 2 Database files for the same DB and 2 Logfiles ,i want it to make a single file..... is it possible with DTS or any other thing.....

View 1 Replies


ADVERTISEMENT

Making Single Column Value To Multiple Columns

Mar 4, 2008

I have a table which has single column like this.


REP5426 02-28-08 0592 00100028 CAFE 00205415 23.77 A O INPUT
REP5426 02-28-08 0592 00100028 CAFE 00580910 475.58 A O INPUT

REP5426 02-28-08 0592 00100028 CAFE 00800840 -13.32 A O INPUT

REP5426 02-28-08 0592 00100028 CAFE 00205416 23.77 A O INPUT

I want to put this in a new table in individual columns

Col1 col2 col3 col4 col5 col6 col7 col8 col9

REP5426 02-28-08 0592 00100028 CAFE 00205415 23.77 A O INPUT
REP5426 02-28-08 0592 00100028 CAFE 00580910 475.58 A O INPUT

REP5426 02-28-08 0592 00100028 CAFE 00800840 -13.32 A O INPUT

REP5426 02-28-08 0592 00100028 CAFE 00205416 23.77 A O INPUT

How to do this.
Thanks.

View 2 Replies View Related

SQL Server Admin 2014 :: Making Single Subnet Cluster Multi-subnet

Aug 18, 2015

We have a SQL 2014 AlwaysOn availability group running on two Windows 2012 R2 servers that are in the same subnet. We created a new server in a second subnet, installed SQL, joined the server to the Windows cluster, added a new IP resource for the new cluster, and performed the other remaining steps to add a new AG replica to the SQL instance on this new server. When we try to move the core cluster resources to the new node to test failover, we get an error. Here's the command we've been using:

Move-ClusterGroup "Cluster Group" -Node node3

and it returns the error: The operation failed because either the specified cluster node is not the owner of the group, or the node is not a possible owner of the group...I've checked the ownership of the cluster groups and the cluster resources and it looks like they are set appropriately:

>Get-ClusterGroup | Get-ClusterOwnerNode
Cluster Object Owner Nodes
---------------- ---------------
Available Storage {}
Cluster Group {node1,node2,node3}
SQLAG {node1,node2,node3}

[code]....

We've double-checked that all IP resources are in the right subnets and that the dependencies for the Cluster Name resource and the Listener Name resource are set appropriately. I'm not sure what else to check since the PowerShell commands seem to indicate that node3 is an owner of the appropriate resources. What other things need to be checked or if the ownership being checked isn't the same as what PowerShell is checking?

View 3 Replies View Related

Making A Batch File That Will Start A Job

Jun 28, 2000

Hi everyone!
I'm new using SQL server (7.0) and I would like to know if it is possible to create a batch file that will automaticly start a job...
If so, let me know and give me some piece of information (command, parameters)
or a web site, anything that will help me do so...
I'll be very grateful.
If not, let me know anyways
Thanks a lot in advance...

View 2 Replies View Related

Making A Sql Backup File A Database

Mar 5, 2004

Hi

I have copied a sql server backup file. I would like to make it a live database. How would I do this??

View 13 Replies View Related

Making FTP Task Retry Until File Shows Up

Feb 28, 2006

If I want to download a file, but I don't know if it's available yet (actually positive it won't be available for some time), how do I make FTP Task retry/wait until file shows up in the ftp folder?

View 1 Replies View Related

Making A Batch File That Will Start A Active Script ...( More)

Jul 3, 2000

Hi!
I would first like to thank the person (Ray) who answered my question and also those who read it and tried to find an answer to it.

But, it didn't quite help me much, so I'll ask again; reformulate my question.
Here it goes:
I would like to know if I can make a batch file, that excutes or starts an active script (in enterprise manager go to SQL Server Group/Management/SQL Server Agent/jobs/Dbl-click on a job/then go to the steps tab and you will see that the type of the job is an active script. Or, try to see if you have an active script job).
P.S. It's not a SQL script (*.sql).
What I want to do is to start that job from a batch file.
If I can, can you give me more info on how to do it (command line, parameters), a web site, anything that can help me do that.

If I cannot do that, let me know please.
Thanks a lot!

View 1 Replies View Related

DB Design :: Log File Corrupted While Making Database Readonly

Jun 3, 2015

We have database when trying to make read only throwing below error: with stack dump

Location:              recovery.cpp:4517
Expression:         m_recoveryUnit->IsIntendedUpdateable ()
SPID:                     51
Process ID:          6448
Msg 926, Level 14, State 1, Line 1
Database 'XXXX' cannot be opened. It has been marked SUSPECT by recovery.

See the SQL Server errorlog for more information.
Msg 5069, Level 16, State 1, Line 1
ALTER DATABASE statement failed.
Msg 3624, Level 20, State 1, Line 1

A system assertion check has failed. Check the SQL Server error log for details. Typically, an assertion failure is caused by a software bug or data corruption. To check for database corruption, consider running DBCC CHECKDB. If you agreed to send dumps to Microsoft during setup, a mini dump will be sent to Microsoft. An update might be available from Microsoft in the latest Service Pack or in a QFE from Technical Support.

Msg 3313, Level 21, State 2, Line 1

During redoing of a logged operation in database 'XXXX', an error occurred at log record ID (0:0:0). Typically, the specific failure is previously logged as an error in the Windows Event Log service. Restore the database from a full backup, or repair the database.

Msg 3414, Level 21, State 1, Line 1

An error occurred during recovery, preventing the database 'XXXX' (database ID 7) from restarting. Diagnose the recovery errors and fix them, or restore from a known good backup. If errors are not corrected or expected, contact Technical Support.

Investigation DONE:

- DBcc checkdb shown Clean 
- database is online and able to access
-Detached database and attached with rebuild log, still could not bring database read_only

SQL version : SQL server 2008 SP4. 

View 15 Replies View Related

SSIS-problems Making A Dynamic Flat File Connection String

May 8, 2007

Hello.

I have packages that must generate log errors dynamically including time of execution and the name of the task.

I make it changing the properties of the connection inserting two expressions.

1.-I alter the File Usage Type to 1 to generate this files.
2.- I alter the connection string as: @[User::myvariable] +"constant_description"+ time description+ +".txt"

The time description is :
(DT_STR,40,1252) DAY (GETDATE())+"-"+(DT_STR,40,1252) MONTH( GETDATE())+"-"+(DT_STR,40,1252) YEAR( GETDATE())+" + REPLACE( (DT_STR,10,1252) (DT_DBTIME) GETDATE(),":","_")
But it is not the problem

In those packages I have one connector for all the tasks and in execution time it creates one file for each of the tasks.

The problem is the way I insert in the filename the task name.

I have a pre-execute event handler in each task that modifies a string variable( myvariable) appending the task name. When I execute de package it works great but when I only execute a task, the program do not enter in the event and do not put the task’s name.

How can I put that name without using that handler? There is another handler can I use to do it that happens before the system generates the new file name and after pre-execute? Anyone knows another way to do this kind of things?

View 3 Replies View Related

SQL Server 2008 :: Making Use Of A Large Transaction File To Delete Records?

Jun 5, 2015

Currently we has a database of size about 300G. Because our backup system failed some time past we were left with a transaction log file which grew to about 160G. However our backups are working again and everything is working fine. My understanding is that now the transaction log file is practically empty but the capacity remains at 160G.

When you delete records the deleted transactions are going to get logged to the transaction file. My understanding is when a backup is done these transactions get discarded out of the transaction file.

could I make use of this relatively large transaction file and start deleting transactions without out actually adding to the transaction file size.

The plan is to delete records from logging tables that are not referenced to by any other table without this increasing the transaction log file.For example over a period of a few weeks we can delete a chunk of records from a table. Then after it has completed a backup we can delete another chunk of records out of this table until we have got the table down to the records that we now need.Will this work?

View 2 Replies View Related

Making A Batch File That Will Start A Active Script In SQL Server Agent Through SQL Enterprise Manag

Jun 29, 2000

Hi again!
I would like to thank the 2 persons which I had an answer from my previous question first. Thanks a lot !

But, it didn't quite answer my question so I'll give a bit more info.
I would like to know if I can make a batch file, that excutes or starts an active script in SQL Server Agent (that is in SQL Enterprise Manager).
If I can, can you give me more info on how to do it (command line, parameters), a web site, anything that can help me to that.

If I cannot do that, let me know please.
Thanks a lot!

View 2 Replies View Related

DB Design :: Partition With Single File Group Or Multiple File Group?

May 19, 2015

partition with single file group or multiple file group which one best.

we have some report running from partition table, few reports don't have any partition Key and after creating 400  partition  with 400 file group it is slow.what is best practices to crate  400 file group or single file group.

View 9 Replies View Related

Attaching DB Using Single MDF File

Feb 9, 2004

Hi there,
I'm trying to attach a DB using a single MDF file. The file was not properly detached as our server had crashed suddenly neither was the a proper backup done..When I try to attach it says
"the file you've specified is not a valid sql server database file" . But another database was restored using a MDF file without any problems ?
Please do get back if anyone may get what the problem likely is ? It'd be of great help. Let me know if my problem was clear or if I've to put it in a different fashion.

Cheers
Ganesh

View 4 Replies View Related

Back Everything Up In A Single File?

Jul 20, 2005

Greetings,Our former SQL Server 2000 DBA backed up everything in a single diskfile. By everything I mean, full backup, differential backup andtransaction logs. See below for details of how the backup is currentlyset up. When I did 'view contents' of DBBackup, I saw it contained themixture of log, full and diff backups of verious dates. She has quit.Other coworkers said (in a not-sure tone) she was able to restore thedatabases from such a single file, although nobody ever saw or knew howshe did recovery. My knowledge about SQL Server, especially regardingits backup/restore is limited. But I've ever worked with otherdatabases, e.g. Oracle, MySQL and Postgres. I think log backups, fullbackups and differential backups should be completely separated. Also,in each type of backups, each database should have its own backup file.Please advise.=====Log backup:CREATE PROCEDURE sp_lbackup ASBackup log AGEP To DBBackupBackup log careerfairs To DBBackupBackup log CoEdocuments To DBBackupBackup log committee To DBBackupBackup log conference To DBBackupGOFull backup:CREATE PROCEDURE dbo.sp_fullbackup ASBackup database AGEP To DBBackup WITH INITBackup database CoEdocuments To DBBackupBackup database careerfairs To DBBackupBackup database committee To DBBackupBackup database conference To DBBackupGODiff backup:CREATE PROCEDURE sp_diffbackup ASBackup database AGEP To DBBackup with differentialBackup database careerfairs To DBBackup with differentialBackup database CoEdocuments To DBBackup with differentialBackup database committee To DBBackup with differentialBackup database conference To DBBackup with differentialGO=====Thanks in advance for any help,Bing

View 10 Replies View Related

To Get All Stored Procedures Together As A Single File

Feb 5, 2008

 

i have sql server 2005 and sqlserver management studio;I want to get all  stored procedures in my db as a filewhat can I do  to get all stored procedures together as a single  file 

View 3 Replies View Related

How To Run Multiple Sql Statements From A Single File?

Nov 15, 2005

Hi,I am wondering if anyone has any examples of how to run multiple sql statements from a file using .net?  I want to automatically install any stored procedures or scripts from a single file on the server when my web application runs for the first time.  Thanks for your help in advance!

View 1 Replies View Related

How To Load Text File Into Single Row ?

Feb 23, 2005

Hi
how to load text file into single row

I already created dts using
Read File Transformation to place
data in to buffer table then
update row in main table

Is Any way to do it without using DTS , just with T- Sql or bcp ?

View 4 Replies View Related

Split Single File Over Two Tables.

Jul 18, 2006

I have an input file with fixed-width columns that I want to import into two tables.. 5 of the input columns go to 1 table and the remaining 15 go to another table. What's a good way to do this in SSIS?



TIA,

Barkingdog



View 3 Replies View Related

Exporting To Muliple File From A Single Table Using DTS

Aug 15, 2003

Hi Friends

I have been trying to solve this problem for the last 2 days but no luck.

Here is the problem that I am facing.

The task on had is to transfer data from a single table (the source) to multiple files (Destination) based on the record type.

I have tried changing the Datasource property of the Text File Connection object dynamically by using an ActiveX Script. But the data is still being written only to one file.

Can anyone please help me.

Thanks in advance.

Srinivas.

View 3 Replies View Related

Exporting Multiple Tables To A Single File

Oct 1, 2004

I need to export data from multiple tables into one single file. The big problem here is that the tables will have different column types.

I am attempting to create something that allows users to be able to send me the contents of their tables's, through either email or ftp. I would prefer to make it easier for them so they only have to deal with one file, instead of the multiple files that bcp and dts create when exporting from multiple tables.

I was thinking of using DTS or BCP and then join (append) the files (either zip them or append the files together in some fashion), but I was hoping that there was an easier method out there.

Any ideas on how I may accomplish this would be greatly appreciated.

Andy

View 9 Replies View Related

Use All Records From Single Day And Put In Different Sheets Of Excel File

Mar 16, 2012

Ihave simple table..

| ID | DateVal |
--------------------------------
| 4971 | 17.10.2008. 13:30:40 |
--------------------------------
| 4972 | 27.10.2008. 21:56:51 |
-------------------------------
| 4973 | 27.10.2008. 22:30:28 |
--------------------------------
| 4974 | 28.10.2008. 0:01:53 |
------------------------------
| 4975 | 28.10.2008. 0:03:23 |
-------------------------------
| 4976 | 28.10.2008. 0:04:50 |
|------------------------------
| 4977 | 29.10.2008. 4:24:10 |
-------------------------------
| 4978 | 29.10.2008. 4:30:51 |
------------------------------
| 4979| 29.10.2008. 4:36:00 |

I need query that will use all records from single day and put it in excel file.

Records need put in same excel but in different sheet.

View 6 Replies View Related

Deleting Expired Backupsets From Single .BAK File

May 28, 2008

Hi,

I'm new to SQL Server 2005 (up until now I've been an Oracle DBA exclusively) and have been tasked with backing up all (6) of our SQL Server 2005 databases on a regular basis. To accomplish this, I've created individual SQL Server jobs for each database I wish to backup. Each of these jobs executes a T-SQL script like this:


BACKUP DATABASE [MYDATA] TO DISK = N'\networksharemydata.bak' WITH RETAINDAYS = 4,
NOFORMAT,
NOINIT,
NAME = N'MyData-FullBackup',
SKIP,
NOREWIND,
NOUNLOAD,
STATS = 10
GO


My goal in specifying 'RETAINDAYS = 4' was so that there would always be 4 days worth of "backupsets" (forgive my Oracle-ese) kept in mydata.bak. But when I look at the amount of backupsets kept in mydata.bak I noticed that all of them were being kept and none were being deleted.


I researched this problem a little bit and thought I had discovered a solution by specifying 'INIT' instead of 'NOINIT' and 'NOSKIP' instead of 'SKIP', but this deletes the entire contents of mydata.bak only-if all of the backupsets contained in it are past their expiration date. I was hoping it would just delete the expired backupsets and keep the non-expired ones, but this isn't the case.


Does anyone know the simplest way - with T-SQL commands - to accmplish the task of backing up a database to 1 individual .bak file and also only retain x amount of "backupsets" within it? Any help would be greatly appreciated, and the more detailed the better. Thanks.


- Gary

View 18 Replies View Related

Deleting Expired Backupsets From Single .BAK File

May 27, 2008



Hi,


I'm new to SQL Server 2005 (up until now I've been an Oracle DBA exclusively) and have been tasked with backing up all (6) of our SQL Server 2005 databases on a regular basis. To accomplish this, I've created individual SQL Server jobs for each database I wish to backup. Each of these jobs executes a T-SQL script like this:



BACKUP DATABASE [MYDATA] TO DISK = N'\networksharemydata.bak' WITH RETAINDAYS = 4,
NOFORMAT,
NOINIT,
NAME = N'MyData-FullBackup',
SKIP,
NOREWIND,
NOUNLOAD,
STATS = 10
GO

My goal in specifying 'RETAINDAYS = 4' was so that there would always be 4 days worth of "backupsets" (forgive my Oracle-ese) kept in mydata.bak. But when I look at the amount of backupsets kept in mydata.bak I noticed that all of them were being kept and none were being deleted.

I researched this problem a little bit and thought I had discovered a solution by specifying 'INIT' instead of 'NOINIT' and 'NOSKIP' instead of 'SKIP', but this deletes the entire contents of mydata.bak only-if all of the backupsets contained in it are past their expiration date. I was hoping it would just delete the expired backupsets and keep the non-expired ones, but this isn't the case.

Does anyone know the simplest way - with T-SQL commands - to accmplish the task of backing up a database to 1 individual .bak file and also only retain x amount of "backupsets" within it? Any help would be greatly appreciated, and the more detailed the better. Thanks.

- Gary

View 2 Replies View Related

Single Config File Across Multiple Packages

Dec 21, 2005

I've read that a single config file can be used across multiple packages, but am unsure if it applies to what I'm trying to achieve. As an example, I have 2 packages, PackageA and PackageB. Each package has a connection manager defined - ManagerA and ManagerB and I want a single package configuration file to contain the connection string for each manager.

I can define the package configuration of PackageA with no problems. I choose XML file, define the filename and add the connection string to the config.

I then open PackageB Package Configuration and point it to the existing config file, IS tells me the file already exists and allows me to choose the option to "Reuse Existing". I then supply a configuration name and the wizard finishes, without letting me expose any properties. At this point, the configuration file still contains config details from PackageA.

If I then choose to Edit the package configuration in PackageB, I get a warning saying the config values in the config file (relating to PackageA) cannot be found, and the wizard continues. The subsequent PackageB properties which I add overwrite the existing PackageA properties.

So it would appear that what I'm trying to do cannot be done, and I need a separate configuration file for each package?

Any ideas much appreciated.

Greg.

View 2 Replies View Related

How To Merge Report Output Into Single File?

Mar 14, 2008

Hi

I have read a few other posts about how to merge multiple report output files into a single document e.g. a single pdf.
There are a few approaches:
1) Generate post script files and then merge and oprint via a post script driver.
2) Generate seperate pdf files and then merge them into single document using a custom library.

I have a third idea and would appreciate any input:

Dynamically generate a RDL file that contains sub-reports, one for each report required in the final document, publish and run this as the final report. This could happen way before actually running the report i.e. the user has a tool where they select reports for a pack, tool then generates new RDL file and publishes it to sql reporting services, gets run at some later point in time.

Some challenges:
-Generate a table of contents with page numbering?
-Layout of sub-reports, not sure how they would be rendered across multiple pages?
-Managing parametes across sub-reports at run time.

Any suggestions or ideas?

Thanks

T

View 1 Replies View Related

How To Use Deployment Utility Using A Single Package Configuration File

Jan 22, 2007

Hi,

We are trying to create a deployment utility for a solution. The issue we are facing is, we are using a single package configuration file and when we try to build the solution to create the deployment utility, the build process fails saying that the package configuration file already exists. THe reason for this is while trying to build, the utility copies the configation fiel for the packages, it copies for one, but for the second onward, when it tries to copies, it fails saying the file already exists.



Any idea how to overcome this, or else any suggestions how to perform the similar steps to create a deployment utility for a solution in which the packages share a single package configuration file.

Any suggestion would be really appreciated.



Thanks in Advance,

Manish Singh

View 5 Replies View Related

DB Engine :: Splitting Data Of Single Large MDF File

Nov 13, 2015

We have a 5 TB database in our environment. Both MDF & LDF are location in 1 single drive which is of 10 TB.

Now, we want to move to new server but we have multiple drives each of max 1 TB per drive. How can I go about splitting the data from 1 MDF files into multiple data files? How about moving indexes ?

SQL Version : Microsoft SQL Server 2012 (SP1) - 11.0.3513.0 (X64) -  Enterprise Edition (64-bit)

View 10 Replies View Related

Combining Multiple Tables Into A Single Flat File Destination

Aug 21, 2007

Hi,

I want to combine a series of outputs from tsql queries into a single flat file destination using SSIS.

Does anyone have any inkling into how I would do this.

I know that I can configure a flat file connection manager to accept the output from the first oledb source, but am having difficulty with subsequent queries.


e.g. output

personID, personForename, personSurname,
1, pf, langan

***Roles
roleID, roleName
1, developer
2, architect
3, business analyst
4, project manager
5, general manager
6, ceo

***joinPersonRoles
personID,roleID
1,1
1,2
1,3
1,4
1,5
1,6

View 9 Replies View Related

Writing Data From Multiple Tables To A Single Flat File

Sep 13, 2005

I have a package that contains three database tables (Header, detail and trailer record) each table is connected via a OLE DB source in SSIS. Each table varies in the amount of colums it holds and niether of the tables have the same field names. I need to transfer all data, from each table, in order, to a flat file destination.

View 6 Replies View Related

How To Distribute A Large Single File Database Into Multiple Files?

Aug 29, 2007

I have several databases that have grown to 300 GB and would like to distribute the data into multiple files across multiple drives. Can I create a new database that is spread across the new drives and use a full backup to restore or am I stuck with unloading the data table by table?

View 3 Replies View Related

Single Configuration File - Mulitple Packages - Elements Not Used In Each Package

Dec 18, 2007

Hi,

I'm fairly new to the SSIS world, and I've recently ported a bunch of dts packages over to SSIS. I'm an ASP.NET developer so I'm very familiar with the capabilities that configuration files give you, and I attempted to set up my solution as follows:

All of my "Data Sources" are at the project level, and added (with the same name) to each package. I wanted to have a single config file that had all of the project-level settings (i.e. connection strings, data file paths, etc). I then have a config for each package with the package level settings - i.e. variables, etc.

The problem becomes that all packages do not use all data sources. This results in an error when I try to open up a package for editing, it complains that it doesn't have a reference to data source XYZ that it is seeing in the configuration file.

Is there any way that I can get around this? If I have a password to a database change, I don't want to have to look through every config file and change it in multiple places.

View 4 Replies View Related

Loading The Different Language Data From Excel File To The Single Table

Feb 29, 2008

can anyone help me to solve this problem
i have created a ssis package to load the data from excel file to the table, but we are getting the data in different language ie in french,english and in china after loading the data when we view the data it is showing as junk characters for chinese data but we are able to see other language data ie french and english.
so please tell me how to solve that
reply to my mail id(sandeep_shetty@mindtree.com)

View 11 Replies View Related

SQL 2012 :: How To Fetch Single File From Local Path Using SSIS Package

Nov 14, 2014

I have 15 Dealers files .With the Files name as follows

1. ''ACTEST00001_20141112_0408_INV.TXT''

2. ''ACTEST00002_20141112_0408_INV.TXT''

I will get these files through FTP on Daily basis with changes on date alone.

I will have 4 files for each dealers.like INV,SERVICE,SALES,APPOINTMENT.

SO i need to fetch a particular dealer with particular date.

I need to create this scenario in SSIS package. How to create this and what are all the Tasks i need to use to implement this process.

View 1 Replies View Related







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